Details
-
New Feature
-
Status: Resolved
-
Major
-
Resolution: Fixed
-
None
-
None
Description
Implementing "protectIndices" could have a consequence that some updated FSs could be removed from the indices by the framework, and addedback later. If the user code were iterating they might get unexpected ConcurrentModificationExceptions because of this.
Extend the iterators to include "snapshot" iterators, that take a snapshot of the index contents at iterator creation time, and then use that to iterate over; this allows the iterator to avoid ConcurrentModificationExceptions.
Do this in a manner to continue to support the "extended for" style of iterating, where you can write
for (MyAnnotation : fsIndexProducingSnapshotIterators) { ... }