Appdynamics 中未检测到传入的 kafka 指标 - spring kafka
Incoming kafka metrics are not detected in Appdynamcis - springkafka
我们正在使用 springboot 和 springkafka 来消费和处理消息,并使用 Appdynamics 来捕获性能指标。
Appdynamics 正在捕获外出主题和指标,但未检测传入主题和我们尝试的 metrics.The 解决方案
后台自定义主题名称
将 enable-kafka-consumer 设置为 true
自定义-interceptors.xml如下所述
<custom-interceptors>
<custom-interceptor>
<interceptor-class-name>com.singularity.KafkaMarkerMethodInterceptor</interceptor-class-name>
<match-class type="matches-class">
<name filter-type="equals">my-fully-qualified-class-name</name>
</match-class>
<match-method>
<name>my-method-name</name>
</match-method>
</custom-interceptor>
在任何情况下,topics/metrics 都不会被发现。我们需要帮助来解决这个问题。
参考:
- https://docs.appdynamics.com/pages/viewpage.action?pageId=45490384#AppAgentNodeProperties(AE)-enable-kafka-consumer
- https://docs.appdynamics.com/22.1/en/application-monitoring/configure-instrumentation/backend-detection-rules/java-backend-detection/apache-kafka-consumer-backends
- https://docs.appdynamics.com/display/PRO44/Java+Backend+Detection#JavaBackendDetection-kafka
所有设置都正确,但我们必须指向 custom-interceptors 中的 spring kafka class 而不是我们的 class 名称。xml
<custom-interceptors>
<custom-interceptor>
<interceptor-class-name>com.singularity.KafkaMarkerMethodInterceptor</interceptor-class-name>
<match-class type="matches-class">
<name filter-type="equals">org.springframework.kafka.listener.KafkaMessageListenerContainer$ListenerConsumer</name>
</match-class>
<match-method>
<name>run</name>
</match-method>
</custom-interceptor>
</custom-interceptors>
我们正在使用 springboot 和 springkafka 来消费和处理消息,并使用 Appdynamics 来捕获性能指标。
Appdynamics 正在捕获外出主题和指标,但未检测传入主题和我们尝试的 metrics.The 解决方案
后台自定义主题名称
将 enable-kafka-consumer 设置为 true
自定义-interceptors.xml如下所述
<custom-interceptors> <custom-interceptor> <interceptor-class-name>com.singularity.KafkaMarkerMethodInterceptor</interceptor-class-name> <match-class type="matches-class"> <name filter-type="equals">my-fully-qualified-class-name</name> </match-class> <match-method> <name>my-method-name</name> </match-method> </custom-interceptor>
在任何情况下,topics/metrics 都不会被发现。我们需要帮助来解决这个问题。
参考:
- https://docs.appdynamics.com/pages/viewpage.action?pageId=45490384#AppAgentNodeProperties(AE)-enable-kafka-consumer
- https://docs.appdynamics.com/22.1/en/application-monitoring/configure-instrumentation/backend-detection-rules/java-backend-detection/apache-kafka-consumer-backends
- https://docs.appdynamics.com/display/PRO44/Java+Backend+Detection#JavaBackendDetection-kafka
所有设置都正确,但我们必须指向 custom-interceptors 中的 spring kafka class 而不是我们的 class 名称。xml
<custom-interceptors>
<custom-interceptor>
<interceptor-class-name>com.singularity.KafkaMarkerMethodInterceptor</interceptor-class-name>
<match-class type="matches-class">
<name filter-type="equals">org.springframework.kafka.listener.KafkaMessageListenerContainer$ListenerConsumer</name>
</match-class>
<match-method>
<name>run</name>
</match-method>
</custom-interceptor>
</custom-interceptors>