#include <common/error.h>
#include <common/macros.h>
-#include <common/config/config.h>
+#include <common/config/session-config.h>
#include <lttng/lttng.h>
/* Don't want to reference snapshot-internal.h here */
* Version information for the machine interface.
*/
struct mi_lttng_version {
- char version[NAME_MAX]; /* Version number of package */
+ char version[LTTNG_NAME_MAX]; /* Version number of package */
uint32_t version_major; /* LTTng-Tools major version number */
uint32_t version_minor; /* LTTng-Tools minor version number */
uint32_t version_patchlevel; /* LTTng-Tools patchlevel version number */
- char version_commit[NAME_MAX]; /* Commit hash of the current version */
- char version_name[NAME_MAX];
- char package_url[NAME_MAX]; /* Define to the home page for this package. */
+ char version_commit[LTTNG_NAME_MAX]; /* Commit hash of the current version */
+ char version_name[LTTNG_NAME_MAX];
+ char package_url[LTTNG_NAME_MAX]; /* Define to the home page for this package. */
};
/* Strings related to command */
extern const char * const mi_lttng_element_perf_counter_context;
/* Strings related to pid */
-extern const char * const mi_lttng_element_processes;
-extern const char * const mi_lttng_element_process;
extern const char * const mi_lttng_element_pid_id;
/* Strings related to save command */
*/
int mi_lttng_process(struct mi_writer *writer, pid_t pid , const char *name,
int is_open);
+
+/*
+ * TODO: move pid of lttng list -u to process semantic on mi api bump
+ * Machine interface of a Process.
+ *
+ * writer An instance of a machine interface writer.
+ * pid A PID.
+ *
+ * is_open Defines whether or not the session element shall be closed.
+ * This should be used carefully and the client
+ * must close the pid element.
+ * Use case: nested addition information on a domain
+ * ex: channel event.
+ *
+ * Returns zero if the element's value could be written.
+ * Negative values indicate an error.
+ */
+int mi_lttng_pid(struct mi_writer *writer, pid_t pid , const char *name,
+ int is_open);
/*
* Machine interface: open a targets element.
*