File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes Other JSE/JEE APIs and the fly likes Pool Exception Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Other JSE/JEE APIs
Bookmark "Pool Exception" Watch "Pool Exception" New topic

Pool Exception

Graham Thorpe
Ranch Hand

Joined: Mar 25, 2002
Posts: 265
When i run this program

import javax.servlet.*;
import javax.servlet.http.*;
import java.sql.*;
import javax.naming.*;
import javax.sql.*;
public class DD11 extends HttpServlet
public void service(HttpServletRequest req,HttpServletResponse res)throws ServletException,IOException{
Connection con=null;
Statement st=null;
ResultSet rs=null;
res.setContentType("text/html"); out = res.getWriter();
String tcnt=null;
try {

Context cx = new InitialContext();
DataSource ds = (DataSource)cx.lookup("oradsn");
out.println("the DataSource is :"+ds);
out.println("ORADSN Connection created"+con);
}catch(Exception e) {

i got this excecption ...................

java.sql.SQLException: weblogic.common.ResourceException: No available connections in pool oradsn at weblogic.jdbc.common.internal.RmiDataSource.getPoolConnection( at weblogic.jdbc.common.internal.RmiDataSource.getConnection( at DD11.service( at javax.servlet.http.HttpServlet.service( at weblogic.servlet.internal.ServletStubImpl$ at weblogic.servlet.internal.ServletStubImpl.invokeServlet( at weblogic.servlet.internal.ServletStubImpl.invokeServlet( at weblogic.servlet.internal.WebAppServletContext$ at at weblogic.servlet.internal.WebAppServletContext.invokeServlet( at weblogic.servlet.internal.ServletRequestImpl.execute( at weblogic.kernel.ExecuteThread.execute( at
Ranch Hand

Joined: Nov 22, 2008
Posts: 18944
There can be two errors, first the connections in the application server are not configured correctly or second the jndi name of your datasources is wrong. I don't know it exactly, but must it not something like "jdbc/dbname" ?
I agree. Here's the link:
subject: Pool Exception
It's not a secret anymore!