You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@iotdb.apache.org by GitBox <gi...@apache.org> on 2021/02/18 07:11:14 UTC

[GitHub] [iotdb] HTHou commented on a change in pull request #2566: add some comments for SeriesReader

HTHou commented on a change in pull request #2566:
URL: https://github.com/apache/iotdb/pull/2566#discussion_r578178855



##########
File path: server/src/main/java/org/apache/iotdb/db/query/reader/series/SeriesReader.java
##########
@@ -390,15 +390,36 @@ boolean hasNextPage() throws IOException {
       /*
        * first chunk metadata is already unpacked, consume cached pages
        */
-      initFirstPageReader();
-      if (firstPageReader != null) {
-        long endpointTime = orderUtils.getOverlapCheckTime(firstPageReader.getStatistics());
-        unpackAllOverlappedTsFilesToTimeSeriesMetadata(endpointTime);
-        unpackAllOverlappedTimeSeriesMetadataToCachedChunkMetadata(endpointTime, false);
-        unpackAllOverlappedChunkMetadataToCachedPageReaders(endpointTime, false);
+      unpackFirstPageReader();
+    }
+
+    if (isExistOverlappedPage()) {
+      return true;
+    }
+
+    // make sure firstPageReader won't be null while cachedPageReaders has more cached page readers

Review comment:
       ```suggestion
       // make sure firstPageReader won't be null while the cachedPageReaders has more cached page readers
   ```




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

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