Organizational Research By

Surprising Reserch Topic

Experts Most Trusted Topic


failed to obtain create connection from connection pool


failed to obtain create connection from connection pool  using -'java,oracle,jdbc,glassfish,connection-pooling'

I am running on glassfish 3 with primefaces 3.1

Any idea why I am getting this exception? When I first create datasource and run it is running fine but after sometime this error starts appearing.

WARNING: RAR5117 : Failed to obtain/create connection from connection pool [ Oracle_TSH1_Pool ]. Reason : com.sun.appserv.connectors.internal.api.PoolingException
WARNING: RAR5114 : Error allocating connection : [Error in allocating a connection. Cause: null]
SEVERE: java.sql.SQLException: Error in allocating a connection. Cause: null
    at com.sun.gjc.spi.base.DataSource.getConnection(DataSource.java:120)
    at MYDataSource.getConnection(DatabaseConnection.java:65)
    at ScheduleDAO.loadSchedules(ScheduleDAO.java:48)
    at SchedulesBean.getSchedules(SchedulesBean.java:42)
    at SchedulesBean.<init>(SchedulesBean.java:28)
    at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
    at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:57)
    at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
    at java.lang.reflect.Constructor.newInstance(Constructor.java:525)
    at java.lang.Class.newInstance0(Class.java:372)
    at java.lang.Class.newInstance(Class.java:325)
    at com.sun.faces.mgbean.BeanBuilder.newBeanInstance(BeanBuilder.java:188)
    at com.sun.faces.mgbean.BeanBuilder.build(BeanBuilder.java:102)
    at com.sun.faces.mgbean.BeanManager.createAndPush(BeanManager.java:409)
    at com.sun.faces.mgbean.BeanManager.create(BeanManager.java:269)
    at com.sun.faces.el.ManagedBeanELResolver.resolveBean(ManagedBeanELResolver.java:244)
    at com.sun.faces.el.ManagedBeanELResolver.getValue(ManagedBeanELResolver.java:116)
    at com.sun.faces.el.DemuxCompositeELResolver._getValue(DemuxCompositeELResolver.java:176)
    at com.sun.faces.el.DemuxCompositeELResolver.getValue(DemuxCompositeELResolver.java:203)
    at com.sun.el.parser.AstIdentifier.getValue(AstIdentifier.java:99)
    at com.sun.el.parser.AstValue.getTarget(AstValue.java:127)
    at com.sun.el.parser.AstValue.getType(AstValue.java:76)
    at com.sun.el.ValueExpressionImpl.getType(ValueExpressionImpl.java:195)
    at com.sun.faces.facelets.el.TagValueExpression.getType(TagValueExpression.java:98)
    at org.primefaces.component.datatable.DataTable.isLazy(DataTable.java:922)
    at org.primefaces.component.datatable.DataTableRenderer.encodeMarkup(DataTableRenderer.java:177)
    at org.primefaces.component.datatable.DataTableRenderer.encodeEnd(DataTableRenderer.java:103)
    at javax.faces.component.UIComponentBase.encodeEnd(UIComponentBase.java:875)
    at javax.faces.component.UIComponent.encodeAll(UIComponent.java:1763)
    at javax.faces.render.Renderer.encodeChildren(Renderer.java:168)
    at javax.faces.component.UIComponentBase.encodeChildren(UIComponentBase.java:845)
    at javax.faces.component.UIComponent.encodeAll(UIComponent.java:1756)
    at javax.faces.component.UIComponent.encodeAll(UIComponent.java:1759)
    at javax.faces.component.UIComponent.encodeAll(UIComponent.java:1759)
    at com.sun.faces.application.view.FaceletViewHandlingStrategy.renderView(FaceletViewHandlingStrategy.java:401)
    at com.sun.faces.application.view.MultiViewHandler.renderView(MultiViewHandler.java:131)


My glassfish-resource.xml

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE resources PUBLIC "-//Sun Microsystems, Inc.//DTD Application Server 9.0 Resource Definitions //EN" "http://www.sun.com/software/appserver/dtds/sun-resources_1_3.dtd">
<resources>
    <jdbc-resource enabled="true" jndi-name="jdbc/myDS"
        object-type="user" pool-name="Oracle_Pool" />

    <jdbc-connection-pool allow-non-component-callers="false"
        associate-with-thread="false" connection-creation-retry-attempts="0"
        connection-creation-retry-interval-in-seconds="10"
        connection-leak-reclaim="false" connection-leak-timeout-in-seconds="0"
        connection-validation-method="auto-commit" datasource-classname="oracle.jdbc.pool.OracleDataSource"
        fail-all-connections="false" idle-timeout-in-seconds="300"
        is-connection-validation-required="false"
        is-isolation-level-guaranteed="true" lazy-connection-association="false"
        lazy-connection-enlistment="false" match-connections="false"
        max-connection-usage-count="0" max-pool-size="32"
        max-wait-time-in-millis="60000" name="Oracle_Pool"
        non-transactional-connections="false" pool-resize-quantity="2"
        res-type="javax.sql.DataSource" statement-timeout-in-seconds="-1"
        steady-pool-size="8" validate-atmost-once-period-in-seconds="0"
        wrap-jdbc-objects="false">

        <property name="serverName" value="server" />

        <property name="PortNumber" value="1521" />

        <property name="DatabaseName" value="mydb" />

        <property name="User" value="user" />


        <property name="URL" value="jdbc:oracle:thin:@server:1521:mydb" />

        <property name="driverClass" value="oracle.jdbc.OracleDriver" />

    </jdbc-connection-pool>
</resources>

    

asked Oct 19, 2015 by santosh soni
0 votes
39 views



Related Hot Questions



Government Jobs Opening


...