diff options
author | Ivan Topolnak <ivantopo@gmail.com> | 2013-09-25 19:45:54 -0300 |
---|---|---|
committer | Ivan Topolnak <ivantopo@gmail.com> | 2013-09-25 19:45:54 -0300 |
commit | 604d5801332838f8bea25fe25cb8df5dbb82af08 (patch) | |
tree | ad107e08888f0aad82899d394ec738c5da29dd5a /kamon-core/src/main/scala/kamon/instrumentation/ActorRefTellInstrumentation.scala | |
parent | 50823a3cc4f6644d569255c7e04423c36eedf295 (diff) | |
download | Kamon-604d5801332838f8bea25fe25cb8df5dbb82af08.tar.gz Kamon-604d5801332838f8bea25fe25cb8df5dbb82af08.tar.bz2 Kamon-604d5801332838f8bea25fe25cb8df5dbb82af08.zip |
wip
Diffstat (limited to 'kamon-core/src/main/scala/kamon/instrumentation/ActorRefTellInstrumentation.scala')
-rw-r--r-- | kamon-core/src/main/scala/kamon/instrumentation/ActorRefTellInstrumentation.scala | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/kamon-core/src/main/scala/kamon/instrumentation/ActorRefTellInstrumentation.scala b/kamon-core/src/main/scala/kamon/instrumentation/ActorRefTellInstrumentation.scala index fdd7b696..d92d7f6c 100644 --- a/kamon-core/src/main/scala/kamon/instrumentation/ActorRefTellInstrumentation.scala +++ b/kamon-core/src/main/scala/kamon/instrumentation/ActorRefTellInstrumentation.scala @@ -34,6 +34,7 @@ class ActorRefTellInstrumentation { @Aspect("""perthis(actorCellCreation(akka.actor.ActorSystem, akka.actor.ActorRef, akka.actor.Props, akka.dispatch.MessageDispatcher, akka.actor.ActorRef))""") class ActorCellInvokeInstrumentation { var instrumentation = ActorReceiveInvokeInstrumentation.noopPreReceive + var self: ActorRef = _ // AKKA 2.2 introduces the dispatcher parameter. Maybe we could provide a dual pointcut. @Pointcut("execution(akka.actor.ActorCell.new(..)) && args(system, ref, props, dispatcher, parent)") @@ -42,6 +43,7 @@ class ActorCellInvokeInstrumentation { @After("actorCellCreation(system, ref, props, dispatcher, parent)") def registerMetricsInRegistry(system: ActorSystem, ref: ActorRef, props: Props, dispatcher: MessageDispatcher, parent: ActorRef): Unit = { instrumentation = kamon.Instrument.instrumentation.receiveInvokeInstrumentation(system, ref, props, dispatcher, parent) + self = ref } @@ -53,7 +55,7 @@ class ActorCellInvokeInstrumentation { import ProceedingJoinPointPimp._ val (originalEnvelope, ctx) = instrumentation.preReceive(envelope) - //println("Test") + //println(s"====>[$ctx] ## [${originalEnvelope.sender}] => [$self] --- ${originalEnvelope.message}") ctx match { case Some(c) => { //MDC.put("uow", c.userContext.get.asInstanceOf[String]) |