Simple demo application in Scala with instrumentation.
Scala Version: 2.11.6
- Download the latest jar of Middleware java agent.
- Update the settings in
build.sbt
file as mentioned below and update the service name.lazy val root = (project in file(".")) .settings( ... (run / javaOptions) ++= Seq( "-javaagent:middleware-javaagent-{VERSION}.jar", "-Dotel.service.name={SCALA-APP-NAME}" ) ... )
- Run the following command to start the application.
MW_API_KEY=<YOUR_API_KEY> sbt run