-
1. Re: transaction propagation and jdbc dao in ejb 2.1
wdfink Jul 11, 2014 5:51 AM (in response to born_free)Do you use the same connection pool? also it is possible that the pool did not return the same connection for different request in the same transaction.
It looks like a configuration issue, but you might share a bit more information if you need more help.
-
2. Re: transaction propagation and jdbc dao in ejb 2.1
born_free Jul 11, 2014 9:19 AM (in response to wdfink)Thanks Wolf-Dieter Fink for response.
You might be correct I do think that it is getting new connection when querying within transaction.
My jboscmp-jdbc.xml has following
<jbosscmp-jdbc>
<defaults>
<datasource>java:/OracleDS</datasource>
<datasource-mapping>Oracle9i</datasource-mapping>
<create-table>false</create-table>
<remove-table>false</remove-table>
</defaults>
...
My Oracle-ds.xml file has following
datasources>
<xa-datasource>
<jndi-name>OracleDS</jndi-name>
....
And the dao references OracleDS using JNDI. We are using jboss 4.2.2.
Thanks
-
3. Re: transaction propagation and jdbc dao in ejb 2.1
born_free Jul 14, 2014 9:28 AM (in response to born_free)Is there any test which I can do to find out if the connection object returned is different than what is used by session bean?
-
4. Re: transaction propagation and jdbc dao in ejb 2.1
wdfink Jul 14, 2014 3:19 PM (in response to born_free)Not sure whether this was possible in AS4.2.
Maybe you do a short test and set the root-logger to TRACE and see if you have details from the connection-pool
-
5. Re: transaction propagation and jdbc dao in ejb 2.1
born_free Jul 30, 2014 11:27 AM (in response to wdfink)I modified jbossjta-properties.xml and jboss-log4j configuration to enable jta logging and it dump too much logs. Application is taking long time to deploy and access is very slow. I review the logs to see if I can understand anything...is there any way we can check only see transaction related or connection pool related logs?