sonatype/nexus-oss — pull request #278 by cstamas (2013-12-11 15:29:03+00:00)
Title: NEXUS-6156: Deleted files left after optimize

This was due to the fact that SearcherManager
maybeRefresh() method was invoked only before
ANY search attempt, that made manager perform
a bookkeeping that released deleted files.

This is basically true to any operation modifying
and committing to index, but is most "visible"
after optimizing of huge index, as it left
Lucene index with double sized segments (the
deleted files got copied into new segment file).

Still, since all the ops doing "heavy lifting"
like merge or replace on context does invoke
optimize as last step, having this happen
here is okay thing, in contrast to do the same
on IndexingContext#commit, where it would happen
"too often" harming the performance of small
but frequent index changes (ie. deploys).

Issue
https://issues.sonatype.org/browse/NEXUS-6156

CI
TBD