I read about how to make java.util.logging logs and System.(out|err) output be piped to slf4j:
But it requires some jar/classes and code to be executed at jetty startup. Basically something like:
SLF4JBridgeHandler.install() // to pipe j.u.l
SysOutOverSLF4J.sendSystemOutAndErrToSLF4J() // to pipe System.(out|err)
I know how to add required jars/classes available to jetty (just add sysout-over-slf4j.jar and jul-to-slf4j.jar to $JETTY_HOME/lib/ext), but I don't know how can I run the code abobe in the server startup so that jetty configures the consolidated outputs (sysout and j.u.l) to slf4j. I can run that code per webapp, but to make things correct, it should be done by jetty, and not by every webapp that needs this behaviour.
Should this be done in a different way? Is there a non-voodo way to do this?
Please make your answer be for jetty version >= 8