Skip to content

Commit

Permalink
use Play Environment's classloader when creating Kamon-related objects (
Browse files Browse the repository at this point in the history
  • Loading branch information
ivantopo authored Jun 27, 2022
1 parent 8b83252 commit 1212250
Showing 1 changed file with 2 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,8 @@ object GuiceModule {
Logger(classOf[KamonLoader]).info("Reconfiguring Kamon with Play's Config")
Logger(classOf[KamonLoader]).info(configuration.underlying.getString("play.server.provider"))
Logger(classOf[KamonLoader]).info(configuration.underlying.getString("kamon.trace.tick-interval"))

kamon.ClassLoading.changeClassLoader(environment.classLoader)
Kamon.initWithoutAttaching(configuration.underlying)

lifecycle.addStopHook { () =>
Expand Down

0 comments on commit 1212250

Please sign in to comment.