Class BasePulsarConsumerInstrumentation
java.lang.Object
org.apache.skywalking.apm.agent.core.plugin.AbstractClassEnhancePluginDefine
org.apache.skywalking.apm.agent.core.plugin.interceptor.enhance.ClassEnhancePluginDefine
org.apache.skywalking.apm.agent.core.plugin.interceptor.enhance.ClassInstanceMethodsEnhancePluginDefine
org.apache.skywalking.apm.plugin.pulsar.common.define.BasePulsarConsumerInstrumentation
public class BasePulsarConsumerInstrumentation
extends org.apache.skywalking.apm.agent.core.plugin.interceptor.enhance.ClassInstanceMethodsEnhancePluginDefine
The pulsar consumer instrumentation use
ConsumerImpl as an enhanced class.
Consumer is a user-oriented interface and the implementations are ConsumerImpl and MultiTopicsConsumerImpl
The MultiTopicsConsumerImpl is a complex type with multiple ConsumerImpl to support uses receive messages from multiple topics. As each ConsumerImpl has it's own topic name and it is the initial unit of a single topic to receiving messages, so use ConsumerImpl as an enhanced class is an effective way.
Use messageProcessed as the enhanced method since pulsar consumer has multiple ways to receiving
messages such as sync method, async method and listeners. Method messageProcessed is a basic unit of ConsumerImpl, no
matter which way uses uses, messageProcessed will always record the message receiving.
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final StringFields inherited from class org.apache.skywalking.apm.agent.core.plugin.AbstractClassEnhancePluginDefine
CONTEXT_ATTR_NAME -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected org.apache.skywalking.apm.agent.core.plugin.match.ClassMatchorg.apache.skywalking.apm.agent.core.plugin.interceptor.ConstructorInterceptPoint[]org.apache.skywalking.apm.agent.core.plugin.interceptor.InstanceMethodsInterceptPoint[]Methods inherited from class org.apache.skywalking.apm.agent.core.plugin.interceptor.enhance.ClassInstanceMethodsEnhancePluginDefine
getStaticMethodsInterceptPointsMethods inherited from class org.apache.skywalking.apm.agent.core.plugin.interceptor.enhance.ClassEnhancePluginDefine
enhanceClass, enhanceInstance, getInstanceMethodsInterceptV2Points, getStaticMethodsInterceptV2PointsMethods inherited from class org.apache.skywalking.apm.agent.core.plugin.AbstractClassEnhancePluginDefine
define, enhance, isBootstrapInstrumentation, witnessClasses, witnessMethods
-
Field Details
-
CONSTRUCTOR_INTERCEPT_TYPE
- See Also:
-
CONSTRUCTOR_INTERCEPTOR_CLASS
- See Also:
-
INTERCEPTOR_CLASS
- See Also:
-
ENHANCE_METHOD
- See Also:
-
ENHANCE_METHOD_TYPE
- See Also:
-
ENHANCE_CLASS
- See Also:
-
-
Constructor Details
-
BasePulsarConsumerInstrumentation
public BasePulsarConsumerInstrumentation()
-
-
Method Details
-
enhanceClass
protected org.apache.skywalking.apm.agent.core.plugin.match.ClassMatch enhanceClass()- Specified by:
enhanceClassin classorg.apache.skywalking.apm.agent.core.plugin.AbstractClassEnhancePluginDefine
-
getConstructorsInterceptPoints
public org.apache.skywalking.apm.agent.core.plugin.interceptor.ConstructorInterceptPoint[] getConstructorsInterceptPoints()- Specified by:
getConstructorsInterceptPointsin classorg.apache.skywalking.apm.agent.core.plugin.AbstractClassEnhancePluginDefine
-
getInstanceMethodsInterceptPoints
public org.apache.skywalking.apm.agent.core.plugin.interceptor.InstanceMethodsInterceptPoint[] getInstanceMethodsInterceptPoints()- Specified by:
getInstanceMethodsInterceptPointsin classorg.apache.skywalking.apm.agent.core.plugin.AbstractClassEnhancePluginDefine
-