james-server-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "robert burrell donkin" <robertburrelldon...@gmail.com>
Subject Re: AbstractJamesHandler error handling
Date Wed, 04 Jul 2007 17:23:02 GMT
On 7/4/07, Stefano Bagnara <apache@bago.org> wrote:
> robert burrell donkin ha scritto:
> > handleConnection catches RuntimeException but not all throwable
> > exceptions. whenever an error is thrown this results in a silent
> > failure. what's the reasoning behind this?
> >
> > - robert
> It also catches all of the checked exceptions declared by the called
> code, right? (SocketException, InterruptedIOException, IOException).
> What kind of "Error" do you think should be catched (and could be
> succesfully handled) here?

successful handling is a different question. we've argued before about
specification compliance verses java best practice error handling.

i prefer servers to comply with the specification whenever possible.
so, in the case of IMAP IMHO JAMES should try to send an untagged BYE
with a message even when faced with an error.

> E.g: I don't think that catching an OOM in the connection handling is a
> good idea.

in the event of an OOM exception being thrown, i would expect an
application to log this fact so that an administrator can do something
about it. silently dropping connections (which is what happens ATM) is
IMHO not the right behaviour.

IMHO JAMES should comply with the specification and try to send an
untagged BYE with an error message before closing the connection. yes,
this may fail but IMHO at least an attempt should be made.

- robert

To unsubscribe, e-mail: server-dev-unsubscribe@james.apache.org
For additional commands, e-mail: server-dev-help@james.apache.org

View raw message