10#define LTTNG_SESSION_H
16#include <lttng/constant.h>
17#include <lttng/lttng-error.h>
18#include <lttng/lttng-export.h>
19#include <lttng/session-descriptor.h>
26#include <lttng/constant.h>
27#include <lttng/map/channel-descriptor.h>
28#include <lttng/map/channel-set.h>
34#define LTTNG_SESSION_PADDING1 8
140 char alignment_padding[4];
146 char padding[LTTNG_SESSION_PADDING1];
291 const char *output_url);
346 const char *output_url,
347 unsigned int live_timer_period);
lttng_error_code
General error codes.
Definition lttng-error.h:49
#define LTTNG_NAME_MAX
Maximum name length.
Definition constant.h:54
lttng_map_channel_type
Type of a map channel.
Definition channel-type.h:25
lttng_trace_format
Trace format of a recording session.
Definition session-descriptor.h:51
int lttng_destroy_session_no_wait(const char *session_name)
Initiates the destruction operation of the recording session named session_name.
lttng_get_session_trace_format_status
Return type of lttng_get_session_trace_format().
Definition session.h:55
int lttng_list_sessions(struct lttng_session **sessions)
Sets *sessions to the summaries of all the available recording sessions.
int lttng_create_session_live(const char *session_name, const char *output_url, unsigned int live_timer_period)
Creates a recording session named session_name in live mode, optionally setting its URL to output_url...
int lttng_set_session_shm_path(const char *session_name, const char *shm_dir)
Sets the path of the directory containing the shared memory files holding the event record channel ri...
enum lttng_get_session_trace_format_status lttng_get_session_trace_format(const struct lttng_session *session, enum lttng_trace_format *format)
Sets *format to the trace format of the recording session summarized by session.
enum lttng_error_code lttng_session_get_creation_time(const struct lttng_session *session, uint64_t *creation_timestamp)
Sets *creation_timestamp to the timestamp of the creation of the recording session summarized by sess...
enum lttng_error_code lttng_create_session_ext(struct lttng_session_descriptor *session_descriptor)
Creates a recording session from the recording session descriptor session_descriptor.
enum lttng_error_code lttng_destroy_session_ext(const char *session_name, struct lttng_destruction_handle **handle)
Initiates a destruction operation of the recording session named session_name.
int lttng_destroy_session(const char *session_name)
Destroys the recording session named session_name, blocking until the operation completes.
enum lttng_get_session_shm_path_status lttng_get_session_shm_path_override(const struct lttng_session *session, const char **shm_dir)
Sets *shm_dir to the path of the custom directory on the local file system containing the shared memo...
lttng_get_session_shm_path_status
Return type of lttng_get_session_shm_path_override().
Definition session.h:40
enum lttng_error_code lttng_session_get_map_channel_by_name(const char *session_name, enum lttng_map_channel_type type, const char *name, struct lttng_map_channel **channel)
Sets *channel to the map channel of the recording session named session_name having the type type and...
int lttng_create_session_snapshot(const char *session_name, const char *output_url)
Creates a recording session named session_name in snapshot mode, optionally setting the URL of its in...
int lttng_create_session(const char *session_name, const char *output_url)
Creates a recording session named session_name in local or network streaming mode,...
enum lttng_error_code lttng_session_list_map_channels(const char *session_name, enum lttng_map_channel_type type, struct lttng_map_channel_set **channels)
Sets *channels to the map channels of the type type of the recording session named session_name.
enum lttng_error_code lttng_session_add_map_channel(const char *session_name, const struct lttng_map_channel_descriptor *descriptor)
Adds the map channel described by descriptor to the recording session named session_name.
@ LTTNG_GET_SESSION_TRACE_FORMAT_STATUS_OK
Success.
Definition session.h:57
@ LTTNG_GET_SESSION_TRACE_FORMAT_STATUS_INVALID
Unsatisfied precondition.
Definition session.h:60
@ LTTNG_GET_SESSION_SHM_PATH_STATUS_INVALID_PARAMETER
Unsatisfied precondition.
Definition session.h:48
@ LTTNG_GET_SESSION_SHM_PATH_STATUS_OK
Success.
Definition session.h:42
@ LTTNG_GET_SESSION_SHM_PATH_STATUS_UNSET
Shared memory path isn't set.
Definition session.h:45
Recording session destruction handle (opaque type).
Recording session handle.
Definition handle.h:44
Map channel descriptor (opaque type).
Set of map channels (opaque type).
Map channel (opaque type).
Recording session descriptor (opaque type).
Recording session summary.
Definition session.h:75
uint32_t enabled
1 if this recording session is active (started), or 0 otherwise.
Definition session.h:96
char path[PATH_MAX]
Human-readable representation of the output (local or remote).
Definition session.h:84
unsigned int live_timer_interval
Period (µs) of the live timers of the event record channels of this recording session,...
Definition session.h:121
char name[LTTNG_NAME_MAX]
Name.
Definition session.h:77
uint32_t snapshot_mode
1 if this recording session was created in snapshot mode, or 0 otherwise.
Definition session.h:108