Article View: borland.public.jbuilder.java.api
Article #934Re: an idea to consider
From: Owen Green
Date: Sun, 07 Jul 2002 01:58
Date: Sun, 07 Jul 2002 01:58
23 lines
1863 bytes
1863 bytes
"Alan Shiers" <ashiers@hfx.eastlink.ca> wrote in message news:3D279D25.59AA52E@hfx.eastlink.ca... > > Then I got the bright idea...why not encorporate a threaded class as > part of the server app that has another ServerSocket object in it set to > listen only to the loopback address (127.0.0.1). Then include with the > program one additional class with its own main() method and a Socket > object, which I can use to execute solely for the purposes to > communicating with the running server app and tell it to shut down. > > That would work, wouldn't it? > > For those of you who are Linux savy, maybe you see some problems with > this? > I'd like to hear any comments you may have. The ShutdownHook class can be used to catch the KILL signal and do just that :) You could knock up a nice shell script, like the one apache has, to have the start, stop etc. presented. This could be invoked in a startup script and / or from the command line.
Technical Details
Message-ID:
<3d27a0b2_2@dnews>Path:
arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!sn-xit-02!sn-xit-08!supernews.com!priapus.visi.com!news-out.visi.com!hermes.visi.com!eusc.inter.net!newsfeed01.sul.t-online.de!t-online.de!dnewsReferences:
<3D279D25.59AA52E@hfx.eastlink.ca>Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 1089d0,4157c064c52214d4 X-Google-Attributes: gid1089d0,public X-Google-ArrivalTime: 2002-07-06 19:11:32 PST From: "Owen Green" <owen@begonefoulmachine.kennulz.demon.co.uk> Newsgroups: borland.public.jbuilder.java.api References: <3D279D25.59AA52E@hfx.eastlink.ca> Subject: Re: an idea to consider Date: Sun, 7 Jul 2002 02:58:10 +0100 Lines: 29 X-Priority: 3 X-MSMail-Priority: Normal X-Newsreader: Microsoft Outlook Express 5.00.2919.6700 X-MimeOLE: Produced By Microsoft MimeOLE V5.00.2919.6700 NNTP-Posting-Host: 193.237.54.9 Message-ID: <3d27a0b2_2@dnews> X-Trace: dnews 1026007218 193.237.54.9 (6 Jul 2002 19:00:18 -0700) Path: arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!sn-xit-02!sn-xit-08!supernews.com!priapus.visi.com!news-out.visi.com!hermes.visi.com!eusc.inter.net!newsfeed01.sul.t-online.de!t-online.de!dnews