tkalkirill commented on code in PR #13736:
URL: https://github.com/apache/ignite/pull/13736#discussion_r4471497493
##########
modules/calcite/src/main/java/org/apache/ignite/internal/processors/query/calcite/exec/AbstractCacheScan.java:
##########
@@ -121,9 +122,22 @@ protected synchronized void reserve() {
GridDhtTopologyFuture topFut = top.topologyVersionFuture();
boolean done = topFut.isDone();
-
- if (!done || !(topFut.topologyVersion().compareTo(topVer) >= 0
- &&
cctx.shared().exchange().lastAffinityChangedTopologyVersion(topFut.initialVersion()).compareTo(topVer)
<= 0)) {
+ AffinityTopologyVersion readyTopVer;
Review Comment:
A transaction can keep a topology exchange unfinished until commit or
rollback.
Previously, AbstractCacheScan rejected any unfinished exchange, causing
SELECT within that transaction to fail after the statistics-related hang was
resolved.
For queries carrying transaction entries, validate the query mapping against
the already ready topology and reserve the required partitions before scanning.
This checks compatibility with the ready topology; it does not determine
which caches the pending exchange affects.
--
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]