aspose file tools*
The moose likes BEA/Weblogic and the fly likes No longer able to connect to JNDI Datasource Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Products » BEA/Weblogic
Bookmark "No longer able to connect to JNDI Datasource" Watch "No longer able to connect to JNDI Datasource" New topic
Author

No longer able to connect to JNDI Datasource

George Impagliazo
Ranch Hand

Joined: Sep 25, 2010
Posts: 41
Hi;

I have WebLogic 9.2 set up on my computer as a development tool. Yesterday I was able to connect to the test database on our test server with the JNDI/Database resource "abc" just fine.

For some reason, it simply stopped working this morning.

I got this error message when trying to connect with the webapp I use:

<Jul 28, 2011 4:48:14 PM EDT> <Notice> <Stdout> <000000> <Exception in getPersonIdByEmail(String emailAddress) - statementDB14>
java.sql.SQLException: Cannot obtain connection: driverURL = jdbc:weblogic:pool:nsd, props = {EmulateTwoPhaseCommit=false, connectionPoolID=abc, jdbcTxDataSourcourceName=abc}.
Nested Exception: java.lang.RuntimeException: Failed to Generate Wrapper Class
at weblogic.utils.wrapper.WrapperFactory.createWrapper(WrapperFactory.java:213)
at weblogic.jdbc.wrapper.JDBCWrapperFactory.getWrapper(JDBCWrapperFactory.java:173)
at weblogic.jdbc.pool.Driver.allocateConnection(Driver.java:247)
at weblogic.jdbc.pool.Driver.connect(Driver.java:164)
at weblogic.jdbc.jts.Driver.getNonTxConnection(Driver.java:647)
at weblogic.jdbc.jts.Driver.connect(Driver.java:137)


I got this error message when using a Test JSP I have for doing a simple database connection using that Database Resource ( "abc")

<Jul 28, 2011 4:52:06 PM EDT> <Error> <HTTP> <BEA-101020> <[weblogic.servlet.internal.WebAppServletContext@507c6d - appName: 'mainWebApp', name: 'mainWebApp', context-path: ''] Servlet failed with Exception
java.lang.NullPointerException
at jsp_servlet._test.__testjndiweblogic._jspService(__testjndiweblogic.java:145)
at weblogic.servlet.jsp.JspBase.service(JspBase.java:34)
at weblogic.servlet.internal.StubSecurityHelper$ServletServiceAction.run(StubSecurityHelper.java:227)
at weblogic.servlet.internal.StubSecurityHelper.invokeServlet(StubSecurityHelper.java:125)
at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:283)
Truncated. see log file for complete stacktrace


WebLogic, the webapp, the datasource have been working fine for weeks. I haven't changed anything recently. This just started happening today. The database is fine.


Any ideas on how I can fix whatever is wrong?

Thanks in advance
George Impagliazo
Ranch Hand

Joined: Sep 25, 2010
Posts: 41
I remembered that a few days ago I copied my Oracle JDBC drivers from my main java installation on my system to the installation directories for JRocket and Std Java within the BEA installation. I restored those jre/lib/ext directories to how they were and the problem cleared up.
 
Consider Paul's rocket mass heater.
 
subject: No longer able to connect to JNDI Datasource