Fix: move set base_path of session to URI configuration
authorJonathan Rajotte <jonathan.rajotte-julien@efficios.com>
Fri, 25 Oct 2019 22:12:00 +0000 (18:12 -0400)
committerJérémie Galarneau <jeremie.galarneau@efficios.com>
Tue, 5 Nov 2019 19:50:54 +0000 (14:50 -0500)
commite3876bf0e1d1be72170b53e9fcb39f3108f069dc
tree5e0d4c568aa45a302e00d85e6f0b624f8d33de63
parent6718a79b6e5cc242bc70ca581c62008a29a9d5a8
Fix: move set base_path of session to URI configuration

The load code still uses the "old" API to create and configure network
session output (lttng_create_session followed by
lttng_set_consumer_url). The session base_path is only set in the
cmd_create_session_from_descriptor function. This results in invalid
network output paths when using a loaded session configuration (xml).

While we might want to move the load code to the new API, there is a
case to be made in not breaking the previous API behaviour.

To restore the expected behaviour of lttng_set_consumer_url, move the
assignation of the session base_path to the cmd_set_consumer_uri
function (LTTNG_SET_CONSUMER_URI).

Both the previous and session descriptor based creation API uses this
code path when needed (network output).

Signed-off-by: Jonathan Rajotte <jonathan.rajotte-julien@efficios.com>
Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
src/bin/lttng-sessiond/cmd.c
src/bin/lttng-sessiond/session.c
src/bin/lttng-sessiond/session.h
tests/unit/test_session.c
This page took 0.026445 seconds and 5 git commands to generate.