At 08:04 16/05/2002 -0400, Larry Isaacs wrote:
I'm afraid Tomcat 3.3.x doesn't support the Resource element
that Tomcat 4.x does for setting up such resources.
oh bugger, that's what I feared. Looks like it's better/easier
for me to find a different hosting provider than rewrite a load
of code.
Thanks for the quick confirmation, Larry.
chas
-Original Message-
From: chas [mailto:[EMAIL PROTECTED]]
Sent: Thursday, May 16, 2002 11:18 AM
To: [EMAIL PROTECTED]
Subject: jndi under tomcat3.x ? (deploying a tomcat4.x webapp
on tomcat3.x server)
I've built my webapp using a JNDI datasource resource, running
on Tomcat4. I had no problem setting up the JNDI environment.
Now, I'm trying to run the webapp on a server which for one
reason or another, has Tomcat3.3. Am finding that the JNDI setup
is not working, even though I simply deployed a war file (so
web.xml should be correct) and copied over the server.xml config
from my development (Tomcat4) server.
Then I checked
http://jakarta.apache.org/tomcat/tomcat-3.3-doc/index.html
(yeah, perhaps I should have done that *before* trying to deploy g)
and don't see any JNDI reference. Did Tomcat 3.x have JNDI support ?
The error messages (below) suggest so :
% 2002-05-16 06:56:24 - Ctx( /myapp ): Exception in: R( /myapp +
/Lists/index.jsp + null) - javax.servlet.ServletException:
javax.naming.NoInitialContextException: Need to specify class name in
environment or system property, or as an applet parameter, or in an
application resource file: java.naming.factory.initial
at
org.apache.jasper.runtime.PageContextImpl.handlePageException(
PageContextImp
l.java:459)
Given that I'm unable to upgrade to Tomcat4 (since it's running on
a VPS - Virtual Private Server), will it be possible to run my
JNDI-dependent webapp on the Tomcat3 server ?
Steps taken so far :
1. Deployed the war file.
2. Added this to the server.xml :
Context path=/myapp docBase=myapp reloadable=true
Resource name=jdbc/mydb auth=Container
type=javax.sql.DataSource/
ResourceParams name=jdbc/mydb
parameter
nameuser/name
value/value
/parameter
parameter
namepassword/name
value/value
/parameter
parameter
namedriverClassName/name
valueorg.gjt.mm.mysql.Driver/value
/parameter
parameter
namedriverName/name
valuejdbc:mysql://localhost/mydb/value
/parameter
/ResourceParams
/Context
3. Copied the following files from tomcat4_home/common/lib
to tomcat3_home/lib (since Tomcat3 does not /common/lib)
- jdbc2_0-stdext.jar
- mm.mysql-2.0.13-bin.jar
However, I notice that tomcat3_home/lib does not have the
naming-common.jar and naming-resources.jar, so I have a sneaky
feeling that I'm barking up the wrong tree...
cheers,
chas
--
To unsubscribe, e-mail:
mailto:tomcat-user- [EMAIL PROTECTED]
For
additional commands,
e-mail: mailto:[EMAIL PROTECTED]
--
To unsubscribe, e-mail: mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]
--
To unsubscribe, e-mail: mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]