Hi,

I created my own Codec and I am trying to create new file format based on
the segment number for my doc values. For each segment number i create my
file.  My DocValuesConsumer is able to create files when writing the
documents to the index as we have the segment number from the SegmentInfo.
But during the segment merge cases, i am not able to delete the files
corresponding to the segments being merged. This is because we do not seem
to pass the original segment info
<https://github.com/apache/lucene-solr/blob/master/lucene/core/src/java/org/apache/lucene/index/MergePolicy.java#L215>
passed to the  MergeState
<https://github.com/apache/lucene-solr/blob/master/lucene/core/src/java/org/apache/lucene/index/MergeState.java>
.
I am thinking, if we atleast pass the list of segment numbers undergoing
merge, it would be helpful for the use cases like me. Also i think it makes
sense for the MergeState to know the segment numbers for which this state
belongs to.

So i am hoping we can add a List<String> segmentNames to the MergeState,

If you think its a valid use case, i can create jira and raise a PR.
-- 
With Regards,
N.Vamshi Vijay,
Mobile:- +1 206-660-9271

Reply via email to