[lttng-dev] Max length for trace path in LTTng MI

Jonathan Rajotte Julien Jonathan.rajotte-julien at efficios.com
Tue Mar 29 18:37:18 UTC 2016



On 2016-03-29 01:44 PM, Marc-André Laperle wrote:
> Hi,
>
> We have noticed a problem when a trace session uses a long output path 
> (over 255 in length) and the session is listed with MI. The MI output 
> format is specified in a schema, here is the relevant part:
>
> <!-- Maps to the char name[LTTNG_SYMBOL_NAME_LEN] -->
> <xs:simpleType name="name_type">
> <xs:restriction base="xs:string">
> <xs:maxLength value="255"/>
> </xs:restriction>
> </xs:simpleType>
>
> Because of the maxLength of 255, the MI output received by the viewer 
> (Trace Compass) is deemed invalid and the session cannot be listed.
>
> The issue was first noticed here, in a test:
> https://ci.lttng.org/view/Trace%20Compass/job/tracecompass-master-linux/197/JAVA_TO_USE=OpenJDK-8,SWT_GTK3=0,WM=metacity,label=x86-32,target-platform=tracecompass-e4.5/artifact/lttng/org.eclipse.tracecompass.lttng2.control.ui.swtbot.tests/target/work/data/.metadata/.log/*view*/
>
> Then I described steps to reproduce this in normal usage:
> https://bugs.eclipse.org/bugs/show_bug.cgi?id=490557
>
> What would be the best way forward here? Would it be a solution to 
> increase this limit or would it be better perhaps to have a different 
> element for the trace output path that has either a bigger limit or no 
> limit at all?
Hi Marc,

The problem seems to lie in the fact that the session path is defined as 
a name_type which is limited to 255. If we compare it to the config.xsd 
file used for saved sessions the paths are defined as xs:string which 
prevent this problem.

This was dormant since the merging of the MI. Could you try to change 
the type of the path attribute under the session_type element from
tns:name_type to xs:string to test it ?

I'll work on a more complete patch since the session path is not the 
only one affected.

Thanks for reporting this.


>
> Thank you,
> Marc-André
>
>
> _______________________________________________
> lttng-dev mailing list
> lttng-dev at lists.lttng.org
> https://lists.lttng.org/cgi-bin/mailman/listinfo/lttng-dev

-- 
Jonathan R. Julien
Efficios



More information about the lttng-dev mailing list