MVCC was added with expectation is that it would not affect existing KV transactional code, neither SQL on non-TRANSACTIONAL_SNAPSHOT caches.
However, this turned not to be the case: if you open an OPTIMISIC SERIALIZABLE transaction and do SQL query to fetch data from table, exception will be thrown with Only pessimistic repeatable read transactions are supported at the moment
Exception in thread "main" javax.cache.CacheException: Only pessimistic repeatable read transactions are supported at the moment. at org.apache.ignite.internal.processors.cache.IgniteCacheProxyImpl.query(IgniteCacheProxyImpl.java:697) at org.apache.ignite.internal.processors.cache.IgniteCacheProxyImpl.query(IgniteCacheProxyImpl.java:636) at org.apache.ignite.internal.processors.cache.GatewayProtectedCacheProxy.query(GatewayProtectedCacheProxy.java:388) at IgniteTransactionTester.testTransactionException(IgniteTransactionTester.java:53) at IgniteTransactionTester.main(IgniteTransactionTester.java:38) Caused by: class org.apache.ignite.internal.processors.query.IgniteSQLException: Only pessimistic repeatable read transactions are supported at the moment. at org.apache.ignite.internal.processors.cache.mvcc.MvccUtils.tx(MvccUtils.java:690) at org.apache.ignite.internal.processors.cache.mvcc.MvccUtils.tx(MvccUtils.java:671) at org.apache.ignite.internal.processors.query.h2.IgniteH2Indexing.runQueryTwoStep(IgniteH2Indexing.java:1793) at org.apache.ignite.internal.processors.query.h2.IgniteH2Indexing.doRunDistributedQuery(IgniteH2Indexing.java:2610) at org.apache.ignite.internal.processors.query.h2.IgniteH2Indexing.doRunPrepared(IgniteH2Indexing.java:2315) at org.apache.ignite.internal.processors.query.h2.IgniteH2Indexing.querySqlFields(IgniteH2Indexing.java:2209) at org.apache.ignite.internal.processors.query.GridQueryProcessor$4.applyx(GridQueryProcessor.java:2135) at org.apache.ignite.internal.processors.query.GridQueryProcessor$4.applyx(GridQueryProcessor.java:2130) at org.apache.ignite.internal.util.lang.IgniteOutClosureX.apply(IgniteOutClosureX.java:36) at org.apache.ignite.internal.processors.query.GridQueryProcessor.executeQuery(GridQueryProcessor.java:2707) at org.apache.ignite.internal.processors.query.GridQueryProcessor.querySqlFields(GridQueryProcessor.java:2144) at org.apache.ignite.internal.processors.cache.IgniteCacheProxyImpl.query(IgniteCacheProxyImpl.java:685) ... 4 more
This is a major regression towards 2.6. Please see linked reproducer (IgniteTransactionTester class).
- is related to
-
IGNITE-10520 MVCC: Next to mvcc-tx non-mvcc-Tx failed with unexpected exception.
-
- Resolved
-
- relates to
-
IGNITE-10895 MVCC: Document several modes of pessimistic transactions are allowed for MVCC caches.
-
- Open
-
- links to
(2 links to)