blob: 0a8d27be0376a5b8b091fad11924e7e45e77be7a (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
|
package kamon.actor
import akka.actor.ActorRef
import akka.util.Timeout
import kamon.TraceContext
trait TraceableAskSupport {
implicit def pimpWithTraceableAsk(actorRef: ActorRef) = new TraceableAskableActorRef(actorRef)
}
// FIXME: This name sucks
class TraceableAskableActorRef(val actorRef: ActorRef) {
def ??(message: Any)(implicit timeout: Timeout) = akka.pattern.ask(actorRef, TraceableMessage(TraceContext.current.get.fork, message))
}
|