Hi all,
I am working on a project which uses Java,Spring and Hibernate. I just came across a situaition like this.
bean 1 :
<bean id="cat" class="org.springframework.transaction.interceptor.TransactionProxyFactoryBean">
<property name="proxyInterfaces">
<list>
<value>cat</value>
</list>
</property>
<property name="transactionManager">
<ref bean="transactionManager"/>
</property>
<property name="transactionAttributeSource">
<ref bean="attributeSource"/>
</property>
</bean>
bean 2:
<bean id="dog" class="org.springframework.transaction.interceptor.TransactionProxyFactoryBean">
<property name="proxyInterfaces">
<list>
<value>dog</value>
</list>
</property>
<property name="transactionManager">
<ref bean="transactionManager"/>
</property>
<property name="transactionAttributeSource">
<ref bean="attributeSource"/>
</property>
</bean>
but while executing a getting the following exception
org.springframework.jdbc.support.SQLErrorCodesFactory] Error while extracting database product name - falling back to empty error codes
org.springframework.jdbc.support.MetaDataAccessException: Could not get Connection for extracting meta data;
nested exception is org.springframework.jdbc.CannotGetJdbcConnectionException: Could not get JDBC Connection;
nested exception is java.sql.SQLException: Connection has already been created in this tx context for pool Illegal attempt to create connection from another pool
Caused by:
at weblogic.jdbc.jts.Driver.getExistingConnection(Driver.java:613)
Assume cat and dog are two differnt interfaces
cant we have two transaction manager opened ??