lttng-tools.git
8 years agoDocs: Missing locking assumptions in function headers
Jérémie Galarneau [Wed, 9 Mar 2016 20:33:22 +0000 (15:33 -0500)] 
Docs: Missing locking assumptions in function headers

Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoTest fix: ignore stderr when generating random string
Jérémie Galarneau [Wed, 9 Mar 2016 20:26:37 +0000 (15:26 -0500)] 
Test fix: ignore stderr when generating random string

tr often reports a broken pipe when the head command exits
(after having received enough characters) which pollutes the
test output.

Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoFix: hold session list lock during delete_ust_app
Jérémie Galarneau [Tue, 8 Mar 2016 23:51:36 +0000 (18:51 -0500)] 
Fix: hold session list lock during delete_ust_app

Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoTest: prevent the spawning of a daemonized sessiond
Jonathan Rajotte [Tue, 8 Mar 2016 22:37:39 +0000 (17:37 -0500)] 
Test: prevent the spawning of a daemonized sessiond

Sets the default lttng-sessiond path to /bin/true to prevent the spawning
of a daemonized sessiond. This is necessary since 'lttng create' will spawn
its own sessiond if none is running. It also ensures that 'lttng create'
fails when no sessiond is running.

Signed-off-by: Jonathan Rajotte <jonathan.rajotte-julien@efficios.com>
Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoMissing void in function signature
Jérémie Galarneau [Tue, 8 Mar 2016 21:32:23 +0000 (16:32 -0500)] 
Missing void in function signature

Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoCLI: Show filter expression associated to a syscall
Jérémie Galarneau [Tue, 8 Mar 2016 18:04:33 +0000 (13:04 -0500)] 
CLI: Show filter expression associated to a syscall

Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoFix: missing dereference when computing extended info position
Jérémie Galarneau [Tue, 8 Mar 2016 18:04:07 +0000 (13:04 -0500)] 
Fix: missing dereference when computing extended info position

Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoFix: Only save kernel enablers in session configuration
Jérémie Galarneau [Tue, 8 Mar 2016 17:08:12 +0000 (12:08 -0500)] 
Fix: Only save kernel enablers in session configuration

The session configuration serialization currently saves the
kernel enablers along with all enabled syscalls. In the case
where a syscall would be enabled with a given filter, this would
result in two events being enabled:

1) the syscall with its filter expression (the enabler)
2) the syscall on its own (an enabled syscall)

The observable effect of this is that the syscall ends up being
traced regardless of the filter's evaluation.

Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoFix: Only list kernel enablers when listing events
Jérémie Galarneau [Tue, 8 Mar 2016 17:06:14 +0000 (12:06 -0500)] 
Fix: Only list kernel enablers when listing events

lttng list would list kernel enablers and individual enabled
syscalls which would result in a confusing output.

For instance, enabling the "open" syscall with a filter would
result in a list output displaying both the enabler,
the syscall's name + its filter, and the syscall on its own,
without any mention of an enabled filter.

Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoFix: syscalls hash table leaks when listing kernel events
Jérémie Galarneau [Tue, 8 Mar 2016 16:11:33 +0000 (11:11 -0500)] 
Fix: syscalls hash table leaks when listing kernel events

Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoInitialize command header to zero
Jérémie Galarneau [Tue, 8 Mar 2016 15:59:49 +0000 (10:59 -0500)] 
Initialize command header to zero

Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoRename filter string to filter expression in liblttng-ctl
Jérémie Galarneau [Tue, 8 Mar 2016 15:59:09 +0000 (10:59 -0500)] 
Rename filter string to filter expression in liblttng-ctl

Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoFix: use of unsigned variable to check for negative return
Jérémie Galarneau [Tue, 8 Mar 2016 15:03:55 +0000 (10:03 -0500)] 
Fix: use of unsigned variable to check for negative return

Reported by Coverity Scan, CID 1352682.

Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoClean-up: remove unreachable goto
Jérémie Galarneau [Tue, 8 Mar 2016 14:59:22 +0000 (09:59 -0500)] 
Clean-up: remove unreachable goto

Reported by Coverity Scan CID 1352683.

Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoFix: missing static inline breaks --without-lttng-ust build
Jérémie Galarneau [Tue, 8 Mar 2016 04:42:30 +0000 (23:42 -0500)] 
Fix: missing static inline breaks --without-lttng-ust build

Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agolttng enable-channel memsets lttng_channel to -1
Jérémie Galarneau [Tue, 8 Mar 2016 03:35:23 +0000 (22:35 -0500)] 
lttng enable-channel memsets lttng_channel to -1

The lttng enable-channel command uses a global
struct lttng_channel which it initializes to contain all "-1".

This is a hack used to set tag all attributes as "unset" which
has the unfortunate consequence of setting the extended pointer
to a non-sensical value. This workaround explicitly sets the
extended pointer to NULL, but this command should be refactored so
it is no longer necessary.

Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoChange padding type from array to fixed-width integer
Jérémie Galarneau [Mon, 7 Mar 2016 22:13:53 +0000 (17:13 -0500)] 
Change padding type from array to fixed-width integer

Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoClean-up: missing space between cast operator and operand
Jérémie Galarneau [Mon, 7 Mar 2016 17:47:42 +0000 (12:47 -0500)] 
Clean-up: missing space between cast operator and operand

Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoEnsure UST channel output mode is LTTNG_UST_MMAP
Jérémie Galarneau [Mon, 7 Mar 2016 17:47:23 +0000 (12:47 -0500)] 
Ensure UST channel output mode is LTTNG_UST_MMAP

Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoExtract the lost packets and discarded events counters
Julien Desfossez [Mon, 29 Jun 2015 19:58:01 +0000 (15:58 -0400)] 
Extract the lost packets and discarded events counters

The "lttng list" command now shows the number of discarded events
(discard mode) or lost packets (overwrite mode).

Signed-off-by: Julien Desfossez <jdesfossez@efficios.com>
Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoSend extended channel payload to client
Jérémie Galarneau [Mon, 7 Mar 2016 23:22:56 +0000 (18:22 -0500)] 
Send extended channel payload to client

Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoAdd channel discarded events and lost packets stats accessors
Jérémie Galarneau [Mon, 7 Mar 2016 22:38:04 +0000 (17:38 -0500)] 
Add channel discarded events and lost packets stats accessors

Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoAdd extended info to liblttng-ctl's struct lttng_channel
Jérémie Galarneau [Mon, 7 Mar 2016 22:14:24 +0000 (17:14 -0500)] 
Add extended info to liblttng-ctl's struct lttng_channel

The change has been tested to maintain lttng_channel's size
on x86, x86-64 and ARM32. The alignment rules of these
architectures should cover all cases.

Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoReuse constant string instead of duplicate literal
Jérémie Galarneau [Fri, 4 Mar 2016 16:59:57 +0000 (11:59 -0500)] 
Reuse constant string instead of duplicate literal

Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoClean-up: simplify computation of string position
Jérémie Galarneau [Fri, 4 Mar 2016 16:59:38 +0000 (11:59 -0500)] 
Clean-up: simplify computation of string position

Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoOptimization: lttng UI uses sprintf instead of strcpy
Jérémie Galarneau [Fri, 4 Mar 2016 16:31:00 +0000 (11:31 -0500)] 
Optimization: lttng UI uses sprintf instead of strcpy

The LTTng client currently uses sprintf with format strings
that don't contain a format specifier.

Users have reported concerns for the scalability and performance
of the LTTng UI because of this overkill use of sprintf instead
of strcpy which, presumably, could be inlined by the compiler.

Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoFix: OOT build fails because of missing include path
Jérémie Galarneau [Fri, 4 Mar 2016 01:30:48 +0000 (20:30 -0500)] 
Fix: OOT build fails because of missing include path

Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoTests: Consider lttng mi namespace in test_load
Jérémie Galarneau [Thu, 3 Mar 2016 23:51:19 +0000 (18:51 -0500)] 
Tests: Consider lttng mi namespace in test_load

Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoMI: Remove boolean "exclusion" element
Jérémie Galarneau [Thu, 3 Mar 2016 23:37:44 +0000 (18:37 -0500)] 
MI: Remove boolean "exclusion" element

Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoMI: add <exclusions> (event exclusion names)
Philippe Proulx [Sat, 29 Aug 2015 22:09:21 +0000 (18:09 -0400)] 
MI: add <exclusions> (event exclusion names)

Signed-off-by: Philippe Proulx <eeppeliteloop@gmail.com>
Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoCLI: show event exclusion names
Philippe Proulx [Sat, 29 Aug 2015 22:12:36 +0000 (18:12 -0400)] 
CLI: show event exclusion names

Signed-off-by: Philippe Proulx <eeppeliteloop@gmail.com>
Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoAdd new LTTNG_ERR_OVERFLOW error code
Jérémie Galarneau [Thu, 3 Mar 2016 21:50:42 +0000 (16:50 -0500)] 
Add new LTTNG_ERR_OVERFLOW error code

Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoAdd lttng_event_get_exclusion_name*() to liblttng-ctl
Philippe Proulx [Sat, 29 Aug 2015 22:32:37 +0000 (18:32 -0400)] 
Add lttng_event_get_exclusion_name*() to liblttng-ctl

Signed-off-by: Philippe Proulx <eeppeliteloop@gmail.com>
Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoTests: Consider lttng mi namespace in test_mi
Jérémie Galarneau [Wed, 2 Mar 2016 21:11:26 +0000 (16:11 -0500)] 
Tests: Consider lttng mi namespace in test_mi

Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoMI: Implement event context schema change
Jérémie Galarneau [Wed, 2 Mar 2016 18:27:59 +0000 (13:27 -0500)] 
MI: Implement event context schema change

8 years agoMI: Add application context type to schema
Jérémie Galarneau [Wed, 2 Mar 2016 04:26:43 +0000 (23:26 -0500)] 
MI: Add application context type to schema

Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoMI: add schemaVersion attribute to command schema
Jérémie Galarneau [Wed, 2 Mar 2016 04:20:57 +0000 (23:20 -0500)] 
MI: add schemaVersion attribute to command schema

Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoMI: set machine interface XSD target namespace
Jérémie Galarneau [Wed, 2 Mar 2016 04:24:46 +0000 (23:24 -0500)] 
MI: set machine interface XSD target namespace

Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoAdd schema information to XML MI output
Jérémie Galarneau [Mon, 29 Feb 2016 22:52:58 +0000 (17:52 -0500)] 
Add schema information to XML MI output

Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoFix: libxml2 may return 0 because of buffering
Jérémie Galarneau [Mon, 29 Feb 2016 19:23:19 +0000 (14:23 -0500)] 
Fix: libxml2 may return 0 because of buffering

Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoBump LTTng MI schema to 3.0
Jérémie Galarneau [Fri, 26 Feb 2016 22:08:33 +0000 (17:08 -0500)] 
Bump LTTng MI schema to 3.0

The machine interface schema now allows LTTng to express filter
expressions.

It also introduces "any" clauses at various points to allow the
extension of the schema in a non-breaking way.

Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoMI: add <filter_expression> (event filter expression)
Philippe Proulx [Sat, 29 Aug 2015 21:12:48 +0000 (17:12 -0400)] 
MI: add <filter_expression> (event filter expression)

Signed-off-by: Philippe Proulx <eeppeliteloop@gmail.com>
Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoTransfer UST exclusion names from sessiond to client
Philippe Proulx [Sat, 29 Aug 2015 20:57:56 +0000 (16:57 -0400)] 
Transfer UST exclusion names from sessiond to client

The variable-length extended info has this layout as of this
patch:

    [extended info header][filter string][excl name 1][excl name 2]...

The extended info header contains the length of the subsequent
filter string, including its terminal null character, as well as
the number of exclusion names, each one having a fixed length of
LTTNG_SYMBOL_NAME_LEN bytes, including their terminal null character.

Signed-off-by: Philippe Proulx <eeppeliteloop@gmail.com>
Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoFix: return negative error code in list_lttng_ust_global_events()
Jérémie Galarneau [Fri, 26 Feb 2016 20:14:04 +0000 (15:14 -0500)] 
Fix: return negative error code in list_lttng_ust_global_events()

Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoCLI: show agent event filter string
Jérémie Galarneau [Fri, 26 Feb 2016 20:13:33 +0000 (15:13 -0500)] 
CLI: show agent event filter string

Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoCLI: show event filter string
Philippe Proulx [Fri, 26 Feb 2016 20:12:28 +0000 (15:12 -0500)] 
CLI: show event filter string

Signed-off-by: Philippe Proulx <eeppeliteloop@gmail.com>
Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoAdd lttng_event_get_filter_string() to liblttng-ctl
Philippe Proulx [Sat, 29 Aug 2015 22:31:03 +0000 (18:31 -0400)] 
Add lttng_event_get_filter_string() to liblttng-ctl

Signed-off-by: Philippe Proulx <eeppeliteloop@gmail.com>
Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoTransfer filter strings from sessiond to client
Philippe Proulx [Fri, 28 Aug 2015 21:48:39 +0000 (17:48 -0400)] 
Transfer filter strings from sessiond to client

Previously, the payload of the list events was a simple array of
struct lttng_event.

    [event1][event2][event3]

This patch adds an array of variable-length extended infos at the
end of the event array:

    [event1][event2][event3][extinfo1][extinfo2][extinfo3]

When received on the client side, the event structures are
edited so that their new extended.ptr member points to their
respective extended infos:

    [event1][event2][event3][extinfo1][extinfo2][extinfo3]
        \       \       \      ^         ^         ^
         \       \       \____/_________/_________/
          \       \__________/_________/
           \________________/

This allows this whole block to be freed at once, so as to
keep existing applications linked with liblttng-ctl working
without being recompiled.

The variable-length extended info has this layout for the moment:

    [extended info header][filter string]

The extended info header contains the length of the subsequent
filter string, including its terminal null character.

Signed-off-by: Philippe Proulx <eeppeliteloop@gmail.com>
Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoRefactor setup_lttng_msg() to include cmd header
Philippe Proulx [Fri, 28 Aug 2015 17:34:54 +0000 (13:34 -0400)] 
Refactor setup_lttng_msg() to include cmd header

setup_lttng_msg_full() is now responsible for memcpy()ing
the command header and payload to the complete message.

Signed-off-by: Philippe Proulx <eeppeliteloop@gmail.com>
Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoAdd offset comments to struct lttng_event
Philippe Proulx [Fri, 28 Aug 2015 15:20:47 +0000 (11:20 -0400)] 
Add offset comments to struct lttng_event

Signed-off-by: Philippe Proulx <eeppeliteloop@gmail.com>
Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoAdd command header to sessiond->client response msg
Philippe Proulx [Wed, 26 Aug 2015 19:44:27 +0000 (15:44 -0400)] 
Add command header to sessiond->client response msg

Response messages from the session daemon have this layout
for the moment:

    [message header] (fixed size)
    [payload data]   (0 to n bytes)

This patch makes them have this layout:

    [message header] (fixed size)
    [command header] (0 to n bytes)
    [payload data]   (0 to n bytes)

The command header allows a command to specify additional
informations about its payload.

The header size is set to 0 for all commands for the moment.

Signed-off-by: Philippe Proulx <eeppeliteloop@gmail.com>
Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoAdd internal extended channel structure
Jérémie Galarneau [Thu, 25 Feb 2016 21:28:16 +0000 (16:28 -0500)] 
Add internal extended channel structure

Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoMetadata for instance_id and packet_seq_num
Julien Desfossez [Mon, 29 Jun 2015 19:45:56 +0000 (15:45 -0400)] 
Metadata for instance_id and packet_seq_num

The UST tracer now stores a stream_instance_id in each packet to allow
the viewers to match streams split in multiple trace files.

Also, a sequence_number is stored in each packet so it is possible to
compute the number of lost packets in overwrite mode.

This is a locked-step with the corresponding lttng-ust commits.

Signed-off-by: Julien Desfossez <jdesfossez@efficios.com>
Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoAdd a HT to lookup sessions by id
Julien Desfossez [Fri, 7 Aug 2015 02:14:49 +0000 (22:14 -0400)] 
Add a HT to lookup sessions by id

Signed-off-by: Julien Desfossez <jdesfossez@efficios.com>
Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoExplicitly stop the session on lttng destroy
Julien Desfossez [Fri, 3 Jul 2015 21:08:27 +0000 (17:08 -0400)] 
Explicitly stop the session on lttng destroy

This changes the default behavior of the "destroy" command and API: now
it implicitely stops the tracing and waits for the data to be available
on disk or the network. Like the "stop" command and API, a no_wait
option is available to skip the waiting and destroy directly the
session.

Signed-off-by: Julien Desfossez <jdesfossez@efficios.com>
Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoFix: per-pid ust buffers flush race with application unregister
Mathieu Desnoyers [Wed, 24 Feb 2016 00:41:40 +0000 (19:41 -0500)] 
Fix: per-pid ust buffers flush race with application unregister

If an application exits between the moment we create the ust app session
(shadow copy) and the moment we send channels to the application,
sending channels may fail. If the application unregisters between the
the end of ust app session creation and the destroy that follows (ust
app session lock is released in between), we may see is_sent being
false.

This assert was initially there in the early days of lttng-tools when
the application was responsible for doing the flush. Now that the flush
has been moved to the consumer daemon, we don't need this assertion
anymore.

Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoFix warning when building Python bindings
Jérémie Galarneau [Tue, 23 Feb 2016 20:18:18 +0000 (15:18 -0500)] 
Fix warning when building Python bindings

Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoAdd CONTRIBUTING.md
Philippe Proulx [Sat, 20 Feb 2016 01:39:35 +0000 (20:39 -0500)] 
Add CONTRIBUTING.md

Signed-off-by: Philippe Proulx <eeppeliteloop@gmail.com>
Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoRevert "Python bindings: remove duplicate structure definitions"
Jérémie Galarneau [Tue, 23 Feb 2016 19:52:13 +0000 (14:52 -0500)] 
Revert "Python bindings: remove duplicate structure definitions"

This reverts commit dcac8046802214aa852b7b3b36bc78a793cb6295.

8 years agoDocs: clarify cross-version tracer compatibility
Jérémie Galarneau [Thu, 18 Feb 2016 17:23:44 +0000 (12:23 -0500)] 
Docs: clarify cross-version tracer compatibility

Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoCleanup: Remove unnecessary newline
Jérémie Galarneau [Fri, 19 Feb 2016 19:34:22 +0000 (14:34 -0500)] 
Cleanup: Remove unnecessary newline

Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoFix: Use ipv6 loopback adress in test_uri
Michael Jeanson [Thu, 18 Feb 2016 17:45:13 +0000 (12:45 -0500)] 
Fix: Use ipv6 loopback adress in test_uri

Some older version of Debian/Ubuntu and maybe other distros won't set
localhost to point on ::1 in the system hosts file and use instead a
custom name like ip6-localhost or ipv6-locahost which is not
standardized across distros.

To work around this, use the ipv6 loopback address instead of localhost.

Signed-off-by: Michael Jeanson <mjeanson@efficios.com>
Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoPython bindings: remove duplicate structure definitions
Jérémie Galarneau [Thu, 18 Feb 2016 16:56:50 +0000 (11:56 -0500)] 
Python bindings: remove duplicate structure definitions

Use the structure definitions as defined in the public lttng
headers and not local copies which will go unmaintained.

Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoFix: test: handle env variables undefined
Jonathan Rajotte [Wed, 17 Feb 2016 21:33:00 +0000 (16:33 -0500)] 
Fix: test: handle env variables undefined

Prevent errors on non-existent key fetching e.g LD_PRELOAD & LD_LIBRARY_PATH.
Uses .get() with a default empty string to prevent this case.

Signed-off-by: Jonathan Rajotte <jonathan.rajotte-julien@efficios.com>
Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoFix: report already enabled event error to client
Jérémie Galarneau [Sun, 14 Feb 2016 23:22:03 +0000 (18:22 -0500)] 
Fix: report already enabled event error to client

Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoDocs: add comment to cmd_add_context()
Jérémie Galarneau [Sun, 14 Feb 2016 23:02:21 +0000 (18:02 -0500)] 
Docs: add comment to cmd_add_context()

Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoFix: application context leak when enabling context
Jérémie Galarneau [Sun, 14 Feb 2016 23:00:43 +0000 (18:00 -0500)] 
Fix: application context leak when enabling context

Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoFix: string leak when processing of client message fails
Jérémie Galarneau [Sun, 14 Feb 2016 22:57:19 +0000 (17:57 -0500)] 
Fix: string leak when processing of client message fails

Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoFix: missing return code initialization on error
Jérémie Galarneau [Sun, 14 Feb 2016 22:54:24 +0000 (17:54 -0500)] 
Fix: missing return code initialization on error

Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoFix: unchecked return value in _lttng_variant_statedump()
Jérémie Galarneau [Sun, 14 Feb 2016 22:52:03 +0000 (17:52 -0500)] 
Fix: unchecked return value in _lttng_variant_statedump()

Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoFix: Possible use-after-free in create_ctx_type()
Jérémie Galarneau [Sun, 14 Feb 2016 22:48:43 +0000 (17:48 -0500)] 
Fix: Possible use-after-free in create_ctx_type()

Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoFix: filter tests now accept "." in identifiers
Mathieu Desnoyers [Sat, 13 Feb 2016 16:18:27 +0000 (11:18 -0500)] 
Fix: filter tests now accept "." in identifiers

Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoFix: Don't notify agent of non-app context addition
Jérémie Galarneau [Tue, 9 Feb 2016 20:16:49 +0000 (15:16 -0500)] 
Fix: Don't notify agent of non-app context addition

Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoCreate agent on channel creation
Jérémie Galarneau [Tue, 9 Feb 2016 20:16:38 +0000 (15:16 -0500)] 
Create agent on channel creation

Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoIntroduce application contexts to session configuration schema
Jérémie Galarneau [Tue, 9 Feb 2016 20:12:33 +0000 (15:12 -0500)] 
Introduce application contexts to session configuration schema

Session configuration schema version is bumped to 2.8.

Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoFix typos in error descriptions
Jérémie Galarneau [Tue, 9 Feb 2016 20:11:32 +0000 (15:11 -0500)] 
Fix typos in error descriptions

Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoEnable agent application contexts if filter has such dependencies
Jérémie Galarneau [Fri, 5 Feb 2016 22:10:41 +0000 (17:10 -0500)] 
Enable agent application contexts if filter has such dependencies

Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoCompare provider and context names in trace_ust_match_context
Jérémie Galarneau [Wed, 3 Feb 2016 23:51:29 +0000 (18:51 -0500)] 
Compare provider and context names in trace_ust_match_context

Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoAllow $app.provider:ctxname in filter, enum, variant identifiers
Mathieu Desnoyers [Tue, 26 Jan 2016 15:14:17 +0000 (10:14 -0500)] 
Allow $app.provider:ctxname in filter, enum, variant identifiers

Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoAdd variant type support to ust registry and metadata
Mathieu Desnoyers [Mon, 18 Jan 2016 22:22:25 +0000 (17:22 -0500)] 
Add variant type support to ust registry and metadata

Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoNotify java agent of enabled application contexts
Jérémie Galarneau [Thu, 28 Jan 2016 21:39:33 +0000 (16:39 -0500)] 
Notify java agent of enabled application contexts

Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoAdd app context support to lttng client
Jérémie Galarneau [Thu, 28 Jan 2016 00:01:50 +0000 (19:01 -0500)] 
Add app context support to lttng client

Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoEnforce const-correctness in UNIX socket wrappers
Jérémie Galarneau [Tue, 26 Jan 2016 16:46:48 +0000 (11:46 -0500)] 
Enforce const-correctness in UNIX socket wrappers

Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoRemove superflous domain check in context_ust_add
Jérémie Galarneau [Tue, 26 Jan 2016 16:46:17 +0000 (11:46 -0500)] 
Remove superflous domain check in context_ust_add

Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoRemove superflous domain check in add_uctx_to_channel
Jérémie Galarneau [Tue, 26 Jan 2016 16:45:42 +0000 (11:45 -0500)] 
Remove superflous domain check in add_uctx_to_channel

Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoUse lttng_domain_type enum instead of bare integer
Jérémie Galarneau [Tue, 26 Jan 2016 16:44:12 +0000 (11:44 -0500)] 
Use lttng_domain_type enum instead of bare integer

Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoAdd application context support to lttng-ctl lttng_add_context
Jérémie Galarneau [Tue, 26 Jan 2016 16:42:45 +0000 (11:42 -0500)] 
Add application context support to lttng-ctl lttng_add_context

Forward the provider and context names of app contexts to the
session daemon.

Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoCleanup comments in lttng-ctl.c
Jérémie Galarneau [Fri, 22 Jan 2016 21:23:43 +0000 (16:23 -0500)] 
Cleanup comments in lttng-ctl.c

Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoTests fix: source utils.sh before using conf_proc_count
Jérémie Galarneau [Fri, 12 Feb 2016 21:41:49 +0000 (16:41 -0500)] 
Tests fix: source utils.sh before using conf_proc_count

Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoTests: use configured processor count in getcpu override tests
Jérémie Galarneau [Fri, 12 Feb 2016 16:19:22 +0000 (11:19 -0500)] 
Tests: use configured processor count in getcpu override tests

Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoTests: use configured processor count in snapshot tests
Jérémie Galarneau [Fri, 12 Feb 2016 16:17:42 +0000 (11:17 -0500)] 
Tests: use configured processor count in snapshot tests

Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoTests: Introduce conf_proc_count()
Jérémie Galarneau [Fri, 12 Feb 2016 16:17:18 +0000 (11:17 -0500)] 
Tests: Introduce conf_proc_count()

Tests are using the nproc utility which return the number of
_available_ CPUs. The distinction between online, available and
configured CPUs is subtle, but important.

The number of "online" CPUs can change at runtime as CPUs are
hot-plugged. This could happen during a test and result in
unexpected results.

The number of "configured" CPUs includes any CPU which may be
offline at the time.

The number of "available" CPUs, which is what is returned by the
nproc utility, may differ from both "online" and "configured"
counts. This is the case in containers which are assigned to a
subset of configured CPUs.

Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoTests: print a more precise test description in snapshot tests
Jérémie Galarneau [Fri, 12 Feb 2016 15:40:50 +0000 (10:40 -0500)] 
Tests: print a more precise test description in snapshot tests

Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoclock offset: print negative value in metadata for lttng-ust metadata
Mathieu Desnoyers [Mon, 8 Feb 2016 22:13:26 +0000 (17:13 -0500)] 
clock offset: print negative value in metadata for lttng-ust metadata

In the upcoming 2.8, we can print the negative value of clock offset in
the metadata, and expect users to update their viewers to correct any
bug that could prevent them from handling those negative values.

This happens only in cases where the system sets CLOCK_REALTIME to 0
after boot, thus leading to a negative clock offset value between
realtime and monotonic clocks.

Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoFix: handle negative clock offset for lttng-ust metadata
Mathieu Desnoyers [Mon, 8 Feb 2016 22:13:25 +0000 (17:13 -0500)] 
Fix: handle negative clock offset for lttng-ust metadata

In the unlikely situation where a system sets its hardware clock
(CLOCK_REALTIME) to 0 (Epoch) after boot, the difference

  monotonic - realtime

becomes negative.

Fixup this situation by returning a 0 offset in this case.

This ensures that trace viewer implementations (e.g. babeltrace) which
currently cannot handle the negative offset (known bug) still work with
the generated traces.

This patch should be applied to master and stable-2.7.

Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoFix: test: append to LD_LIBRARY_PATH
Jonathan Rajotte [Thu, 14 Jan 2016 20:08:22 +0000 (15:08 -0500)] 
Fix: test: append to LD_LIBRARY_PATH

The overwriting of LD_LIBRARY_PATH can cause failure of tests when lttng-ust is
not installed in the default path and location is passed via LD_LIBRARY_PATH.

Signed-off-by: Jonathan Rajotte <jonathan.rajotte-julien@efficios.com>
Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoFix: test: use load_path instead of $1
Jonathan Rajotte [Thu, 14 Jan 2016 18:40:42 +0000 (13:40 -0500)] 
Fix: test: use load_path instead of $1

$1 is used for tap condition checking not the load path.

Signed-off-by: Jonathan Rajotte <jonathan.rajotte-julien@efficios.com>
Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoBump lttng-ust protocol version to 6.1
Jérémie Galarneau [Thu, 14 Jan 2016 16:08:53 +0000 (11:08 -0500)] 
Bump lttng-ust protocol version to 6.1

The introduction of enumerations in lttng-ust forces the protocol
to accomodate a new command which will only be used by lttng-ust
2.8+.

This is not a breaking change in the protocol since lttng-tools
does not _need_ to receive this command for normal operation, nor
does it issue it.

Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoAdd CTF enum type support for UST registry
Mathieu Desnoyers [Sun, 10 Jan 2016 16:50:47 +0000 (11:50 -0500)] 
Add CTF enum type support for UST registry

Derived from initial implementation by:
Geneviève Bastien <gbastien+lttng@versatic.net>

Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 years agoCleanup __lttng_print macro indentation
Jérémie Galarneau [Wed, 13 Jan 2016 20:41:44 +0000 (15:41 -0500)] 
Cleanup __lttng_print macro indentation

Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
This page took 0.042161 seconds and 4 git commands to generate.