[
https://issues.apache.org/jira/browse/SOLR-9778?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15677601#comment-15677601
]
David Smiley commented on SOLR-9778:
------------------------------------
It's still possible to shoot yourself in the foot :-) The main objective of
this issue is to do the right thing automatically -- wherein the user never
specifies luceneMatchVersion. I believe the plan above does that.
One reason to specify luceneMatchVersion in solrconfig.xml is to ensure you
benefit from some analysis bug fixes after upgrading Solr without having to
re-index -- _provided you know or have tested it's safe_. This is true with or
without the protocol specified in this issue. If luceneMatchVersion is set in
solrconfig.xml to some value that differs from whatever the version was used to
analyze data in the existing indexes, and you index more data, then it's true
some segments with some of the same original text fragments might analyze
differently. _Again, this is true with or without the protocol specified in
this issue._
I suppose the ideal spot to record the luceneMatchVersion would be on the
segment somehow, but I'm not sure that's possible and I don't think there's
much value in that fidelity vs. the commit point metadata.
> Make luceneMatchVersion handling easy/automatic
> -----------------------------------------------
>
> Key: SOLR-9778
> URL: https://issues.apache.org/jira/browse/SOLR-9778
> Project: Solr
> Issue Type: Improvement
> Security Level: Public(Default Security Level. Issues are Public)
> Reporter: David Smiley
>
> I was thinking about luceneMatchVersion and how it's annoying to both explain
> and get right, and maintain. I think there's a way in Solr we can do this
> way better:
> When an index is initialized, record the luceneMatchVersion in effect into a
> file in the data directory, like luceneMatchVersion.txt. It's a file that
> will never be modified.
> The luceneMatchVersion in effect is the first of these that are specified:
> * {{<luceneMatchVersion>}} in solrconfig.xml
> * data/luceneMatchVersion.txt
> * {{org.apache.lucene.util.Version.LATEST}}
> With this approach, we can eliminate putting {{<luceneMatchVersion>}} into
> solrconfig.xml by default. Most users will have no need to bother setting
> it, even during an upgrade of either an existing index, or when they
> re-index. Of course there are cases where the user knows what they are doing
> and insists on a different luceneMatchVersion, and they can specify that
> still.
> Perhaps instead of a new file (data/luceneMatchVersion.txt), it might go into
> core.properties. I dunno.
> _(disclaimer: as I write this, I have no plans to work on this at the moment)_
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]