The Cursor Stability (CS) isolation level is the default isolation level and locks any row on which the cursor is positioned during a unit of workThis was really not what was intended since it locks rows with a shared lock. Other transactions can still access the table for selects but holding the locks places a heavy load on the db. In this case what was desired was to have a READ_UNCOMMITTED isolation level for those completely read-only operations.
There are usually two ways to solve the problem of custom tx levels with JTA.
- Define a datasource for each isolation level you intend to use in your application and then use IsolationLevelDataSourceRouter
- Use a vendor-specific extension that wraps the JNDI datasource