|
From: George K. <gk...@in...> - 2004-01-05 19:35:19
|
Leif thanks for this.
I'll try the WrapperManager.start() fix you're suggesting.
Just to let you know however: I was exiting normally by just logging the
exception.
Then I tried to do this:
try {
...
}
catch (Exception e) {
log(e.getMessage());
throw new RuntimeException();
}
that is before stopping I throw a new RuntimeException just to stop the
program with an exception.
The wrapper still doesn't seem to restart the service however although the
program didn't terminate normally.
Thanks again both for the Wrapper and the excellent support you're providing
for it.
-George
----- Original Message -----
From: "Leif Mortenson" <le...@ta...>
To: <wra...@li...>; <gk...@in...>
Sent: Monday, January 05, 2004 10:41 AM
Subject: Re: [Wrapper-user] Service recovery
> George,
> If I read this correctly then your client application is throwing an
> error because it has lost
> contact with the server. When that happens the client is exiting by
> calling System.exit?
> Is that correct?
>
> I have high goals for the Wrapper, but so far it has not yet
> achieved sentience. At this
> point, when the application exits by calling System.exit, the Wrapper
> currently assumes
> that it wanted to exit. The Wrapper thus shuts down normally.
>
> If you want your client application to restart in this event, you
> will need to tell the
> Wrapper so by calling WrapperManager.restart(). Do this rather than
> calling System.exit.
>
> There is currently a feature request to be able to configure the
> wrapper so that it will
> restart on its own if System.exit is called, but that is not yet
> implemented.
>
> After the restart, you may also be interested in the
> wrapper.restart.delay property
> if your server will take a while to restart.
>
> Let me know if I misunderstood your question.
>
> Cheers,
> Leif
>
> George Kakarontzas wrote:
>
> > I have an RMI-based server and a number of PCs.
> > PCs run a wrapper encapsulated service. This service registers with
> > the RMI server and then sends heartbeat messages at regular intervals
> > at the server.
> > This is how the server knows that a PC is still alive.
> > If the server dies (e.g. the server machine reboots) the heartbeat
> > message at the PC will cause an Exception and the java PC program will
> > stop.
> > It was my understanding that in such cases the wrapper will figure out
> > that there is something wrong with the service and it will restart it
> > after a while.
> > This is not happening. If the server hangs for any reason the PCs
> > someone has to start the service manually to register the PCs again.
> > The PCs run Win XP Pro.
> > (1) Is my understanding correct? Is there recovery of failed services
> > in wrapper?
> > (2) If it is do you have any ideas why this isn't working?
> >
> > Thanks
> > -George
>
>
>
>
>
> -------------------------------------------------------
> This SF.net email is sponsored by: IBM Linux Tutorials.
> Become an expert in LINUX or just sharpen your skills. Sign up for IBM's
> Free Linux Tutorials. Learn everything from the bash shell to sys admin.
> Click now! http://ads.osdn.com/?ad_id=1278&alloc_id=3371&op=click
> _______________________________________________
> Wrapper-user mailing list
> Wra...@li...
> https://lists.sourceforge.net/lists/listinfo/wrapper-user
|