tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "BURCHER, Edward, GFM" <>
Subject how do you pass parameters to the internal JVM ? or to the servle t instance ?
Date Wed, 29 Mar 2000 16:03:39 GMT
Hi all,

I've got one, possibly two, problems here. Basically, I'm trying to run my
servlet on tomcat. The servlet connects to a back-end CORBA object. This all
works fine under servletrunner as run by JBuilder. When run by tomcat, I am
getting a CORBA NO_IMPLEMENT exception because the servlet cannot find my
corba server. This is almost certainly because the ORBagentAddr and
ORBagentPort properties (we use Visi for Java) are not set within the
servlet's java.lang.System property list. So far I have tried the following

1. Setting OSAGENT_ADDR and OSAGENT_PORT in the unix shell environment prior
to running tomcat.
2. Setting ORBagentAddr and ORBagentPort properties directly within the
servlet init() method using System.setProperty()
3. Editing the <mycontext>/WEB-INF/web.xml file for my context and adding
the parameter specification. 

All of these have failed. I suspect the latter is the correct way to do
things, and I also suspect I am doing things wrong here, because I cannot
refer to my servlet by it's alias as defined in this file. 

In other words, my servlet has class EdServlet and occupies package a.b.c. I
want to just be able to reference it as EdServlet from a URL (e.g.
http://myhost/mycontext/servlet/EdServlet), so I create the following entry
in the web.xml file:-


However, the aliasing doesn't work, so I am addressing my servlet as follows
http://myhost/mycontext/servlet/a.b.c.EdServlet. i.e. with the full package
path of the class. However, this seems to mean that I bypass my parameter
list as specified above and so the servlet uses the default ORB port and
address which is no use to me at all.

Does anyone know how to solve these problems?


Ed B.

View raw message