Philippe,
maybe that whole thing would be easier if there would be a public interface
to the server. At the moment, the only public, documented way to talk to
JOnAS from outside is to use the batch scripts. Why not making a public
document that describes how to use all that what I can do with the scripts
in Java ways? I mean, it would be best to tell the end user that there is a
method "stopServer" and so on (and not methods in the administration tool),
so everyone can do what he wants, and no one has to go over the
administration tool to talk to the server (what is some kind of strange from
my sight; I also do not talk to Microsoft Outlook if I want to talk to my
POP3 server). This is part one of my idea. Part two would be to start JOnAS
by method call, not by JVM call, so JOnAS needs not to call System.exit()
since JOnAS does not know of it he has exclusive rights on the JVM. This
means, give that task that started the JVM the control of the JVM. If
someone wants to start a new JVM, he has to make sure (by writing some kind
of service control thread) that this JVM is killed if JOnAS is stopped. If
someone does not start a new JVM (e. g. he wants to have JOnAS be run in the
same JVM as some other services) JOnAS has no problem with this since it
does not call System.exit(). Sad but true, what we need, is what the JVM
lacks: WindowsNT, Linux and every other "good" OS has a facility where I can
control services (start/pause/resume/stop). The JVM was not intended to run
services (so tools like JServ where invented). Indeed, what we need is a
layer between the JVM and services like JOnAS, that controls that services,
but runs them inside the same VM. Maybe we should build an interest group
and talk to the Java Communicty Process?
----- Original Message -----
From: "Philippe Coq" <[EMAIL PROTECTED]>
To: "Halas, Miroslav" <[EMAIL PROTECTED]>
Cc: "Meghani, Murad" <[EMAIL PROTECTED]>;
<[EMAIL PROTECTED]>
Sent: Friday, August 10, 2001 8:37 AM
Subject: Re: How to stop Jonas cleanly?
> "Halas, Miroslav" wrote:
> >
> > Philippe,
> >
> > The problem Murad is working on is that we take Jonas, we embed it with
> > Jetty and several other processes which runs in separate threads inside
of
> > the same JVM as a part of our very lightweight J2EE like server
> > When we want to stop this server we want to stop all these processes so
they
> > can clean up and end gracefully and then when everything is done,
shutdown
> > the JVM so in this case we are responsible for System.exit(0) and not
Jonas.
> >
> > Do you think the best solution for this would be to change stopServer()
to
> > do not call System.exit(0) and add new method
> >
> > public void killServer() throws RemoteException {
> > stopServer()
> > System.exit(0);
> > }
> >
> > Thanks,
> >
> > Miro Halas
>
> Hi,
> yes, we can add killServer in the interface AdmInterface
> implement it as you said, and change JonASAdmin
> in order that the stopserver of JonasAdmin calls killServer
> instead of stopServer.
> I am not sure that it is worth to implement a new command
> in JonASAdmin for stopping the server without killing it
> (if not, there is more work ,find a new command, change the
> public documentation etc...)
> I think that Murad only need to call stopServer on the
> adm object in the server and not via JOnASAdmin, true?
>
> --
> Philippe
>
> Philippe Coq Evidian Phone: (33) 04 76 29 78 49
> Bull S.A - 1 rue de Provence - 38432 Echirolles Cedex France
> Download our EJBServer at http://www.objectweb.org
> ----
> To unsubscribe, send email to [EMAIL PROTECTED] and
> include in the body of the message "unsubscribe jonas-users".
> For general help, send email to [EMAIL PROTECTED] and
> include in the body of the message "help".
>
----
To unsubscribe, send email to [EMAIL PROTECTED] and
include in the body of the message "unsubscribe jonas-users".
For general help, send email to [EMAIL PROTECTED] and
include in the body of the message "help".