You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by Pa...@linedata.com on 2001/05/31 16:15:20 UTC

Get a JDBC DataSource via JNDI ( using Poolman ) - NEED HELP

We are trying to get a DataSource with a JNDI lookup.

We want to use PoolMan for this and JNP (as JNDI server)

Our questions
--------------
1. How to setup the JNP server or another JNDI server with Tomcat ?
2. How to install Poolman, we have copied the poolman.jar, install the
poolman.xml file and nothing sounds happening ?
3. We have a servlet that start at the starting of Tomcat, this one already
use
to DataSource.

What's happening currently
---------------------------
We have copy the poolman.jar and set the classpath
We have copy the jndi.jar and set the classpath
We have copy the jnp.jar and set the classpath
We have copy the jndi.properties in the TOMCAT/conf folder
We have copy the jnp.properties in the TOMCAT/conf folder
We have copy the poolman.xml in the TOMCAT/conf folder and the TOMCAT/ (We
do not know where to put this file !)

We have the servlet that do :

     InitialContext tContext = new InitialContext();
     DataSource tDataSource = (DataSource) tContext.lookup(
tDataSourceJNDIName );

We have a crash during the lookup, we have this message :

javax.naming.ServiceUnavailableException: Connection refused: no further
information.  Root exception is java.net.ConnectException: Connection
refused: no further information
     java.lang.Throwable(java.lang.String)
     java.lang.Exception(java.lang.String)
     java.io.IOException(java.lang.String)
     java.net.SocketException(java.lang.String)
     java.net.ConnectException(java.lang.String)
     void java.net.PlainSocketImpl.socketConnect(java.net.InetAddress, int)
     void java.net.PlainSocketImpl.doConnect(java.net.InetAddress, int)
     void java.net.PlainSocketImpl.connectToAddress(java.net.InetAddress,
int)
     void java.net.PlainSocketImpl.connect(java.net.InetAddress, int)
     java.net.Socket(java.net.InetAddress, int, java.net.InetAddress, int,
boolean)
     java.net.Socket(java.lang.String, int)
     void org.jnp.interfaces.NamingContext.checkRef(java.util.Hashtable)
     java.lang.Object
org.jnp.interfaces.NamingContext.lookup(javax.naming.Name)
     java.lang.Object
org.jnp.interfaces.NamingContext.lookup(java.lang.String)
     java.lang.Object javax.naming.InitialContext.lookup(java.lang.String)


Can someone help us, we have try a lot, read the documentation and the FAQ,
but
without success, please HELP US !!!!


Thanks a lot for all your help

Patrick Pierra