This is an automated email from the ASF dual-hosted git repository.

wusheng pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-skywalking.git


The following commit(s) were added to refs/heads/master by this push:
     new 5ea5471  add ContextManager.isActive() (#1070)
5ea5471 is described below

commit 5ea5471c96dc78365fadae13eb0a0d30925951bd
Author: carlvine500 <carlvine...@163.com>
AuthorDate: Thu Apr 12 11:35:19 2018 +0800

    add ContextManager.isActive() (#1070)
---
 .../org/apache/skywalking/apm/agent/core/context/ContextManager.java  | 4 ++++
 1 file changed, 4 insertions(+)

diff --git 
a/apm-sniffer/apm-agent-core/src/main/java/org/apache/skywalking/apm/agent/core/context/ContextManager.java
 
b/apm-sniffer/apm-agent-core/src/main/java/org/apache/skywalking/apm/agent/core/context/ContextManager.java
index 16b6a1d..b2d3a99 100644
--- 
a/apm-sniffer/apm-agent-core/src/main/java/org/apache/skywalking/apm/agent/core/context/ContextManager.java
+++ 
b/apm-sniffer/apm-agent-core/src/main/java/org/apache/skywalking/apm/agent/core/context/ContextManager.java
@@ -200,4 +200,8 @@ public class ContextManager implements 
TracingContextListener, BootService, Igno
     public void afterFinished(IgnoredTracerContext traceSegment) {
         CONTEXT.remove();
     }
+
+    public static boolean isActive() {
+        return CONTEXT.get() != null;
+    }
 }

-- 
To stop receiving notification emails like this one, please contact
wush...@apache.org.

Reply via email to