This week's book giveaway is in the OCPJP forum.
We're giving away four copies of OCA/OCP Java SE 7 Programmer I & II Study Guide and have Kathy Sierra & Bert Bates on-line!
See this thread for details.
The moose likes JBoss/WildFly and the fly likes Display datasource isolation level Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of OCA/OCP Java SE 7 Programmer I & II Study Guide this week in the OCPJP forum!
JavaRanch » Java Forums » Products » JBoss/WildFly
Bookmark "Display datasource isolation level" Watch "Display datasource isolation level" New topic
Author

Display datasource isolation level

Sugantha Jeevankumar
Ranch Hand

Joined: Jun 06, 2007
Posts: 93
Hi All.. I just want to know if there is a way to display the actual transaction isolation level used by my JBoss datasource. My datasource configuration looks like below,



I understand MySql uses TRANSACTION_REPEATABLE_READ by default and I am trying to override it with TRANSACTION_READ_COMMITTED for all transactions originating from my application. Is there anyway to check, if the datasource is indeed using TRANSACTION_READ_COMMITTED. JBoss' JMX console did not show much under "name=template/datasource,service=DataSourceBinding" node and server.log also did not reveal much. Any help is appreciated.


SCJP 5.0
Jaikiran Pai
Marshal

Joined: Jul 20, 2005
Posts: 10242
    
168

You'll have to check it on the Connection object returned by the DataSource. For example:



[My Blog] [JavaRanch Journal]
Sugantha Jeevankumar
Ranch Hand

Joined: Jun 06, 2007
Posts: 93
Thanks Jaikiran.. I was hoping there would be a non-intrusive way to do this, since I need to check the isolation level in use in a production machine. Any more suggestions are welcome.
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
 
subject: Display datasource isolation level