[lttng-dev] [PATCH lttng-ust] Fix: Warn when log4j version is too old

Mathieu Desnoyers mathieu.desnoyers at efficios.com
Fri Oct 31 15:39:33 EDT 2014


Merged, thanks!

Mathieu

----- Original Message -----
> From: "Christian Babeux" <christian.babeux at efficios.com>
> To: lttng-dev at lists.lttng.org
> Cc: "mathieu desnoyers" <mathieu.desnoyers at efficios.com>, "Christian Babeux" <christian.babeux at efficios.com>
> Sent: Friday, October 31, 2014 3:33:59 PM
> Subject: [PATCH lttng-ust] Fix: Warn when log4j version is too old
> 
> Signed-off-by: Christian Babeux <christian.babeux at efficios.com>
> ---
>  liblttng-ust-java-agent/java/org/lttng/ust/agent/LTTngAgent.java | 1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/liblttng-ust-java-agent/java/org/lttng/ust/agent/LTTngAgent.java
> b/liblttng-ust-java-agent/java/org/lttng/ust/agent/LTTngAgent.java
> index 47b4519..f7e1e38 100644
> --- a/liblttng-ust-java-agent/java/org/lttng/ust/agent/LTTngAgent.java
> +++ b/liblttng-ust-java-agent/java/org/lttng/ust/agent/LTTngAgent.java
> @@ -119,6 +119,7 @@ public class LTTngAgent {
>  		try {
>  			logging.getDeclaredMethod("getTimeStamp");
>  		} catch (NoSuchMethodException e) {
> +			System.err.println("Warning: The loaded log4j library is too old. Log4j
> tracing with LTTng will be disabled.");
>  			return false;
>  		} catch (NullPointerException e) {
>  			/* Should never happen */
> --
> 2.1.1
> 
> 

-- 
Mathieu Desnoyers
EfficiOS Inc.
http://www.efficios.com



More information about the lttng-dev mailing list