xy720 commented on code in PR #33028:
URL: https://github.com/apache/doris/pull/33028#discussion_r1545722812


##########
fe/fe-core/src/main/java/org/apache/doris/cloud/transaction/CloudGlobalTransactionMgr.java:
##########
@@ -548,11 +548,25 @@ private void getPartitionInfo(List<OlapTable> tableList,
 
     private Map<Long, Long> getPartitionVersions(Map<Long, Partition> 
partitionMap) {
         Map<Long, Long> partitionToVersions = Maps.newHashMap();
+        List<CloudPartition> cloudPartitions = Lists.newArrayList();
         partitionMap.forEach((key, value) -> {
-            long visibleVersion = value.getVisibleVersion();
-            long newVersion = visibleVersion <= 0 ? 2 : visibleVersion + 1;
-            partitionToVersions.put(key, newVersion);
+            if (value instanceof CloudPartition) {
+                cloudPartitions.add((CloudPartition) value);
+            } else {
+                long visibleVersion = value.getVisibleVersion();
+                long newVersion = visibleVersion <= 0 ? 2 : visibleVersion + 1;
+                partitionToVersions.put(key, newVersion);
+            }
         });
+        try {
+            List<Long> visibleVersion = 
CloudPartition.getSnapshotVisibleVersion(cloudPartitions);

Review Comment:
   https://apple.github.io/foundationdb/developer-guide.html#snapshot-isolation



-- 
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: commits-unsubscr...@doris.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscr...@doris.apache.org
For additional commands, e-mail: commits-h...@doris.apache.org

Reply via email to