apurtell commented on code in PR #2668:
URL: https://github.com/apache/phoenix/pull/2668#discussion_r4519475299
##########
phoenix-core-server/src/main/java/org/apache/phoenix/iterate/NonAggregateRegionScannerFactory.java:
##########
@@ -599,6 +618,15 @@ public boolean isFilterDone() {
return tuple == null;
}
+ // Get the next tuple. When the build becomes complete, size the chunk
to the cached rows.
+ private void nextTuple() throws SQLException {
+ tuple = iterator.next();
+ if (!isChunkSized && !isDummy(tuple)) {
+ chunk.resize(iterator.getByteSize());
+ isChunkSized = true;
+ }
+ }
Review Comment:
isDummy returns false for null, so a null tuple safely triggers the single
resize.
--
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]