Skip to content

ConfigurationLoggingJBoss7

dlecan edited this page Feb 25, 2013 · 2 revisions

If you plan to use JBoss7, you have to know that Play2 and JBoss7 don't "play" well together.

Why ? Because Play2 has been designed to use SLF4J & Co (**-over-slf4j, **-to-slf4j, ...) and Logback and to be executed standalone. Some configurations are hardcoded and cannot be overriden by JBoss.

You can try to follow classic logging configuration for JBoss, but you will fail, for example, to redirect correctly System.out logs.

To solve this incompatibilty, you can add a new dependency in your Play project. It will disable Play logging.

val appDependencies = Seq(
  // ... Actual dependencies
  "com.github.play2war.ext" %% "redirect-playlogger" % "1.0.1" // add this after your others dependencies
)

Warning, internal conf/logger.xml will be ignored. Configure logging output with standard JBoss logging features.

Clone this wiki locally