• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Connection pooling

 
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I had hosted an application in the mochahost . I am getting their the "javax.naming.NameNotFoundException: Name java: is not bound in this Context" error .
I am using Tomcat 5.5 , java 1.7 , mysql 5.5 .
In my local server pooing is working fine but in the server it gives the error .
I am posting the codes of web.xml , context.xml , connection class .

Context.xml

web.xml

DBConnect.java
 
Saloon Keeper
Posts: 27763
196
Android Eclipse IDE Tomcat Server Redhat Java Linux
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I can think of 2 possibilities:

1. The Context file isn't being seen by the Tomcat server. That would happen if the file wasn't located in one of Tomcat's designated locations for Context definitions, or if the OS userid that Tomcat is running under didn't have file access rights to read that file.

2. The database configuration information isn't working. The URL could be wrong, the userid/password could be invalid, or there could be a firewall blocking access to the database server. Plus there are other possibilities as well. If the connections cannot be created, chances are that the pool will not be constructed and thus not registered under JNDI.

Check Tomcat's logfiles and you'll probably find more information. The catalina.out file is the primary file, but also look in the localhost logfile.

Whatever your problem is, it's almost certainly Tomcat specific, so if you need help, check out the Tomcat forum.
 
Hemant Bagwan
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
The database configuration i had checked without jndi it is working fine .

I have Business Plan Shared JVM of mochahost . May be first possibility is correct . But how to resolve it ?
 
reply
    Bookmark Topic Watch Topic
  • New Topic