diff options
Diffstat (limited to 'src/main/java/com/amazon/carbonado/repo')
-rw-r--r-- | src/main/java/com/amazon/carbonado/repo/jdbc/JDBCRepository.java | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/main/java/com/amazon/carbonado/repo/jdbc/JDBCRepository.java b/src/main/java/com/amazon/carbonado/repo/jdbc/JDBCRepository.java index 6e53354..97be915 100644 --- a/src/main/java/com/amazon/carbonado/repo/jdbc/JDBCRepository.java +++ b/src/main/java/com/amazon/carbonado/repo/jdbc/JDBCRepository.java @@ -92,6 +92,9 @@ public class JDBCRepository return Connection.TRANSACTION_READ_COMMITTED;
case REPEATABLE_READ:
return Connection.TRANSACTION_REPEATABLE_READ;
+ case SNAPSHOT:
+ // TODO: not accurate for all databases.
+ return Connection.TRANSACTION_SERIALIZABLE;
case SERIALIZABLE:
return Connection.TRANSACTION_SERIALIZABLE;
}
@@ -117,6 +120,9 @@ public class JDBCRepository case REPEATABLE_READ:
desiredLevel = IsolationLevel.SERIALIZABLE;
break;
+ case SNAPSHOT:
+ desiredLevel = IsolationLevel.SERIALIZABLE;
+ break;
case SERIALIZABLE: default:
return null;
}
|