tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "William L. Thomson Jr." <>
Subject Re: Bootstrap redirecting stdout/err via system.set
Date Mon, 03 Dec 2007 18:19:01 GMT

On Wed, 2007-11-28 at 18:28 +0100, jean-frederic clere wrote:
> William L. Thomson Jr. wrote:
> >
> > 
> > But I believe the argument is that applications should do their own
> > stderr/out redirection and not to it external of the app. As in not via
> > bash/shell redirection and sending that to a log file. The app should be
> > doing that internally.
> That is what daemon is doing.

Was that referring to an external daemon, as in jsvc, or the Daemon as
part of the class that is called in Bootstrap and responsible for
starting Tomcat?

Seems odd no one has commented on this so far. Unless it's due to
ignorance on my behalf. I am not that familiar with Tomcat source code,
or internals on starting and etc. Slowly tracing things down there. So
please excuse my lack of knowledge or ignorance there.

Now I noticed several classes including Embedded make a System.setErr
call. If any of those are invoked as part of Boostrap starting, no clue
atm. But seems like if that logic exists in other place. If Boostrap or
something it called, invokes doesn't set that. Then it makes a good case
that it should be set. Since it's set when Tomcat is started via other

I have since switched my own apps over to this. It's quite nice and
provides me a way to catch what otherwise might have been uncaught
exceptions. Via logging them to a file that I have redirected stderr and
stdout to.

William L. Thomson Jr.

View raw message