Because that doesn't belong in the LogManager. The underlying problem with the JDK
LogManager is that it is not equipped to handle the job it is designed for - so the best
solution is to strip configuration/etc out of it and let it basically just be a holder for
the root Logger and that is all. Essentially my LogManager is the minimum needed to do
the job (also taking into account factors like the fact that it has to be on the boot
classpath, so it really ought to be as small as possible).
That's why this is split into two parts. The first part is the LogManager (namely,
fixing the zillion bugs with the JDK one), and the second part is a JAR which is
deployable into the MC to insert a Handler into the root logger to map the log messages
over.
That's not to say that what you propose shouldn't be done though. There are a
bunch of things around logging that *could* be done, and that I've contemplated:
1) Make a native MetaData model for j.u.l.Loggers using SchemaResolverDeployer (pluggable
handlers, filters, etc).
2) Make a compatibility MetaData model for [jboss-]log4j.xml configuration deployments
(with adapter classes to allow log4j appenders to be called directly from j.u.l Handlers)
using SchemaResolverDeployer
3) Whip up a compatibility log4j API that maps transparently to j.u.l, use
jboss-classloading.xml to make it available to components
4) Or ditch 1-3 and stick with logbridge to map j.u.l to log4j, and instead come up with a
MetaData model for log4j using SchemaResolverDeployer and rewrite that service
The reason I held back (apart from my 100-mile-long todo list) was that I don't know
that log4j needs to be replaced. I mean, maybe it does but I'm not familiar with the
issues surrounding it within the AS. I noticed that it's still deployed the Old Way
as an MBean, and the configuration seems a bit crusty, but it seems functional at least.
Maybe log4j is still OK as the framework but the configuration needs to be updated? Do we
have the issues surrounding the current logging framework documented somewhere?
View the original post :
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4188577#...
Reply to the post :
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&a...