You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by "Somayaji, Archana" <Ar...@compuware.com> on 2003/05/21 00:52:28 UTC

tomcat4 embedded problem

I am  trying to use tomcat(4.0.6)bedded server. What beats me is why u would
want a user to give a predefines thread.sleep() time limit. Shouldnt the
user be able to use their apps till they decide to stop it. The problem with
using catalina/bootstrap classes is that i cannot define my own app_base and
create my own host. For this purpose the emedded class fits into our needs
as we can add remove hosts. 
Am i wrong in my understanding of the tomcat integration. I notice the await
method is not provided in embedded.java for tomcat4.0.6 but is, in 5.0. Is
there a workaround for this problem?
How can we use embedded to keep a application running till the user decides
to stop the process?

Regards
Archana Somayaji


Regards
Archana Somayaji

Optimal J Team
Phone: 248-737-7300 ext 11290
email: archana.somayaji@compuware.com




The contents of this e-mail are intended for the named addressee only. It
contains information that may be confidential. Unless you are the named
addressee or an authorized designee, you may not copy or use it, or disclose
it to anyone else. If you received it in error please notify us immediately
and then destroy it. 


---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-user-help@jakarta.apache.org


Re: tomcat4 embedded problem

Posted by Sriram N <sr...@yahoo.com>.
Hello:

When you mention the "Thread.sleep() time limit", I guess you are referring to
the example given in the Embedded class.

About 18 months ago, I had made use of Tomcat 4.0.1 classes and built my own
"server", which was a Swing app that made use of wrapper on Tomcat classes to
give a UI along the lines of Websphere Application Server's Management Console.

In my app, I did away with the server.xml, and instead loaded contexts, etc as
demonstrated by the "Embedded" example. 

If you take this route, you will find that it's very easy to use the Catalina
classes and the listeners, and just concentrate on developing the UI. At that
time, the LifeCycle Interface supported just the starting and stopping
notifications, I think Remy has added something along the lines of "Started"
and "Stopped" in 4.1.x

I don't think Embedded is intended to be used by itself, and is rather an
example on how you could make use of the Tomcat classes the way Embedded does. 

Note: If you take this route and load your app via a jar, you need to alter the
java classpath in case you have to serve jsp files.

-- Sriram

--- "Somayaji, Archana" <Ar...@compuware.com> wrote:
> I am  trying to use tomcat(4.0.6)bedded server. What beats me is why u would
> want a user to give a predefines thread.sleep() time limit. Shouldnt the
> user be able to use their apps till they decide to stop it. The problem with
> using catalina/bootstrap classes is that i cannot define my own app_base and
> create my own host. For this purpose the emedded class fits into our needs
> as we can add remove hosts. 
> Am i wrong in my understanding of the tomcat integration. I notice the await
> method is not provided in embedded.java for tomcat4.0.6 but is, in 5.0. Is
> there a workaround for this problem?
> How can we use embedded to keep a application running till the user decides
> to stop the process?
> 
> Regards
> Archana Somayaji
> 
> 
> Regards
> Archana Somayaji
> 
> Optimal J Team
> Phone: 248-737-7300 ext 11290
> email: archana.somayaji@compuware.com


__________________________________
Do you Yahoo!?
The New Yahoo! Search - Faster. Easier. Bingo.
http://search.yahoo.com

---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-user-help@jakarta.apache.org