tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Robert Charbonneau <>
Subject Embedded Tomcat
Date Sat, 25 Oct 2003 21:16:08 GMT
I've successfully embedded Tomcat into my application and have talked to a few 
people about how to shared objects between the application and the JSPs from 
the contexts I've defined.  I've had a suggested to use JNDI but this seems a 
little more elaborate than I need, and someone else was talking about using 
ServletContext.setAttribute() and ServletContext.getAttribute()

Is there a code example both application side and web side somewhere that 
could show me how to do this?  I've been wrestling with this for a while and 
it's starting to irritate me.  :)

I've embedded Tomcat for the sole purpose of being able to create JSPs and 
Servlets that can examine the properties of the application and modify the 
properties as well.  For example, I need to be able to do the following in my 

MyApplication app = <someway of getting access to the instantiated object>;

Object obj = app.getSomeData();

If anyone can provide an example for this, I would very much appreciate it.


Robert Charbonneau

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message