What are transaction isolation levels in EJB?1. Transaction_read_uncommitted
Explain the types of isolation levels that J2EE supports.Isolation Levels describes the degree to which the data being updated is visible to other transactions. There are 4 types of isolation levels supported by J2EE described as follows:
A static final variable / constant specifies the non-repeatable reads, dirty reads and phantom reads occurrences. This allows a specific row that is changed by one of the transactions to be read by another specific transaction well before the changes in that row have been committed. In case of any roll backs, an invalid row will be retrieved by the second transaction.
A static final variable / constant that specifies the prevention of the dirty reads, non-repeatable reads and phantom reads occurrences.
A static final variable / constant that specifies the prevention of dirty reads and non-repeatable reads and the occurrences of phantom reads.
The level indicates the prohibitions of reading a row with uncommitted changes in it, and also indicates the prohibition in specific situations where one transaction reads a row, a second transaction alters the row and the first transaction rereads the row.
A static final variable / constant that indicates the prevention of dirty reads, non-repeatable reads and phantom reads. This includes the prohibitions in TRANSACTION_REPEATABLE_READ.
It further prohibits the following situations:
- First transaction reads all rows that satisfy a WHERE condition
- A second transaction that inserts rows that satisfies the WHERE condition and
- First transaction rereads for the same condition, retrieving the additional phantom row in the second read.