Loading apm-sniffer/apm-sdk-plugin/hystrix-1.x-plugin/src/main/java/org/apache/skywalking/apm/plugin/hystrix/v1/HystrixCommandGetFallbackInterceptor.java +3 −1 Original line number Diff line number Diff line Loading @@ -36,8 +36,10 @@ public class HystrixCommandGetFallbackInterceptor implements InstanceMethodsArou AbstractSpan activeSpan = ContextManager.createLocalSpan(enhanceRequireObjectCache.getOperationNamePrefix() + "/Fallback"); activeSpan.setComponent(ComponentsDefine.HYSTRIX); if (snapshot != null) { ContextManager.continued(snapshot); } } @Override public Object afterMethod(EnhancedInstance objInst, Method method, Object[] allArguments, Class<?>[] argumentsTypes, Loading apm-sniffer/apm-sdk-plugin/hystrix-1.x-plugin/src/main/java/org/apache/skywalking/apm/plugin/hystrix/v1/HystrixCommandRunInterceptor.java +3 −1 Original line number Diff line number Diff line Loading @@ -41,7 +41,9 @@ public class HystrixCommandRunInterceptor implements InstanceMethodsAroundInterc AbstractSpan activeSpan = ContextManager.createLocalSpan(enhanceRequireObjectCache.getOperationNamePrefix() + "/Execution"); activeSpan.setComponent(ComponentsDefine.HYSTRIX); if (snapshot != null) { ContextManager.continued(snapshot); } // Because of `fall back` method running in other thread. so we need capture concurrent span for tracing. enhanceRequireObjectCache.setContextSnapshot(ContextManager.capture()); Loading apm-sniffer/apm-sdk-plugin/hystrix-1.x-plugin/src/main/java/org/apache/skywalking/apm/plugin/hystrix/v1/SWExecutionHookWrapper.java +6 −2 Original line number Diff line number Diff line Loading @@ -41,7 +41,9 @@ public class SWExecutionHookWrapper extends HystrixCommandExecutionHook { public <T> void onStart(HystrixInvokable<T> commandInstance) { EnhancedInstance enhancedInstance = (EnhancedInstance)commandInstance; EnhanceRequireObjectCache enhanceRequireObjectCache = (EnhanceRequireObjectCache)enhancedInstance.getSkyWalkingDynamicField(); if (ContextManager.isActive()) { enhanceRequireObjectCache.setContextSnapshot(ContextManager.capture()); } actual.onStart(commandInstance); } Loading Loading @@ -166,7 +168,9 @@ public class SWExecutionHookWrapper extends HystrixCommandExecutionHook { @Override public <T> void onStart(HystrixCommand<T> commandInstance) { EnhancedInstance enhancedInstance = (EnhancedInstance)commandInstance; EnhanceRequireObjectCache enhanceRequireObjectCache = (EnhanceRequireObjectCache)enhancedInstance.getSkyWalkingDynamicField(); if (ContextManager.isActive()) { enhanceRequireObjectCache.setContextSnapshot(ContextManager.capture()); } actual.onStart(commandInstance); } Loading Loading
apm-sniffer/apm-sdk-plugin/hystrix-1.x-plugin/src/main/java/org/apache/skywalking/apm/plugin/hystrix/v1/HystrixCommandGetFallbackInterceptor.java +3 −1 Original line number Diff line number Diff line Loading @@ -36,8 +36,10 @@ public class HystrixCommandGetFallbackInterceptor implements InstanceMethodsArou AbstractSpan activeSpan = ContextManager.createLocalSpan(enhanceRequireObjectCache.getOperationNamePrefix() + "/Fallback"); activeSpan.setComponent(ComponentsDefine.HYSTRIX); if (snapshot != null) { ContextManager.continued(snapshot); } } @Override public Object afterMethod(EnhancedInstance objInst, Method method, Object[] allArguments, Class<?>[] argumentsTypes, Loading
apm-sniffer/apm-sdk-plugin/hystrix-1.x-plugin/src/main/java/org/apache/skywalking/apm/plugin/hystrix/v1/HystrixCommandRunInterceptor.java +3 −1 Original line number Diff line number Diff line Loading @@ -41,7 +41,9 @@ public class HystrixCommandRunInterceptor implements InstanceMethodsAroundInterc AbstractSpan activeSpan = ContextManager.createLocalSpan(enhanceRequireObjectCache.getOperationNamePrefix() + "/Execution"); activeSpan.setComponent(ComponentsDefine.HYSTRIX); if (snapshot != null) { ContextManager.continued(snapshot); } // Because of `fall back` method running in other thread. so we need capture concurrent span for tracing. enhanceRequireObjectCache.setContextSnapshot(ContextManager.capture()); Loading
apm-sniffer/apm-sdk-plugin/hystrix-1.x-plugin/src/main/java/org/apache/skywalking/apm/plugin/hystrix/v1/SWExecutionHookWrapper.java +6 −2 Original line number Diff line number Diff line Loading @@ -41,7 +41,9 @@ public class SWExecutionHookWrapper extends HystrixCommandExecutionHook { public <T> void onStart(HystrixInvokable<T> commandInstance) { EnhancedInstance enhancedInstance = (EnhancedInstance)commandInstance; EnhanceRequireObjectCache enhanceRequireObjectCache = (EnhanceRequireObjectCache)enhancedInstance.getSkyWalkingDynamicField(); if (ContextManager.isActive()) { enhanceRequireObjectCache.setContextSnapshot(ContextManager.capture()); } actual.onStart(commandInstance); } Loading Loading @@ -166,7 +168,9 @@ public class SWExecutionHookWrapper extends HystrixCommandExecutionHook { @Override public <T> void onStart(HystrixCommand<T> commandInstance) { EnhancedInstance enhancedInstance = (EnhancedInstance)commandInstance; EnhanceRequireObjectCache enhanceRequireObjectCache = (EnhanceRequireObjectCache)enhancedInstance.getSkyWalkingDynamicField(); if (ContextManager.isActive()) { enhanceRequireObjectCache.setContextSnapshot(ContextManager.capture()); } actual.onStart(commandInstance); } Loading