logging-log4j-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Paul Smith <Paul.Sm...@lawlex.com.au>
Subject RE: reconnecting to SocketHubAppender
Date Mon, 24 May 2004 23:58:30 GMT
> Still nice to be able to have the Receiver itself have a 
> reconnect ability,
> but the above was quicker for me at the time.

I've had a very brief look at how this might be accomplished.  It appears
that once the java.net.Socket instance has been created, I cannot see a way
to 'trap' when the Socket connection is broken.  There _are_ some methods on
the Socket class, isClosed, isConnected, which could help by periodic
inspection, however these have only been added since JDK 1.4.

I guess I could change the Receiver class so they can have this detection
code using reflection to detect if the methods are available, but I thought
I would check with the group on this first.

Does anyone else have a suggestion here?

cheers,

Paul Smith

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


Mime
View raw message