Why can't I see Cinnamon metrics when running my Play application in development?

Why can't I see Cinnamon metrics when running my Play application in development?

A common cause for Cinnamon metrics not being reported in Play development is because Cinnamon does not currently support Play’s development mode*, which is the mode used by the Play server when started using the sbt run command. As a workaround, start your Play server using the sbt runProd command instead(sbt testProd for Play 2.5.x or older).

However, this is only recommended for when there is a need to see Cinnamon metrics while running a Play application locally. For all other scenarios, the sbt run command should be used. This is because Play's development mode offers many benefits including auto reloading, easy to read in-browser compilation errors and triggered execution.

For more information on getting started with Cinnamon & Play please see https://developer.lightbend.com/docs/cinnamon/latest/getting-started/play.html

*Why the Limitation
In order to instrument the code correctly, Cinnamon requires a forked Java Virtual Machine (JVM), which means a completely separate JVM is run as a different process in the operating system. Play’s development mode always runs in-process, which is what prevents Cinnamon metrics from being output.