tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From dileep_sivaraman <dileep_sivara...@infosys.com>
Subject registering a DB2ConnectionPoolDataSource in tomcat 5.5
Date Fri, 27 Jul 2007 06:58:21 GMT

Hi ,

I am trying to register a com.ibm.db2.jcc.DB2ConnectionPoolDataSource
datasource in tomcat 5.5.4.

I am not getting any exception's while doing a context lookup and gives me
the datasource.
However the paramaeter's that are set with that Resource are always null.

Server.xml
<GlobalNamingResources>
<Resource name="jdbc/db2universal"
type="com.ibm.db2.jcc.DB2ConnectionPoolDataSource"
factory="com.ibm.db2.jcc.DB2DataSourceFactory"
serverName="PROD9S03.bankofamerica.com" username="abc" password="abc"/>

</GlobalNamingResources>

In my code  I get the datasource as :

connPoolDataSource=(DB2ConnectionPoolDataSource)
envContext.lookup("jdbc/db2universal");

However when I print out the serverName parameter that has been set in the
resource it prints null.

System.out.println("connPoolDataSource.getServerName()
:"+connPoolDataSource.getServerName());

OUTPUT:

connPoolDataSource.getServerName() :null


Can somebody tell me what I  am doing wrong?
-- 
View this message in context: http://www.nabble.com/registering-a-DB2ConnectionPoolDataSource-in-tomcat--5.5-tf4155802.html#a11823991
Sent from the Tomcat - User mailing list archive at Nabble.com.


---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Mime
View raw message