[Simpleweb-Support] How to get noticed when Simple Server goes down ...
Brought to you by:
niallg
From: bagas <ba...@in...> - 2004-05-10 07:31:10
|
Hi, Currently I use Simple as simple as this .. Connection webserverConn = ConnectionFactory.getConnection(new HttpMainHandler(), new BufferedPipelineFactory(4096)); webserverConn.connect(new ServerSocket(80)); class HttpMainHandler implements ProtocolHandler { public void handle(Request req, Response resp) { //do something // } } is it running ServerSocket(80).close() would stop this server cleanly? Supposed ServerSocket(80) crashes because of any problem, how to get a noticed when this event occur? Thank you |