Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fixes intermittent failure in ScanConsistencyIT (#4292)
The following failure was observed when running ScanConsistencyIT in the elasticity branch. ``` java.util.concurrent.ExecutionException: java.util.NoSuchElementException at java.base/java.util.concurrent.FutureTask.report(FutureTask.java:122) at java.base/java.util.concurrent.FutureTask.get(FutureTask.java:191) at org.apache.accumulo.test.ScanConsistencyIT.testConcurrentScanConsistency(ScanConsistencyIT.java:186) at java.base/java.lang.reflect.Method.invoke(Method.java:566) at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264) at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128) at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628) at java.base/java.lang.Thread.run(Thread.java:829) Caused by: java.util.NoSuchElementException at com.google.common.collect.MoreCollectors$ToOptionalState.getElement(MoreCollectors.java:163) at com.google.common.collect.MoreCollectors.lambda$static$1(MoreCollectors.java:75) at java.base/java.util.stream.ReferencePipeline.collect(ReferencePipeline.java:582) at org.apache.accumulo.test.ScanConsistencyIT$TableOpsTask.call(ScanConsistencyIT.java:685) at org.apache.accumulo.test.ScanConsistencyIT$TableOpsTask.call(ScanConsistencyIT.java:622) ... 4 more ``` This was caused by the test attempting to do a filter compaction when there was currently no data to delete. Added a check for this case in this commit.