From 8e264f4ea1e60b2cdc2c04f940767ca6e4d1eca2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=D0=9D=D0=B8=D0=BA=D0=BE=D0=BB=D0=B0=D0=B9=20=D0=91=D0=B5?= =?UTF-8?q?=D0=BB=D0=BE=D0=BD=D0=BE=D0=B3=D0=BE=D0=B2?= Date: Tue, 10 Nov 2026 22:16:27 +0300 Subject: [PATCH] feat(core): add LINEARIZABLE level of isolation --- CHANGELOG.md | 6 ++++++ .../core/protocol/TransactionIsolationLevel.java | 12 +++++++++++- 2 files changed, 17 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 716d7705..640af90d 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,12 @@ ## [Unreleased] +### Core + +- Added + [LINEARIZABLE](https://github.com/tarantool/tarantool/blob/e643f88a5e0c6d9ef2789b2033088fd04e7d39ae/src/box/txn.h#L228) + isolation level. + ### Testcontainers - `CartridgeClusterContainer`: a failed `cartridge replicasets setup` from a YAML topology file diff --git a/tarantool-core/src/main/java/io/tarantool/core/protocol/TransactionIsolationLevel.java b/tarantool-core/src/main/java/io/tarantool/core/protocol/TransactionIsolationLevel.java index b6aecfc3..a04d6673 100644 --- a/tarantool-core/src/main/java/io/tarantool/core/protocol/TransactionIsolationLevel.java +++ b/tarantool-core/src/main/java/io/tarantool/core/protocol/TransactionIsolationLevel.java @@ -6,8 +6,18 @@ package io.tarantool.core.protocol; public enum TransactionIsolationLevel { + /** Take isolation level from global default_isolation_level. */ DEFAULT, + + /** Allow to read committed, but not confirmed changes. */ READ_COMMITTED, + + /** Allow to read only confirmed changes. */ READ_CONFIRMED, - BEST_EFFORT; + + /** Determine isolation level automatically. */ + BEST_EFFORT, + + /** Allow to read only the changes confirmed on any cluster node. */ + LINEARIZABLE; }