<div dir="ltr">More questions.<div><br></div><div>I notice that filter expression parser does not validate to check if the field-name in the expression is valid or whether the expression value is consistent with the field type (e.g check that expression value is integer if field type is integer). Are there any plans of stricter checking of expressions? If the user makes a mistake while typing out the expression is there any feedback to indicate the error?</div><div><br></div><div>Thanks,</div><div>Nalin</div></div><div class="gmail_extra"><br><div class="gmail_quote">On Wed, Jul 19, 2017 at 10:11 AM, Nalin Pai <span dir="ltr"><<a href="mailto:nalinpai@gmail.com" target="_blank">nalinpai@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">Thanks for your answers. I have a question on event filters. We will be representing IPv6 addresses as arrays of bytes. We would like to be able to filter on IPv6 address fields. Does lttng filtering on arrays and sequences? If yes, then what's the filter expression format for this.<div><br></div><div>Thanks,</div><div>Nalin<br><div><br></div><div><br></div></div></div><div class="HOEnZb"><div class="h5"><div class="gmail_extra"><br><div class="gmail_quote">On Sun, Jul 16, 2017 at 4:49 PM, Philippe Proulx <span dir="ltr"><<a href="mailto:eeppeliteloop@gmail.com" target="_blank">eeppeliteloop@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><span>On Sun, Jul 16, 2017 at 2:28 PM, Nalin Pai <<a href="mailto:nalinpai@gmail.com" target="_blank">nalinpai@gmail.com</a>> wrote:<br>
><br>
> Hello,<br>
><br>
> We are looking at using lttng as a solution for all our trace and debug requirements. We want to get away from traditional file based string format logging and move to lttng, which then gives us the flexibility of dumping the traces to file or the network. With this background, I have several questions for the team.<br>
><br>
> 1) CTF supports struct fields. I don’t see any ctf_ macros in lttng that will allow us to define tracepoints having struct fields. Is there a way to do this that I am missing?<br>
<br>
</span>Complex CTF types (except a few very specific exceptions) are not<br>
supported in LTTng-UST, the user space LTTng tracer. If you need a<br>
structure data type, then you need to "explode" it, perhaps with field<br>
name prefixes, as of the latest version of LTTng. For example:<br>
`my_struct_user_id`, `my_struct_msg_id`, `my_struct_msg`.<br>
<span><br>
><br>
> 2) Display hints. Sometimes there is a need to display certain fields in a particular way, e.g. IP and MAC addresses. While the tracepoint definition for these fields are going to be integers or sequences of integers, we would like babeltrace to display these fields in a certain format. Short of modifying babeltrace to recognize these fields by their names and handle them specially, is there any other way of achieving the same?<br>
<br>
</span>In the short- to medium-term, with Babeltrace 2.0 (currently in "pre"<br>
development stage), you can create your own sink component to do<br>
something with events. The default textual display is called<br>
sink.text.pretty. If you need a modified version of this sink<br>
component class, you could copy its source and create your own<br>
modified plugin which, as you wrote, would recognize the fields by<br>
name, etc. You could then run the CLI as such:<br>
<br>
babeltrace /path/to/trace --component=sink.my-plugin.my-<wbr>component-class<br>
<br>
I can't comment on Trace Compass/LTTng Scope.<br>
<br>
I see no other way for the moment. CTF 2 will have a way to indicate<br>
that specific fields are to be displayed using a given format string,<br>
for example, but its specification is not available currently (only a<br>
proposal is available here<br>
<<a href="http://diamon.org/ctf/files/CTF2-PROP-1.0.html" rel="noreferrer" target="_blank">http://diamon.org/ctf/files/C<wbr>TF2-PROP-1.0.html</a>>). Babeltrace 2.1 will<br>
support CTF 2, after which a future version of LTTng will produce it.<br>
<br>
Phil<br>
<br>
><br>
> -Nalin<br>
><br>
><br>
><br>
><br>
> ______________________________<wbr>_________________<br>
> lttng-dev mailing list<br>
> <a href="mailto:lttng-dev@lists.lttng.org" target="_blank">lttng-dev@lists.lttng.org</a><br>
> <a href="https://lists.lttng.org/cgi-bin/mailman/listinfo/lttng-dev" rel="noreferrer" target="_blank">https://lists.lttng.org/cgi-bi<wbr>n/mailman/listinfo/lttng-dev</a><br>
><br>
</blockquote></div><br></div>
</div></div></blockquote></div><br></div>