From df128123d44c8cdce4a54d1887bb2e50fceabaad Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=9D=8E=E5=9B=BD=E6=96=8C?= Date: Fri, 29 Apr 2022 10:52:20 +0800 Subject: [PATCH 1/2] fix akka filter --- .../instrumentations/akka_25/DispatcherInstrumentation.scala | 4 ++-- .../instrumentations/akka_26/DispatcherInstrumentation.scala | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/instrumentation/kamon-akka/src/akka-2.5/scala/kamon/instrumentation/akka/instrumentations/akka_25/DispatcherInstrumentation.scala b/instrumentation/kamon-akka/src/akka-2.5/scala/kamon/instrumentation/akka/instrumentations/akka_25/DispatcherInstrumentation.scala index ac73a7364..4c8719e28 100644 --- a/instrumentation/kamon-akka/src/akka-2.5/scala/kamon/instrumentation/akka/instrumentations/akka_25/DispatcherInstrumentation.scala +++ b/instrumentation/kamon-akka/src/akka-2.5/scala/kamon/instrumentation/akka/instrumentations/akka_25/DispatcherInstrumentation.scala @@ -123,7 +123,7 @@ object InstrumentNewExecutorServiceOnAkka24 { val systemTags = TagSet.of("akka.system", actorSystemName) - if(Kamon.filter(AkkaInstrumentation.TrackDispatcherFilterName).accept(dispatcherName)) { + if(Kamon.filter(AkkaInstrumentation.TrackDispatcherFilterName).accept(scheduledActionName)) { val defaultEcOption = factory.dispatcherPrerequisites.defaultExecutionContext if(dispatcherName == Dispatchers.DefaultDispatcherId && defaultEcOption.isDefined) { @@ -147,7 +147,7 @@ object InstrumentNewExecutorServiceOnAkka25 { val scheduledActionName = actorSystemName + "/" + dispatcherName val systemTags = TagSet.of("akka.system", actorSystemName) - if(Kamon.filter(AkkaInstrumentation.TrackDispatcherFilterName).accept(dispatcherName)) { + if(Kamon.filter(AkkaInstrumentation.TrackDispatcherFilterName).accept(scheduledActionName)) { val defaultEcOption = factory.dispatcherPrerequisites.defaultExecutionContext if(dispatcherName == Dispatchers.DefaultDispatcherId && defaultEcOption.isDefined) { diff --git a/instrumentation/kamon-akka/src/akka-2.6/scala/kamon/instrumentation/akka/instrumentations/akka_26/DispatcherInstrumentation.scala b/instrumentation/kamon-akka/src/akka-2.6/scala/kamon/instrumentation/akka/instrumentations/akka_26/DispatcherInstrumentation.scala index f7e5f19ad..1557c71cb 100644 --- a/instrumentation/kamon-akka/src/akka-2.6/scala/kamon/instrumentation/akka/instrumentations/akka_26/DispatcherInstrumentation.scala +++ b/instrumentation/kamon-akka/src/akka-2.6/scala/kamon/instrumentation/akka/instrumentations/akka_26/DispatcherInstrumentation.scala @@ -110,7 +110,7 @@ object InstrumentNewExecutorServiceOnAkka26 { val scheduledActionName = actorSystemName + "/" + dispatcherName val systemTags = TagSet.of("akka.system", actorSystemName) - if(Kamon.filter(AkkaInstrumentation.TrackDispatcherFilterName).accept(dispatcherName)) { + if(Kamon.filter(AkkaInstrumentation.TrackDispatcherFilterName).accept(scheduledActionName)) { val defaultEcOption = factory.dispatcherPrerequisites.defaultExecutionContext if(dispatcherName == Dispatchers.DefaultDispatcherId && defaultEcOption.isDefined) { From bdfce719822edcf2f947b3fc5a704045f3f3ecb8 Mon Sep 17 00:00:00 2001 From: liguobin233 Date: Thu, 19 May 2022 17:14:17 +0800 Subject: [PATCH 2/2] update test conf --- .../kamon-akka/src/test-common/resources/application.conf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/instrumentation/kamon-akka/src/test-common/resources/application.conf b/instrumentation/kamon-akka/src/test-common/resources/application.conf index 0e8f95654..1230b27f7 100644 --- a/instrumentation/kamon-akka/src/test-common/resources/application.conf +++ b/instrumentation/kamon-akka/src/test-common/resources/application.conf @@ -65,7 +65,7 @@ kamon { dispatchers { includes = [ "**" ] - excludes = [ "explicitly-excluded" ] + excludes = [ "DispatcherMetricsSpec/explicitly-excluded" ] } groups {