[jboss-user] [Datasource Configuration] - You are trying to use a connection factory that has been shut down

Antoine Brun do-not-reply at jboss.com
Wed Jan 12 13:16:23 EST 2011


Antoine Brun [http://community.jboss.org/people/abr] created the discussion

"You are trying to use a connection factory that has been shut down"

To view the discussion, visit: http://community.jboss.org/message/580379#580379

--------------------------------------------------------------
Hi,

I have an application running on jboss5 and sometime we lose the database connection.
In the log I get this exception:

12/Jan/2011 14:58:59 ERROR [STDERR] Caused by: javax.resource.ResourceException: You are trying to use a connection factory that has been shut down: ManagedConnectionFactory is null.
12/Jan/2011 14:58:59 ERROR [STDERR]     at org.jboss.resource.connectionmanager.BaseConnectionManager2.allocateConnection(BaseConnectionManager2.java:487)
12/Jan/2011 14:58:59 ERROR [STDERR]     at org.jboss.resource.connectionmanager.BaseConnectionManager2$ConnectionManagerProxy.allocateConnection(BaseConnectionManager2.java:941)
12/Jan/2011 14:58:59 ERROR [STDERR]     at org.jboss.resource.adapter.jdbc.WrapperDataSource.getConnection(WrapperDataSource.java:89)

I trying to investigate on this, but I don't really know how to start.
If I restart jboss, the datasource are ok (my application works fine), but the administration console displays this datasource as *unavailable.*

The strange thing is that I have other datasources that are marked as available.

below the DS definition of the unavailable DS:
<datasources>
    <local-tx-datasource>
        <jndi-name>jdbc/customerDS</jndi-name>
        <connection-url>jdbc:oracle:thin:@127.0.0.1:1521:CUSTOMER</connection-url>
        <driver-class>oracle.jdbc.OracleDriver</driver-class>
        <user-name>ncgest</user-name>
        <password>Sec_52jlkhin_b4hdh</password>
        <track-statements>true</track-statements>
                <min-pool-size>20</min-pool-size>
                <max-pool-size>50</max-pool-size>
                <idle-timeout-minutes>1</idle-timeout-minutes>
                <transaction-isolation>TRANSACTION_READ_COMMITTED</transaction-isolation>
                <validate-on-match>false</validate-on-match>
                <allocation-retry-wait-millis>200</allocation-retry-wait-millis>
    </local-tx-datasource>
</datasources>

and the definition of the available one:
<datasources>
        <local-tx-datasource>
                <jndi-name>jdbc/reportTxDS</jndi-name>
                <connection-url>jdbc:oracle:thin:@127.0.0.1:1521:REPORT
                </connection-url>
                <driver-class>oracle.jdbc.OracleDriver</driver-class>
                <user-name>netreport</user-name>
                <password>netreport</password>
                <max-pool-size>5</max-pool-size>
                <query-timeout>0</query-timeout>
        </local-tx-datasource>
</datasources>

My question is:
Is there any way to know why the DS is marked as unavailable?
How can it be marked as unavailable and still the application can access the database through the DS?

Antoine
--------------------------------------------------------------

Reply to this message by going to Community
[http://community.jboss.org/message/580379#580379]

Start a new discussion in Datasource Configuration at Community
[http://community.jboss.org/choose-container!input.jspa?contentType=1&containerType=14&container=2077]

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/jboss-user/attachments/20110112/3f6e6ab3/attachment.html 


More information about the jboss-user mailing list