diff --git a/contrib/client-c b/contrib/client-c index 099157bf7d9..260359f7c58 160000 --- a/contrib/client-c +++ b/contrib/client-c @@ -1 +1 @@ -Subproject commit 099157bf7d9e20eac73a38c5490467b80427761f +Subproject commit 260359f7c587e0acc10e6205021feff8e84b1465 diff --git a/contrib/kvproto b/contrib/kvproto index ecf635d1a67..118a4cab53e 160000 --- a/contrib/kvproto +++ b/contrib/kvproto @@ -1 +1 @@ -Subproject commit ecf635d1a67b57ace980deca2d9fa838d05e63d8 +Subproject commit 118a4cab53e4352a99cc31f8912629601b2ea0a3 diff --git a/contrib/tiflash-proxy b/contrib/tiflash-proxy index b8c00d3953f..87b66828617 160000 --- a/contrib/tiflash-proxy +++ b/contrib/tiflash-proxy @@ -1 +1 @@ -Subproject commit b8c00d3953fc847a4958cec69b69ad5aa45c8a6d +Subproject commit 87b668286174b152df0f7ef4b738a5f46857eeff diff --git a/dbms/src/Storages/KVStore/TiKVHelpers/DecodedLockCFValue.cpp b/dbms/src/Storages/KVStore/TiKVHelpers/DecodedLockCFValue.cpp index 1b429b32a6f..f90fdf61299 100644 --- a/dbms/src/Storages/KVStore/TiKVHelpers/DecodedLockCFValue.cpp +++ b/dbms/src/Storages/KVStore/TiKVHelpers/DecodedLockCFValue.cpp @@ -81,6 +81,13 @@ inline void decodeLockCfValue(DecodedLockCFValue & res) res.txn_size = readUInt64(data, len); break; } +#if SERVERLESS_PROXY != 0 + case IS_TXN_FILE_PREFIX: + { + res.is_txn_file = true; + break; + } +#endif case ASYNC_COMMIT_PREFIX: { res.use_async_commit = true; @@ -159,6 +166,7 @@ void DecodedLockCFValue::intoLockInfo(kvrpcpb::LockInfo & res) const res.set_txn_size(txn_size); res.set_use_async_commit(use_async_commit); res.set_key(decodeTiKVKey(*key)); + res.set_is_txn_file(is_txn_file); if (use_async_commit) { @@ -185,4 +193,4 @@ bool DecodedLockCFValue::isLargeTxn() const } } // namespace RecordKVFormat -} // namespace DB \ No newline at end of file +} // namespace DB diff --git a/dbms/src/Storages/KVStore/TiKVHelpers/DecodedLockCFValue.h b/dbms/src/Storages/KVStore/TiKVHelpers/DecodedLockCFValue.h index 5e1febf819a..56538e1854d 100644 --- a/dbms/src/Storages/KVStore/TiKVHelpers/DecodedLockCFValue.h +++ b/dbms/src/Storages/KVStore/TiKVHelpers/DecodedLockCFValue.h @@ -39,8 +39,9 @@ struct DecodedLockCFValue : boost::noncopyable UInt64 min_commit_ts{0}; std::string_view secondaries; std::string_view primary_lock; + bool is_txn_file{0}; // For large txn, generation is not zero. UInt64 generation{0}; }; -} // namespace DB::RecordKVFormat \ No newline at end of file +} // namespace DB::RecordKVFormat diff --git a/dbms/src/Storages/KVStore/TiKVHelpers/TiKVRecordFormat.h b/dbms/src/Storages/KVStore/TiKVHelpers/TiKVRecordFormat.h index 4923eda2602..99d605338ad 100644 --- a/dbms/src/Storages/KVStore/TiKVHelpers/TiKVRecordFormat.h +++ b/dbms/src/Storages/KVStore/TiKVHelpers/TiKVRecordFormat.h @@ -61,6 +61,7 @@ static const char SHORT_VALUE_PREFIX = 'v'; static const char MIN_COMMIT_TS_PREFIX = 'c'; static const char FOR_UPDATE_TS_PREFIX = 'f'; static const char TXN_SIZE_PREFIX = 't'; +static const char IS_TXN_FILE_PREFIX = 'T'; static const char ASYNC_COMMIT_PREFIX = 'a'; static const char ROLLBACK_TS_PREFIX = 'r'; static const char FLAG_OVERLAPPED_ROLLBACK = 'R';