tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Filip Hanik" <devli...@hanik.com>
Subject Re: Missing jdbc context
Date Mon, 27 Oct 2003 06:42:33 GMT
where did you put the postgres jar file?

Filip
----- Original Message -----
From: "Johann Uhrmann" <johann.uhrmann@xpecto.com>
To: "Tomcat Users List" <tomcat-user@jakarta.apache.org>
Sent: Wednesday, October 22, 2003 3:59 AM
Subject: Missing jdbc context


Hello,

I have some problems with Tomcat 4.1.27 and database connection pooling:

Apparently, the context java:comp/env/jdbc does not exist.

This is what I get from catalina.out:

Starting service Tomcat-Standalone
Apache Tomcat/4.1.27-LE-jdk14
GlobalResourcesLifecycleListener: Destroying MBeans for Global JNDI
Resources
Stopping service Tomcat-Standalone
GlobalResourcesLifecycleListener: Creating MBeans for Global JNDI Resources
in Context '' org.apache.naming.NamingContext@be16f5
GlobalResourcesLifecycleListener: Processing resource jdbc java.lang.String
GlobalResourcesLifecycleListener: Creating MBeans for Global JNDI Resources
in Context 'jdbc/' org.apache.naming.NamingContext@7cec96
GlobalResourcesLifecycleListener: Naming exception processing jdbc:
org.apache.naming.NamingContext:org.apache.naming.NamingContext@7cec96
javax.naming.NamingException: Cannot create resource instance


The configuration in server.xml is:

<?xml version='1.0' encoding='utf-8'?>
<Server className="org.apache.catalina.core.StandardServer" debug="0"
port="8006" shutdown="SHUTDOWN">
   <Listener className="org.apache.catalina.mbeans.ServerLifecycleListener"
debug="0" jsr77Names="false"/>
   <Listener
className="org.apache.catalina.mbeans.GlobalResourcesLifecycleListener"
debug="2"/>
   <GlobalNamingResources>
     <Resource name="jdbc/globaldb" scope="Shareable"
type="javax.sql.DataSource"/>
     <ResourceParams name="jdbc/globaldb">
       <parameter>
         <name>validationQuery</name>
         <value>select version()</value>
       </parameter>
       <parameter>
         <name>url</name>
         <value>jdbc:postgresql://dbserver:5432/mydb</value>
       </parameter>
       <parameter>
         <name>password</name>
         <value>myPwd</value>
       </parameter>
       <parameter>
         <name>maxActive</name>
         <value>10</value>
       </parameter>
       <parameter>
         <name>maxWait</name>
         <value>5000</value>
       </parameter>
       <parameter>
         <name>driverClassName</name>
         <value>org.postgresql.Driver</value>
       </parameter>
       <parameter>
         <name>username</name>
         <value>dbuser</value>
       </parameter>
       <parameter>
         <name>maxIdle</name>
         <value>2</value>
       </parameter>
     </ResourceParams>
...


Can someone give me a hint why that context is not available?

Thank You,

Johann Uhrmann

--
Johann Uhrmann
xpecto AG | Lindenstrasse 81 | D-84030 Ergolding
Telefon: 0700 xpecto 00 (0700 973286 00)
Telefax: 0700 xpecto 10 (0700 973286 10)
Internet: http://www.xpecto.com


---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-user-help@jakarta.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-user-help@jakarta.apache.org


Mime
View raw message