Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Name jdbc is not bound in this Context in Tomcat

Tags:

java

tomcat

jdbc

I'm having trouble with JDBC Connection Pooling, I've done all the same with explained here: JNDI Resources HOW-TO, and here is also question (the same configuration with mine) regarding this topic which has not been resolved, I think.
What else should I consider?

like image 611
user1143343 Avatar asked Jan 13 '12 10:01

user1143343


2 Answers

I hope you have done the ResourceLink configuration to your webapp, too.

<Context>
  ...
  <ResourceLink global="jdbc/MyDS" name="jdbc/MyDS" type="javax.sql.DataSource" />
  ...
</Context>
like image 168
adarshr Avatar answered Sep 28 '22 03:09

adarshr


I had this error when the JDBC driver was deleted from classpath. In my setup, Tomcat expected libraries in a special directory, which was filled by Maven executing a special target. Whenever I cleaned and forgot to execute the Maven's target prior to running Tomcat, I had precisely this error.

like image 24
MaDa Avatar answered Sep 28 '22 02:09

MaDa