From: Jérémie Galarneau Date: Thu, 30 Jul 2015 20:49:49 +0000 (-0400) Subject: Consolidate agent event names regardless of user privilege X-Git-Tag: v2.8.0-rc1~530 X-Git-Url: https://git.lttng.org./?a=commitdiff_plain;h=d1ec8e200960bdcb62913be640a98e276ff6d97d;p=lttng-tools.git Consolidate agent event names regardless of user privilege Signed-off-by: Jérémie Galarneau --- diff --git a/src/bin/lttng-sessiond/event.c b/src/bin/lttng-sessiond/event.c index 08c7d4339..8727dfd9a 100644 --- a/src/bin/lttng-sessiond/event.c +++ b/src/bin/lttng-sessiond/event.c @@ -597,8 +597,8 @@ error: } /* - * Return the agent default event name to use by testing if the process is root - * or not. Return NULL on error. + * Return the default event name associated with the provided UST domain. Return + * NULL on error. */ const char *event_get_default_agent_ust_name(enum lttng_domain_type domain) { @@ -606,18 +606,10 @@ const char *event_get_default_agent_ust_name(enum lttng_domain_type domain) switch (domain) { case LTTNG_DOMAIN_LOG4J: - if (is_root) { - default_event_name = DEFAULT_SYS_LOG4J_EVENT_NAME; - } else { - default_event_name = DEFAULT_USER_LOG4J_EVENT_NAME; - } + default_event_name = DEFAULT_LOG4J_EVENT_NAME; break; case LTTNG_DOMAIN_JUL: - if (is_root) { - default_event_name = DEFAULT_SYS_JUL_EVENT_NAME; - } else { - default_event_name = DEFAULT_USER_JUL_EVENT_NAME; - } + default_event_name = DEFAULT_JUL_EVENT_NAME; break; case LTTNG_DOMAIN_PYTHON: default_event_name = DEFAULT_USER_PYTHON_EVENT_NAME; diff --git a/src/common/defaults.h b/src/common/defaults.h index c7e801d14..4d9c13d59 100644 --- a/src/common/defaults.h +++ b/src/common/defaults.h @@ -166,14 +166,12 @@ /* Default JUL domain channel name. */ #define DEFAULT_JUL_CHANNEL_NAME "lttng_jul_channel" /* Default JUL tracepoint name. This is a wildcard for the JUL domain. */ -#define DEFAULT_SYS_JUL_EVENT_NAME "lttng_jul:sys*" -#define DEFAULT_USER_JUL_EVENT_NAME "lttng_jul:user*" +#define DEFAULT_JUL_EVENT_NAME "lttng_jul:*" /* Default log4j domain channel name. */ #define DEFAULT_LOG4J_CHANNEL_NAME "lttng_log4j_channel" /* Default log4j tracepoint name. This is a wildcard for the log4j domain. */ -#define DEFAULT_SYS_LOG4J_EVENT_NAME "lttng_log4j:sys*" -#define DEFAULT_USER_LOG4J_EVENT_NAME "lttng_log4j:user*" +#define DEFAULT_LOG4J_EVENT_NAME "lttng_log4j:*" /* Default Python domain channel name. */ #define DEFAULT_PYTHON_CHANNEL_NAME "lttng_python_channel"