This is an automated email from the ASF dual-hosted git repository.

xingtanzjr pushed a commit to branch rel/1.1
in repository https://gitbox.apache.org/repos/asf/iotdb.git


The following commit(s) were added to refs/heads/rel/1.1 by this push:
     new ee1cd45e646 fix concurrent modification (#10183)
ee1cd45e646 is described below

commit ee1cd45e6460a457ceef160f2384b86b77d2a331
Author: Alan Choo <[email protected]>
AuthorDate: Fri Jun 16 18:47:23 2023 +0800

    fix concurrent modification (#10183)
---
 .../main/java/org/apache/iotdb/db/engine/storagegroup/DataRegion.java   | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git 
a/server/src/main/java/org/apache/iotdb/db/engine/storagegroup/DataRegion.java 
b/server/src/main/java/org/apache/iotdb/db/engine/storagegroup/DataRegion.java
index aa550edb29e..2bb1b55e923 100644
--- 
a/server/src/main/java/org/apache/iotdb/db/engine/storagegroup/DataRegion.java
+++ 
b/server/src/main/java/org/apache/iotdb/db/engine/storagegroup/DataRegion.java
@@ -3146,7 +3146,7 @@ public class DataRegion implements IDataRegionForQuery {
   }
 
   public Long getLatestTimePartition() {
-    return 
partitionMaxFileVersions.keySet().stream().max(Long::compareTo).orElse(0L);
+    return getTimePartitions().stream().max(Long::compareTo).orElse(0L);
   }
 
   public String getInsertWriteLockHolder() {

Reply via email to