gjacoby126 commented on a change in pull request #672: PHOENIX-5658 IndexTool
to verify index rows inline
URL: https://github.com/apache/phoenix/pull/672#discussion_r363866549
##########
File path:
phoenix-core/src/main/java/org/apache/phoenix/coprocessor/UngroupedAggregateRegionObserver.java
##########
@@ -1291,6 +1470,38 @@ public boolean next(List<Cell> results) throws
IOException {
} finally {
region.closeRegionOperation();
}
+ if (verify) {
+ ArrayList<KeyRange> keys = new ArrayList<>(rowCountPerTask);
+ for (byte[] key : dataPutMap.keySet()) {
+ keys.add(PVarbinary.INSTANCE.getKeyRange(key));
+ if (keys.size() == rowCountPerTask) {
+ addVerifyTask(keys);
+ keys = new ArrayList<>(rowCountPerTask);
+ }
+ }
+ if (keys.size() > 0) {
+ addVerifyTask(keys);
+ }
+ List<Boolean> taskResultList = null;
+ try {
+ LOGGER.debug("Waiting on index verify tasks to
complete...");
+ taskResultList = this.pool.submitUninterruptible(tasks);
+ } catch (ExecutionException e) {
+ throw new RuntimeException("Should not fail on the results
while using a WaitForCompletionTaskRunner", e);
+ } catch (EarlyExitFailure e) {
+ throw new RuntimeException("Stopped while waiting for
batch, quiting!", e);
Review comment:
nit: "quitting"
----------------------------------------------------------------
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