ibessonov commented on code in PR #6307: URL: https://github.com/apache/ignite-3/pull/6307#discussion_r2236351842
########## modules/table/src/main/java/org/apache/ignite/internal/table/distributed/replicator/PartitionReplicaListener.java: ########## @@ -1940,20 +1941,29 @@ private CompletableFuture<List<BinaryRow>> processReadOnlyDirectMultiEntryAction ReadOnlyDirectMultiRowReplicaRequest request, HybridTimestamp opStartTimestamp) { List<BinaryTuple> primaryKeys = resolvePks(request.primaryKeys()); - HybridTimestamp readTimestamp = opStartTimestamp; - if (request.requestType() != RO_GET_ALL) { - throw new IgniteInternalException(Replicator.REPLICA_COMMON_ERR, - format("Unknown single request [actionType={}]", request.requestType())); - } + assert request.requestType() == RO_GET_ALL; CompletableFuture<BinaryRow>[] resolutionFuts = new CompletableFuture[primaryKeys.size()]; for (int i = 0; i < primaryKeys.size(); i++) { - resolutionFuts[i] = resolveRowByPkForReadOnly(primaryKeys.get(i), readTimestamp); + resolutionFuts[i] = resolveRowByPkForReadOnly(primaryKeys.get(i), opStartTimestamp); } - return allOfToList(resolutionFuts); + return allOfToList(resolutionFuts).thenApply(rows -> { + // Validate read correctness. + HybridTimestamp lwm = lowWatermark.getLowWatermark(); + + if (lwm != null && opStartTimestamp.compareTo(lwm) < 0) { Review Comment: We should check that storage engines support such a concurrent read. `aipersist` may fail if GC removes this entry concurrently, it may result in node failure, potentially. I realize that the chances of that happening are astronomically small, but I will check it in the future. This is just and information for you, and a reminder for me to create a new Jira for such a testing. No code changes are required. -- 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: notifications-unsubscr...@ignite.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org