How do you intend to start Tomcat on the same JVM as your bootstrap application? Bypass ALL of tomcat facilities and scripts and take direct control, instantiating Tomcat classes by name from its libraries!! Embedded through API Interfaces! Wow! What is the advantage gained?
I would leave tomcat stricly alone, configure its server and web configuration files,; start, stop and control through Runtime commands from the bootstrap application. Communicate through sockets. On Wed, 2007-08-29 at 01:39 -0700, nlif wrote: > Hmm, I guess I did not explain myself very well... > > I have an application, that acts as bootstrap: it creates and initializes > various services, which provide a Java API to resources such as database, > file-system, and native libraries. In addition, I want that bootstrap > application to start an embedded tomcat, in which my web application will > run. Thus, *everything* is in the same process. The question was, how can I > pass Java references from the bootstrap application to the web-apps in side > the embedded Tomcat. > > I hope this makes it clear. > > I assume the Tomcat embedded APIs provide some way to pass a reference into > the web-app contexts that are deployed in that Tomcat. I've never worked > with Tomcat as embedded, and frankly, I can't seem to find documentation or > code-samples for it. If anyone can point me to anything, I'd appreciate it. > > Thanks again. > > > > > > OFFICIAL WEBSITE wrote: > > > > If I understand correctly, external applications were started on one JVM > > and the tomcat is on another JVM, started separately or by the external > > application itself. > > > > Two JVMS running on on machine have nothing in common other than system > > resources. Open a serversocket at a named port on the external > > application and let the tomcat applications from webapps connect to it > > and exchange sweet talk on a mutually agreed protocol. > > > > > > On Wed, 2007-08-29 at 00:05 -0700, nlif wrote: > >> Hi, > >> > >> If I run Tomcat as embedded, is it possible for the application that > >> contains Tomcat to interact with web-apps that run inside that Tomcat? > >> For > >> example, the external application, in addition to starting the embedded > >> Tomcat, also manages other services, and the web-apps that runs inside > >> the > >> embedded Tomcat need to use those services. How can this be done? > >> > >> Thanks in advance. > > > > > > --------------------------------------------------------------------- > > To start a new topic, e-mail: users@tomcat.apache.org > > To unsubscribe, e-mail: [EMAIL PROTECTED] > > For additional commands, e-mail: [EMAIL PROTECTED] > > > > > > > --------------------------------------------------------------------- To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]