TMF: Do not keep event matches by default when no processing unit is set

This reduces the memory footprint of even matching. Just counting the matches
is enough.

Change-Id: I7650fe55afc878b5afabf9b6cc0c9ec116026448
Signed-off-by: Geneviève Bastien <gbastien+lttng@versatic.net>
Reviewed-on: https://git.eclipse.org/r/31003
Tested-by: Hudson CI
Reviewed-by: Patrick Tasse <patrick.tasse@gmail.com>
Fix API warnings with o.e.l.oprofile.ui plug-in

- Bump up version to 2.1.0

Change-Id: Ie4e76989d20f67a57783b2a271ab42d664296736
Reviewed-on: https://git.eclipse.org/r/31483
Tested-by: Hudson CI
Reviewed-by: Jeff Johnston <jjohnstn@redhat.com>
Tested-by: Jeff Johnston <jjohnstn@redhat.com>
ctf: add Event header data types

This is a composite datatype described in the examples of the CTF spec,
section 6.1.1 . Right now, chances are that many people will re-use this pattern
so why not enhance its performance.

Change-Id: I2042be35fee38e42680691af879357ebb1aff95b
Signed-off-by: Matthew Khouzam <matthew.khouzam@ericsson.com>
Reviewed-on: https://git.eclipse.org/r/25937
Reviewed-by: Alexandre Montplaisir <alexmonthy@voxpopuli.im>
Tested-by: Hudson CI
lttng-control: Workaround for stderr problem in with SSH shell

The RSE ssh shell service uses JCraft's ChannelShell class which
doesn't provide the error stream. This causes problems when parsing
the error output for a special behaviour. For example, when a
the kernel provider is not available the command lttng list -k returns
an error message in the error stream "Kernel provider not available"
and has a non-zero return value. However, this error is ingored in the
Control view, since some users only use UST.

For MI integration, it's important that stdout and stderr is provided
separately.  This patch works for the MI integration, unless there
is mixture of stdout and stderr output for the case that a subset
of the command is successful and some fail (e.g. enable multiple
events). In that case the output has to treated in a special way.

Change-Id: I22f6aa98f36c80602d0f73c0d9a25ae5131ef16b
Signed-off-by: Bernd Hufmann <Bernd.Hufmann@ericsson.com>
Reviewed-on: https://git.eclipse.org/r/31570
Tested-by: Hudson CI
Reviewed-by: Jonathan Rajotte Julien <jonathan.rajotte-julien@ericsson.com>
Reviewed-by: Alexandre Montplaisir <alexmonthy@voxpopuli.im>
Reviewed-by: Bernd Hufmann <bernd.hufmann@ericsson.com>
Tested-by: Bernd Hufmann <bernd.hufmann@ericsson.com>
tmf: Fix and simplify State System Explorer viewer

- Simplify code and reduce the number of private methods
- Wait for initialization of state systems	
- Make the viewer always detect new attributes on update
- Indicate refresh needed on visible range update only if new attributes
found
- Keep root, trace and state system entries on update in filter mode
- Avoid recomputing list of traces, analysis modules and state systems
at every update
- Highlight changed attributes in filter mode
- Implement toString() for tree viewer entries
- Expand tree to auto-expand level after refresh to show changed items
in filter mode

Change-Id: I4c7b9c6c6313733ee94ae9b4e800f78fe085ff64
Signed-off-by: Patrick Tasse <patrick.tasse@gmail.com>
Reviewed-on: https://git.eclipse.org/r/30538
Tested-by: Hudson CI
Reviewed-by: Bernd Hufmann <bernd.hufmann@ericsson.com>
Tested-by: Bernd Hufmann <bernd.hufmann@ericsson.com>
pcap: update the developer guide

Change-Id: I8322e19a4f54e903ef603f6b265e7c2341f244d8
Signed-off-by: Vincent Perot <vincent.perot@ericsson.com>
Reviewed-on: https://git.eclipse.org/r/31473
Tested-by: Hudson CI
Reviewed-by: Patrick Tasse <patrick.tasse@gmail.com>
Reviewed-by: Bernd Hufmann <bernd.hufmann@ericsson.com>
Tested-by: Bernd Hufmann <bernd.hufmann@ericsson.com>
pcap: add pcap to the user guide

Change-Id: Ic043f2dd68e8f4893ba82a81f83d42128b7859b9
Signed-off-by: Vincent Perot <vincent.perot@ericsson.com>
Reviewed-on: https://git.eclipse.org/r/31474
Reviewed-by: Matthew Khouzam <matthew.khouzam@ericsson.com>
Tested-by: Hudson CI
Reviewed-by: Bernd Hufmann <bernd.hufmann@ericsson.com>
Tested-by: Bernd Hufmann <bernd.hufmann@ericsson.com>
pcap: update groupId to org.eclipse.linuxtools.tmf.pcap

Change-Id: Ia2ba9363ffa4cc0df867b097e711d8aa26f86217
Signed-off-by: Vincent Perot <vincent.perot@ericsson.com>
Reviewed-on: https://git.eclipse.org/r/31695
Reviewed-by: Bernd Hufmann <bernd.hufmann@ericsson.com>
Tested-by: Bernd Hufmann <bernd.hufmann@ericsson.com>
Reviewed-by: Matthew Khouzam <matthew.khouzam@ericsson.com>
Tested-by: Hudson CI
Reviewed-by: Alexandre Montplaisir <alexmonthy@voxpopuli.im>
pcap: Add feature plug-in

This patch includes
* Integrated in lttng/pom.xml
* Updates for the releng on Linux Tools level and LTTng level.
* Updated version numbers for PCAP to 1.0.0 (not starting at 3.1.0)
* Exported icons in tmf.pcap.ui
* Updated plug-in dependencies

Change-Id: Ie6319a453350193a99050edc4a7b396b771d0b9d
Signed-off-by: Matthew Khouzam <matthew.khouzam@ericsson.com>
Signed-off-by: Bernd Hufmann <Bernd.Hufmann@ericsson.com>
Reviewed-on: https://git.eclipse.org/r/31563
Reviewed-by: Alexandre Montplaisir <alexmonthy@voxpopuli.im>
Tested-by: Hudson CI
Reviewed-by: Bernd Hufmann <bernd.hufmann@ericsson.com>
Tested-by: Bernd Hufmann <bernd.hufmann@ericsson.com>
rcp: add pcap feature to tracing rcp

Change-Id: I4518f97372c4f8481684f3673d090577611aede5
Signed-off-by: Bernd Hufmann <Bernd.Hufmann@ericsson.com>
Reviewed-on: https://git.eclipse.org/r/31679
Reviewed-by: Alexandre Montplaisir <alexmonthy@voxpopuli.im>
Tested-by: Alexandre Montplaisir <alexmonthy@voxpopuli.im>
Tested-by: Hudson CI
tmf: open files without trace type with eclipse default editors

Also, the navigator content label was changed to delegate the
icon selection for files without trace types to the platform.

This allows users to double-click on any file and it will open with
either as a trace type or as a file in the default editor.

Change-Id: I362dd31c4394bb00fea8ff33bc4843f799ffb3de
Signed-off-by: Bernd Hufmann <Bernd.Hufmann@ericsson.com>
Reviewed-on: https://git.eclipse.org/r/31134
Reviewed-by: Patrick Tasse <patrick.tasse@gmail.com>
Tested-by: Hudson CI
Reviewed-by: Bernd Hufmann <bernd.hufmann@ericsson.com>
Tested-by: Bernd Hufmann <bernd.hufmann@ericsson.com>
Lttng: Attempt to resolve SWTBot test failure.

ImportAndReadKernelSmokeTest.test() sometimes fails
on openTrace() due to not being able to find the editor
view for the trace. Attempt to suppress this error by
having the workbench bot wait for the editor.

Change-Id: I60e6fc90efa49913d4b90b13c9445fcbc44c2277
Signed-off-by: Andrew Ferrazzutti <aferrazz@redhat.com>
Reviewed-on: https://git.eclipse.org/r/31681
Reviewed-by: Matthew Khouzam <matthew.khouzam@ericsson.com>
Tested-by: Hudson CI
pcap: Fix null warning in ProtocolConversion

Rework the ProtocolConversion utility class to switch/case
through the existing values, instead of relying on
non-null-annotated methods.

Also updated the documentation.

Change-Id: I9de733029de08e976acca313a8ad4601d3db0a8b
Signed-off-by: Matthew Khouzam <matthew.khouzam@ericsson.com>
Signed-off-by: Vincent Perot <vincent.perot@ericsson.com>
Signed-off-by: Alexandre Montplaisir <alexmonthy@voxpopuli.im>
Reviewed-on: https://git.eclipse.org/r/31588
Tested-by: Hudson CI
pcap: Convert filePath to java.nio.file.Path

The new Java 7 API for handling file paths is quite versatile,
and much more robust (cross-platform, etc.) than dealing with
simple Strings.

One note: I removed the check to verify that the files end in
".cap" or ".pcap". While it would still have been possible to
do with Path.toString(), on Unix typically the file contents
indicates the type, not the extension.

Change-Id: I327272dd99b298ccd61c1e53d4ded4ed79885d1c
Signed-off-by: Alexandre Montplaisir <alexmonthy@voxpopuli.im>
Reviewed-on: https://git.eclipse.org/r/31596
Tested-by: Hudson CI
Reviewed-by: Bernd Hufmann <bernd.hufmann@ericsson.com>
Reviewed-by: Vincent Perot <vincent.perot@ericsson.com>
Reviewed-by: Matthew Khouzam <matthew.khouzam@ericsson.com>
tmf: Use custom parser constants of TmfTraceType evereywhere

Change-Id: I165c289d5fa3394deee47b631dec45a202987bdc
Signed-off-by: Bernd Hufmann <Bernd.Hufmann@ericsson.com>
Reviewed-on: https://git.eclipse.org/r/31748
Tested-by: Hudson CI
Reviewed-by: Patrick Tasse <patrick.tasse@gmail.com>
Reviewed-by: Bernd Hufmann <bernd.hufmann@ericsson.com>
Tested-by: Bernd Hufmann <bernd.hufmann@ericsson.com>
pcap: initial swtbot project

copy pasted from kernel ui swtbot. Will contain pcap specific tests.

Change-Id: Ic5bb371e99d156c6e6c509a5ee15c9020dc0f5ac
Signed-off-by: Matthew Khouzam <matthew.khouzam@ericsson.com>
Signed-off-by: Vincent Perot <vincent.perot@ericsson.com>
Reviewed-on: https://git.eclipse.org/r/31487
Tested-by: Hudson CI
Reviewed-by: Bernd Hufmann <bernd.hufmann@ericsson.com>
tmf: initial pcap swtbot test

This test will verify that all the views are correctly spawned.

Change-Id: I30717970c4b1d453aef872bb34d5a2eb541f42ac
Signed-off-by: Matthew Khouzam <matthew.khouzam@ericsson.com>
Signed-off-by: Vincent Perot <vincent.perot@ericsson.com>
Reviewed-on: https://git.eclipse.org/r/31488
Tested-by: Hudson CI
Reviewed-by: Bernd Hufmann <bernd.hufmann@ericsson.com>
Tested-by: Bernd Hufmann <bernd.hufmann@ericsson.com>
TMF: Move timestamp transform to internal to avoid API breakage later

The original timestamp transforms have been deprecated. The factory makes them
obsolete anyway.

Change-Id: I83d7fe9d2d78c93850e281d56d8201ea0f0b9177
Signed-off-by: Geneviève Bastien <gbastien+lttng@versatic.net>
Reviewed-on: https://git.eclipse.org/r/31760
Reviewed-by: Alexandre Montplaisir <alexmonthy@voxpopuli.im>
Tested-by: Hudson CI
lttng: user guide for new behaviour of opening of unrecognized traces

Change-Id: I8a79348950b034dfeb21a36b20a3d2ba5f30d7a7
Signed-off-by: Bernd Hufmann <Bernd.Hufmann@ericsson.com>
Reviewed-on: https://git.eclipse.org/r/31729
Tested-by: Hudson CI
Reviewed-by: Patrick Tasse <patrick.tasse@gmail.com>
Reviewed-by: Bernd Hufmann <bernd.hufmann@ericsson.com>
pcap: make test export packages

Change-Id: I084ed468ab6d6d5cfcae75e53a65dd88f2c08bf5
Signed-off-by: Matthew Khouzam <matthew.khouzam@ericsson.com>
Signed-off-by: Vincent Perot <vincent.perot@ericsson.com>
Reviewed-on: https://git.eclipse.org/r/31490
Reviewed-by: Bernd Hufmann <bernd.hufmann@ericsson.com>
Tested-by: Hudson CI