I am new to Tomcat; I installed a web application consisting of
Servlets/JSPs. The Servlet accesses the database directly by loading a
database driver. Everything works fine in this architecture.
I then modified the Servlet so that it looked up the database through JNDI.
I understand that Server.xml and Web.xml needs to have appropriate entries
to enable the servlet to successfully get a connection. I used the admin
tool to configure the database; after configuration, I noticed that the
following changes were made to the server.xml.
<ResourceParams name="jdbc/Questions">
<parameter><name>validationQuery</name><value></value></parameter>
<parameter><name>user</name><value>sa</value></parameter>
<parameter><name>maxWait</name><value>5000</value></parameter>
<parameter><name>maxActive</name><value>4</value></parameter>
<parameter><name>password</name><value> </value></parameter>
<parameter><name>url</name><value>jdbc:weblogic:mssqlserver4:Questions@local
host</value>
</parameter>
<parameter><name>driverClassName</name><value>weblogic.jdbc.mssqlserver4.Dri
ver</value>
</parameter>
<parameter><name>maxIdle</name><value>2</value></parameter>
</ResourceParams>
I added the following additional entry to the web.xml:
<resource-ref>
<description>Questions Database</description>
<res-ref-name>jdbc/Questions</res-ref-name>
<res-ref-type>javax.sql.DataSource</res-ref-type>
<res-auth>Container</res-auth>
</resource-ref>
I am using ant build and ant install to install the application. Now if I
try to access the same resource, I get the following error:
Status report
message /AdminApp/jsp/menu.jsp
description The requested resource (/AdminApp/jsp/menu.jsp) is not available
Can somebody help me out?
--
To unsubscribe, e-mail: <mailto:tomcat-user-unsubscribe@;jakarta.apache.org>
For additional commands, e-mail: <mailto:tomcat-user-help@;jakarta.apache.org>