iotdb-reviews mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From GitBox <...@apache.org>
Subject [GitHub] [iotdb] yyt86 commented on a change in pull request #3606: [IOTDB-1372] delete devices field in FileTimeIndex
Date Thu, 05 Aug 2021 19:45:07 GMT

yyt86 commented on a change in pull request #3606:
URL: https://github.com/apache/iotdb/pull/3606#discussion_r683740184



##########
File path: server/src/main/java/org/apache/iotdb/db/engine/storagegroup/timeindex/FileTimeIndex.java
##########
@@ -114,8 +81,14 @@ public void close() {
   }
 
   @Override
-  public Set<String> getDevices() {
-    return devices;
+  public Set<String> getDevices(String tsFilePath) {
+    try {
+      TsFileSequenceReader fileReader = FileReaderManager.getInstance().get(tsFilePath, true);
+      return new HashSet<>(fileReader.getAllDevices());
+    } catch (IOException e) {
+      logger.error("Can't read file {} from disk ", tsFilePath, e);

Review comment:
       I will create another PR to throw IOException for the method and all method callers.




-- 
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: reviews-unsubscribe@iotdb.apache.org

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



Mime
View raw message