rpuch commented on code in PR #1331:
URL: https://github.com/apache/ignite-3/pull/1331#discussion_r1020292251
##########
modules/transactions/src/main/java/org/apache/ignite/internal/tx/storage/state/rocksdb/TxStateRocksDbStorage.java:
##########
@@ -115,11 +118,13 @@ public TxStateRocksDbStorage(
this.persistedTierReadOptions = persistedTierReadOptions;
this.partitionId = partitionId;
this.tableStorage = tableStorage;
- this.lastAppliedIndexKey =
ByteBuffer.allocate(Short.BYTES).order(ByteOrder.BIG_ENDIAN)
+ this.lastAppliedIndexAndTermKey =
ByteBuffer.allocate(Short.BYTES).order(ByteOrder.BIG_ENDIAN)
.putShort((short) partitionId)
.array();
- lastAppliedIndex = readLastAppliedIndex(readOptions);
+ byte[] indexAndTermBytes = readLastAppliedIndexAndTerm(readOptions);
Review Comment:
Also, for TX partition storage meta is simpler. We don't need to store
configuration there, which is A) many bytes, and B) it is updated independently
from index+term. So this 'squashing to same value' would not work well for MV
partition meta, but it does work for TX data partition meta.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]