[jboss-dev] My logging ultimatum

Adrian Brock abrock at redhat.com
Wed Dec 12 10:34:00 EST 2007


On Wed, 2007-12-12 at 09:01 -0600, David M. Lloyd wrote:
> On Wed, 12 Dec 2007 15:20:12 +0100
> Adrian Brock <abrock at redhat.com> wrote:
> 
> > You still miss the point. I'm not wrong. :-)
> > 
> > Forcing people to use the JDK api (broken)
> > because you don't like 3 jars (working)
> > isn't a solution to the problem.
> 
> Sure it is, assuming that the JDK api isn't broken, or at least not
> unfixably so.
> 

Assumptions...
The devil is always in the details. :-)

> > The deadlocking problems can only get worse
> > in the delegating LogManager solution.
> > You now have competing synchronization
> > strategies, e.g. jdk and log4j
> 
> What deadlocking problems?  What strategies?  If you do a custom
> LogManager, there *is* no synchronization strategy as far as I see -
> you're completely in control. Has it been demonstrated that the JDK api
> is broken?

See other post for two examples of "unfixed bugs".

Implementing the whole LogManager/Logger api
is almost certainly more code than jboss-logging-spi
and you'd need a seperate (non jdk) api to create something other
than the default logger implementation.

// static method == not overriddable
private static final Logger log = Logger.getLogger(className)

Your only reason for doing it is so you can have a
zero jar deployment (i.e. use the JDK by default)
but this is potentially broken as demonstrated.

In fact, this changes the burden for clients.

Previously a client without log4j or a log4j configuration
did no logging,

Now they will have to do some configuration
to avoid the potentially broken JDK calls.

> 
> > Conclusion: An unstable server is not a valid
> > trade-off to fix some aethestic considersation
> > about distributing a few small jars.
> 
> Sure I'll agree with that, but as far as I can see it hasn't been
> demonstrated that JDK logging would make your server unstable.

We've had lots of problems with logging causing server hangs
in the past. 

Logging is pervasive, it's not something
we should be changing on a whim.

And the correct question is the opposite:
"Is JDK logging demostratively as stable as what we've got now?"

>   Also,
> calling JAR dependencies "small" and "aesthetic" is really your
> opinion, not a factual contribution to the discussion.

And that there is a real problem that needs solving here
is your opinion.

You are arguing for a change, convince me
that a "few extra" java classes on the classpath
is a big problem that requires this "major upheaval".
(opinions in quotes :-).

P.S. Attacking my argument as only opinion is
a logical fallacy:
http://en.wikipedia.org/wiki/Ignoratio_elenchi
and certainly not a "factual contribution to the discussion". :-)
-- 
xxxxxxxxxxxxxxxxxxxxxxxxxxxx
Adrian Brock
Chief Scientist
JBoss, a division of Red Hat
xxxxxxxxxxxxxxxxxxxxxxxxxxxx




More information about the jboss-development mailing list