SLF4J events

This backend allows you to log all events. It is using SLF4J which gives you the possibility to select the logging implementation of your choice. Using this backend in combination with the SLF4J reporter will give you insight into both metrics and events in your instrumented application.

Cinnamon dependency

First make sure that your build is configured to use the Cinnamon Agent.

Next add the SLF4J event backend dependency to your build:

sbt
libraryDependencies += Cinnamon.library.cinnamonSlf4jEvents
Maven
<dependency>
  <groupId>com.lightbend.cinnamon</groupId>
  <artifactId>cinnamon-slf4j-events_2.11</artifactId>
  <version>2.5.0</version>
</dependency>
Gradle
dependencies {
  compile group: 'com.lightbend.cinnamon', name: 'cinnamon-slf4j-events_2.11', version: '2.5.0'
}

Configuration

Make sure actors are configured for instrumentation. For example, you can instrument all application actors by class by adding an application.conf file to the folder src/main/resources with the following content:

cinnamon.akka {
  actors {
    "/user/*" {
      report-by = class
    }
  }
}

Run

Run your application and events will be published via SLF4J. Make sure to add a logging implementation, e.g. Log4J(2), Logback, Logstash, etc., in order to see any output.