lucene-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Michael McCandless (JIRA)" <>
Subject [jira] [Commented] (LUCENE-7999) Invalid segment file name
Date Mon, 23 Oct 2017 10:14:00 GMT


Michael McCandless commented on LUCENE-7999:

Patch looks good; thank you [~mikedemi]!  Very impressive you hit the limit of int in segment
file names!  I'm curious: how often do you refresh/commit and how long lived was this index?

I don't think you should check the index created version for this logic.  Instead, you should
add a new static final version constant at the top of {{}}, e.g. {{LUCENE_72}}
(since 7.1 is already released), and fix {{VERSION_CURRENT}} to point to that constant.  Then
fix the {{write}} method to always {{writeLong}} (maybe we should use {{writeVLong}}?).  Then
fix the {{readCommit}} method to use the (currently unused) {{format}} variable to switch
to {{readInt}} or {{readVLong}}.  See e.g. the 6.x version of {{}} which
does have switching based on that {{format}}.

> Invalid segment file name
> -------------------------
>                 Key: LUCENE-7999
>                 URL:
>             Project: Lucene - Core
>          Issue Type: Bug
>    Affects Versions: 5.x, 6.x, 7.0
>            Reporter: Mykhailo Demianenko
>            Priority: Minor
>         Attachments: segmentName.patch
> After really long and intensive index usage its possible to overflow counter that used
to generate new segment name that will not satisfy validation criteria:
> Caused by: java.lang.IllegalArgumentException: invalid codec filename '_-zik0zk_Lucene54_0.dvm',
must match: _[a-z0-9]+(_.*)?\..*
>     at org.apache.lucene.index.SegmentInfo.checkFileNames(
>     at org.apache.lucene.index.SegmentInfo.addFiles(
>     at org.apache.lucene.index.SegmentInfo.setFiles(
>     at org.apache.lucene.index.IndexWriter.mergeMiddle(
>     at org.apache.lucene.index.IndexWriter.merge(
>     at org.apache.lucene.index.ConcurrentMergeScheduler.doMerge(
>     at org.apache.lucene.index.ConcurrentMergeScheduler$

This message was sent by Atlassian JIRA

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message