Documentation

Akka Integration

Kamon’s integration with Akka comes in the form of two modules: kamon-akka and kamon-akka-remote that bring bytecode instrumentation to gather metrics and perform automatic TraceContext propagation on your behalf.

Both the kamon-akka and kamon-akka-remote modules require you to start your application using the AspectJ Weaver Agent. Kamon will warn you at startup if you failed to do so.

Here is a quick list of the functionalities included on each module:

kamon-akka

  • Actor, Router and Dispatcher Metrics: This module hooks into Akka’s heart to give you a robust set of metrics based on the concepts already exposed by our metrics module.
  • Automatic TraceContext Propagation: This allows you to implicitly propagate the TraceContext across actor messages without having to change a single line of code and respecting the “follow the events” rather than “stick to the thread” convention as described in the event based threading model section of our core module.
  • Ask Pattern Timeout Warning: A utility that logs a warning with additional information when a usage of the Ask Pattern timesout.

kamon-akka-remote

  • Remote TraceContext Propagation: This bit of instrumentation allows basic TraceContext information to be propagated across the remoting channel provided by Akka. This hooks in the low level remoting implementation that ships with Akka, which means it will propagate the TraceContext when using plain remoting as well as when using the Akka Cluster.

If you are using Akka Remote 2.4 or Akka Cluster 2.4, please make sure that you are using the kamon-akka-remote_akka-2.4 artifact instead of the regular kamon-akka-remote.