gjacoby126 commented on a change in pull request #751: PHOENIX-5735 Add the
maxLookBack logic in the inline validation.
URL: https://github.com/apache/phoenix/pull/751#discussion_r402653091
##########
File path:
phoenix-core/src/main/java/org/apache/phoenix/coprocessor/IndexRebuildRegionScanner.java
##########
@@ -859,39 +898,54 @@ public boolean verifySingleIndexRow(Result indexRow,
IndexToolVerificationResult
(actual instanceof Delete && isDeleteFamily(actual))) {
expectedIndex++;
actualIndex++;
- matchingCount++;
continue;
}
}
- if (matchingCount > 0) {
- break;
+ break;
+ }
+
+ if (expectedIndex == expectedSize ){
+ // every expected mutation has its matching one in the actual list.
+ verificationPhaseResult.validIndexRowCount++;
+ return true;
+ }
+
+ if (isTimestampBeyondMaxLookBack(currentTime,
getTimestamp(expectedMutationList.get(expectedIndex)))){
+ if (expectedIndex > 0) {
+ // if current expected index mutation is beyond max look back
window, we only need to make sure its latest
+ // mutation get the matching one, as SCN query is required to
be within the MaxLookBack window.
Review comment:
nit: "mutation is a matching one, as an SCN query is required"
----------------------------------------------------------------
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:
[email protected]
With regards,
Apache Git Services