This is an automated email from the ASF dual-hosted git repository. irakov pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/ignite.git
The following commit(s) were added to refs/heads/master by this push: new 4a57f7d IGNITE-13271 Add new type of WAL records to track/debug atomic updates on backup nodes - Fixes #8060 4a57f7d is described below commit 4a57f7d5caef29a9ac84ecfee542439404339c7c Author: sk0x50 <slava.kopti...@gmail.com> AuthorDate: Wed Jul 22 20:53:37 2020 +0300 IGNITE-13271 Add new type of WAL records to track/debug atomic updates on backup nodes - Fixes #8060 Signed-off-by: Ivan Rakov <ivan.glu...@gmail.com> --- .../org/apache/ignite/internal/pagemem/wal/record/WALRecord.java | 5 ++++- .../internal/processors/cache/persistence/tree/io/PageIO.java | 3 +++ .../org/apache/ignite/testframework/wal/record/RecordUtils.java | 7 +++++++ 3 files changed, 14 insertions(+), 1 deletion(-) diff --git a/modules/core/src/main/java/org/apache/ignite/internal/pagemem/wal/record/WALRecord.java b/modules/core/src/main/java/org/apache/ignite/internal/pagemem/wal/record/WALRecord.java index 21388bc..da8e03e 100644 --- a/modules/core/src/main/java/org/apache/ignite/internal/pagemem/wal/record/WALRecord.java +++ b/modules/core/src/main/java/org/apache/ignite/internal/pagemem/wal/record/WALRecord.java @@ -230,7 +230,10 @@ public abstract class WALRecord { MASTER_KEY_CHANGE_RECORD(60, LOGICAL), /** Record that indicates that "corrupted" flag should be removed from tracking page. */ - TRACKING_PAGE_REPAIR_DELTA(61, PHYSICAL); + TRACKING_PAGE_REPAIR_DELTA(61, PHYSICAL), + + /** Atomic out-of-order update. */ + OUT_OF_ORDER_UPDATE(62, LOGICAL); /** Index for serialization. Should be consistent throughout all versions. */ private final int idx; diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/persistence/tree/io/PageIO.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/persistence/tree/io/PageIO.java index e9032ec..070d426 100644 --- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/persistence/tree/io/PageIO.java +++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/persistence/tree/io/PageIO.java @@ -255,6 +255,9 @@ public abstract class PageIO { /** */ public static final short T_DATA_PART = 32; + /** */ + public static final short T_MARKER_PAGE = 33; + /** Index for payload == 1. */ public static final short T_H2_EX_REF_LEAF_START = 10_000; diff --git a/modules/core/src/test/java/org/apache/ignite/testframework/wal/record/RecordUtils.java b/modules/core/src/test/java/org/apache/ignite/testframework/wal/record/RecordUtils.java index 793825e..4892cf4 100644 --- a/modules/core/src/test/java/org/apache/ignite/testframework/wal/record/RecordUtils.java +++ b/modules/core/src/test/java/org/apache/ignite/testframework/wal/record/RecordUtils.java @@ -127,6 +127,7 @@ import static org.apache.ignite.internal.pagemem.wal.record.WALRecord.RecordType import static org.apache.ignite.internal.pagemem.wal.record.WALRecord.RecordType.MVCC_DATA_PAGE_TX_STATE_HINT_UPDATED_RECORD; import static org.apache.ignite.internal.pagemem.wal.record.WALRecord.RecordType.MVCC_DATA_RECORD; import static org.apache.ignite.internal.pagemem.wal.record.WALRecord.RecordType.MVCC_TX_RECORD; +import static org.apache.ignite.internal.pagemem.wal.record.WALRecord.RecordType.OUT_OF_ORDER_UPDATE; import static org.apache.ignite.internal.pagemem.wal.record.WALRecord.RecordType.PAGES_LIST_ADD_PAGE; import static org.apache.ignite.internal.pagemem.wal.record.WALRecord.RecordType.PAGES_LIST_INIT_NEW_PAGE; import static org.apache.ignite.internal.pagemem.wal.record.WALRecord.RecordType.PAGES_LIST_REMOVE_PAGE; @@ -219,6 +220,7 @@ public class RecordUtils { put(MVCC_TX_RECORD, RecordUtils::buildMvccTxRecord); put(CONSISTENT_CUT, RecordUtils::buildConsistentCutRecord); put(BTREE_META_PAGE_INIT_ROOT_V3, RecordUtils::buildBtreeMetaPageInitRootV3); + put(OUT_OF_ORDER_UPDATE, RecordUtils::buildOutOfOrderRecord); }}; /** **/ @@ -572,6 +574,11 @@ public class RecordUtils { return new UnsupportedWalRecord(BTREE_META_PAGE_INIT_ROOT_V3); } + /** **/ + public static UnsupportedWalRecord buildOutOfOrderRecord() { + return new UnsupportedWalRecord(OUT_OF_ORDER_UPDATE); + } + /** * Return {@code true} if include to write-ahead log. *