Class SendCallbackInterceptor
java.lang.Object
org.apache.skywalking.apm.plugin.pulsar.common.SendCallbackInterceptor
- All Implemented Interfaces:
org.apache.skywalking.apm.agent.core.plugin.interceptor.enhance.InstanceMethodsAroundInterceptor
public class SendCallbackInterceptor
extends Object
implements org.apache.skywalking.apm.agent.core.plugin.interceptor.enhance.InstanceMethodsAroundInterceptor
Interceptor for send callback enhanced instance.
Here is the intercept process steps:
1. Get the @SendCallbackEnhanceRequiredInfoand record the service url, context snapshot 2. Create the local span when the callback invokesendCompletemethod 3. Stop the local span whensendCompletemethod finished.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionafterMethod(org.apache.skywalking.apm.agent.core.plugin.interceptor.enhance.EnhancedInstance objInst, Method method, Object[] allArguments, Class<?>[] argumentsTypes, Object ret) voidbeforeMethod(org.apache.skywalking.apm.agent.core.plugin.interceptor.enhance.EnhancedInstance objInst, Method method, Object[] allArguments, Class<?>[] argumentsTypes, org.apache.skywalking.apm.agent.core.plugin.interceptor.enhance.MethodInterceptResult result) voidhandleMethodException(org.apache.skywalking.apm.agent.core.plugin.interceptor.enhance.EnhancedInstance objInst, Method method, Object[] allArguments, Class<?>[] argumentsTypes, Throwable t)
-
Constructor Details
-
SendCallbackInterceptor
public SendCallbackInterceptor()
-
-
Method Details
-
beforeMethod
public void beforeMethod(org.apache.skywalking.apm.agent.core.plugin.interceptor.enhance.EnhancedInstance objInst, Method method, Object[] allArguments, Class<?>[] argumentsTypes, org.apache.skywalking.apm.agent.core.plugin.interceptor.enhance.MethodInterceptResult result) throws Throwable - Specified by:
beforeMethodin interfaceorg.apache.skywalking.apm.agent.core.plugin.interceptor.enhance.InstanceMethodsAroundInterceptor- Throws:
Throwable
-
afterMethod
public Object afterMethod(org.apache.skywalking.apm.agent.core.plugin.interceptor.enhance.EnhancedInstance objInst, Method method, Object[] allArguments, Class<?>[] argumentsTypes, Object ret) throws Throwable - Specified by:
afterMethodin interfaceorg.apache.skywalking.apm.agent.core.plugin.interceptor.enhance.InstanceMethodsAroundInterceptor- Throws:
Throwable
-
handleMethodException
public void handleMethodException(org.apache.skywalking.apm.agent.core.plugin.interceptor.enhance.EnhancedInstance objInst, Method method, Object[] allArguments, Class<?>[] argumentsTypes, Throwable t) - Specified by:
handleMethodExceptionin interfaceorg.apache.skywalking.apm.agent.core.plugin.interceptor.enhance.InstanceMethodsAroundInterceptor
-