How to set the JDBC isolation level.

How to set the JDBC isolation level.

book

Article ID: KB0093063

calendar_today

Updated On:

Products Versions
TIBCO ActiveMatrix BusinessWorks -
Not Applicable -

Description

Resolution:

For the BW XA transaction group, you can set the transaction isolation level using BW property in tra. The transaction isolation level is set using the following BW property. For details, refer to BW documentation BW Administration ->Custom Engine Properties-> Available Custom Engine Properties


bw.plugin.transaction.xa.isolation 


By default in an XA transaction, the transaction isolation level is set to the default value for the JDBC driver you are using. If you wish to ensure a particular transaction isolation level, set the bw.plugin.transaction.xa.isolation custom engine property to one of the following values:



  value                                      transaction isolation level

    1                  java.sql.Connection.TRANSACTION_READ_UNCOMMITTED  

    2                  java.sql.Connection.TRANSACTION_READ_COMMITTED  

    3                  java.sql.Connection.TRANSACTION_REPEATABLE_READ  

    4                  java.sql.Connection.TRANSACTION_SERIALIZABLE  


For plain JDBC activity, you can set isolation level in several ways.


- If the driver you choose provides an isolation level property, you can add the connection property in the connection URL.

- For JDBC Select activity, you can use "select... from table with <isolation level>".

- You may use JDBC SQL Direct and run the "SET TRANSACTION ISOLATION LEVEL" statement.


Issue/Introduction

How to set the JDBC isolation level.