Win a copy of Design for the Mind this week in the Design forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Datasource JNDI

 
Pearlo Muthukumaran
Ranch Hand
Posts: 79
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

My web application has the following flow from the servlet layer:

Servlet <--> Controller Beans <--> Application Beans <--> JDBC layer <--> DB

I am bundling all components in jar file and deploying it as single web
application. Currently, I am not using any EJB for any of the above components implementation.

Now I have a clarification. In above flow, can the Datasource JNDI configured in Apache Tomcat Server be used by JDBC Layer ? Will this approach work?

Or will I have to acquire Connection object from Datasource at Servlet Layer and pass it all the way down to JDBC Layer through controller beans and application beans?

Regards
Muthu
 
It is sorta covered in the JavaRanch Style Guide.
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic