You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by Joe <be...@yahoo.com> on 2003/02/08 21:57:19 UTC
Accessing Singleton
Hi,
What would be the best way to access a singleton
running in the JVM that runs Tomcat?
What I have is this:
The classes in question are singleton because they
take a huge amount of time to start up but little to
call methods.
Tomcat contains one webapp, that has those singletons
running (among others) so each request (SOAP) doesn't
have to wait ages for a new instance of that class to
be created.
I need to be able to access the running singleton from
the console on the same machine as tomcat is running.
IE tomcat is running, I open up the console and run
bat file which calls a class which loads the singleton
and calls a few methods on it.
However, calling java MyMaintainanceClass will create
a new JVM wont it? Therefore it will not call the
singleton running in tomcat. What would be the best
way to approach this problem?
Thanks,
Joe
__________________________________________________
Do you Yahoo!?
Yahoo! Mail Plus - Powerful. Affordable. Sign up now.
http://mailplus.yahoo.com
---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-user-help@jakarta.apache.org