I wrote my own logback adapter class. When I start the program with the respective class file in the classpath directly (inside a directory), logback can't find it.
ERROR in ch.qos.logback.core.joran.action.AppenderAction - Could not create an Appender of type [com....MyAppender]. ch.qos.logback.core.util.DynamicClassLoadingException: Failed to instantiate type com....MyAppender
at ch.qos.logback.core.util.DynamicClassLoadingException: Failed to instantiate type com....MyAppender
at ch.qos.logback.core.util.OptionHelper.instantiateByClassNameAndParameter(OptionHelper.java:73)
at ch.qos.logback.core.util.OptionHelper.instantiateByClassName(OptionHelper.java:48)
If I put it in a jar file, everything is fine.
I saw that logback is using it's own class loader and my problem occurs when I start my application using sbt
and play
. So the problem may lay there.
Any ideas on how I could troubleshoot this?
Using:
"com.typesafe.play" %% "play" % "2.3.9"
"ch.qos.logback" % "logback-core" % "1.1.3",
sbt launcher version 0.13.8