3 Replies Latest reply on Feb 2, 2006 11:24 AM by Sz Fab

    changing datasource on runtime breaks hibernate session fact

    Sz Fab Newbie

      If I change my xxx-ds.xml on runtime, I cannot use hiberante. All the time, I receive:

      Caused by: javax.resource.ResourceException: You are trying to use a connection factory that has been shut down: ManagedConnectionFactory is null.
      at org.jboss.resource.connectionmanager.BaseConnectionManager2.allocateConnection(BaseConnectionManager2.java:439)
      at org.jboss.resource.connectionmanager.BaseConnectionManager2$ConnectionManagerProxy.allocateConnection(BaseConnectionManager2.java:874)
      at org.jboss.resource.adapter.jdbc.WrapperDataSource.getConnection(WrapperDataSource.java:103)
      ... 62 more

      I use har archive that has hibernate session factory defined properly to datasource JNDI name.