-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Amit,

On 3/8/12 11:55 AM, Amit wrote:
> Enabling debug level would add some extra handling
> 
> 1. We use slf4j & logback as our logging framework & tomcat uses
> jul logging. We would have to add jul-to-slf4j.jar to direct the
> jul messages to logback. This adds a performance overhead since
> the validation code & this class would be executed frequently.
> 
> 2. Specially adding a logger in logback.xml for this particular 
> class. We have multiple web applications which do not share the 
> logback.xml currently.
> 
> If the exception is not ignored and thrown right where it
> occurred, the stack trace would be enough to understand the root
> cause of the issue.
> 
> [snip]
> 
> I do not want to handle the exception. It would just help in
understanding the root cause in secs instead of mins since there could
many reasons why establishing a connection could fail. Seeing a null
pointer exception does not help at all.

So what you're saying is that you'd rather have someone here patch
Tomcat's code, then wait for another release, then upgrade all your
production systems and then see what the exception is, rather than
just enabling debug logging?

Now who's wasting time?

> I would appreciate if someone could detail on the benefits on
> having the code the way it is currently implemented i.e. why the
> exception is ignored instead of just throwing it there right away?

The method is not declared to throw any exceptions (except the
implicit RuntimeExceptions and Errors). Changing the API isn't
something that we like to do in stable releases unless it's absolutely
necessary. Filip would have to add his opinions on whether throwing
exceptions from validate is appropriate.

IMHO, debug logging is the right way to go in general. I don't think
the validate() method should throw anything, nor do I think that the
log level should be increased from debug to something higher.

- -chris
-----BEGIN PGP SIGNATURE-----
Version: GnuPG/MacGPG2 v2.0.17 (Darwin)
Comment: GPGTools - http://gpgtools.org
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

iEYEARECAAYFAk9ZDQEACgkQ9CaO5/Lv0PDTbgCguG7o2kPIOQliuFkuEby+gyFh
lFsAn0q6LrDPxSfE7C2wteVJr8waU34o
=hRYi
-----END PGP SIGNATURE-----

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org

Reply via email to