我有一个在WebLogic中正常运行的Spring应用程序。Spring IntTest从Atomikos获得“无法增长连接池”
我有一套使用Atomikos“Transaction Essentials”框架提供独立事务管理器的集成测试。我有这个工作,但我现在看到一个新问题,但我不知道我可能会做出什么改变,会导致这种情况发生。
我看到一个堆栈跟踪开头是这样的:
org.springframework.jdbc.CannotGetJdbcConnectionException:无法获取JDBC连接;嵌套的例外是com.atomikos.jdbc.AtomikosSQLException:无法在org.springframework.jdbc.datasource.DataSourceUtils.getConnection增长连接池 (DataSourceUtils.java:80)
下面是相关的bean定义:
<bean id="atomikosTransactionManager" class="com.atomikos.icatch.jta.UserTransactionManager"
init-method="init" destroy-method="close">
<!-- when close is called, should we force transactions to terminate or not? -->
<property name="forceShutdown">
<value>true</value>
</property>
</bean>
<!-- Also use Atomikos UserTransactionImp, needed to configure Spring -->
<bean id="atomikosUserTransaction" class="com.atomikos.icatch.jta.UserTransactionImp">
<property name="transactionTimeout">
<value>300</value>
</property>
</bean>
<!-- Configure the Spring framework to use JTA transactions from Atomikos -->
<bean id="catalogTransactionManager" class="org.springframework.transaction.jta.JtaTransactionManager">
<property name="transactionManager">
<ref bean="atomikosTransactionManager" />
</property>
<property name="userTransaction">
<ref bean="atomikosUserTransaction" />
</property>
</bean>
我也有好几个这样的:
<bean id="appConfigDataSource"
class="com.atomikos.jdbc.AtomikosDataSourceBean"
p:uniqueResourceName="appConfigDataSource"
p:xaDataSourceClassName="oracle.jdbc.xa.client.OracleXADataSource"
p:poolSize="5">
<property name="xaProperties">
<props>
<prop key="user">${ds.appconfig.userName}</prop>
<prop key="password">${ds.appconfig.password}</prop>
<prop key="URL">${ds.appconfig.url}</prop>
</props>
</property>
</bean>
我试图改变 “5” 到 “50”。这使得它运行时间更长,但它仍然会因相同的错误而失败。没有办法,甚至需要5个甚至50个连接。我有一种强烈的感觉,如果我将它改为更大的数字,它会运行更长的时间,并且仍会以相同的错误失败。
我可能会丢失什么?