zhangyue19921010 commented on code in PR #11232:
URL: https://github.com/apache/paimon/pull/11232#discussion_r4624128105


##########
paimon-core/src/main/java/org/apache/paimon/append/cluster/HistoryPartitionCluster.java:
##########
@@ -129,12 +128,7 @@ public Map<BinaryRow, CompactUnit> 
pickForHistoryPartitions() {
 
     @VisibleForTesting
     public Map<BinaryRow, List<LevelSortedRun>> 
constructLevelsForHistoryPartitions() {
-        long historyMilli =
-                LocalDateTime.now()
-                        .minus(historyPartitionIdleTime)
-                        .atZone(ZoneId.systemDefault())
-                        .toInstant()
-                        .toEpochMilli();
+        long historyMilli = 
Instant.now().minus(historyPartitionIdleTime).toEpochMilli();

Review Comment:
   Fixed in 2b17b2f: since the persisted local time cannot distinguish the two 
occurrences, the idle check now resolves a repeated-hour creation time to the 
later occurrence, so a partition is never picked early (a file from the first 
occurrence may wait up to one extra hour). Added your `America/New_York` case 
(created at `06:15Z`, planned at `07:45Z`), which fails before this change and 
passes now.



-- 
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]

Reply via email to