-
Notifications
You must be signed in to change notification settings - Fork 25.2k
Add version to Analyzers #3790
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
+1 to push! |
It'd be nice to let the user request a specific version of the prebuilt analyzer. Something like "standard circa 0.90.5". That way when I update elasticsearch and build a new index using the prebuilt analyzer I still get the one I expect. |
we can do this already, you can specify the lucene version. We will not change |
Sounds good to me. Thanks! |
cool! |
looks great! thanks for the additional test. Please push it! |
The integration test is actually useless, because I did not test if the corresponding analyzers were really loaded. By doing this I found out, that they were not - because we overwrite the Fixed this, please check again in a second |
Updated. Crucial change (allows to configure the index version) in spinscale@853f64a#diff-beee1cd752cd81f3779332628d5b296eL255 Not sure if we want to leave this in? |
I think that is ok though - I don't think we guarantee anything here so that is fine? simon |
This patch takes the version of the created index into account when a prebuilt analyzer is created. So, if an index was created with 0.90.4, then the prebuilt analyzers will be the same than on the 0.90.4 release. One reason for this feature is the possibility to change pre built analyzers like the standard one. The patch tries to reuse analyzers as mutch as possible. So even if version X.Y.Z and X.Y.A use the same lucene analyzers, the same instance is reused in order to prevent overcreation of lucene analyzer instances. Closes #3790
Due to fix [3790](elastic/elasticsearch#3790) in core, upgrading an analyzer provided as a plugin now fails. See elastic/elasticsearch#4936 for details. Issue is in elasticsearch core code but can be fixed in plugins by overloading `PreBuiltTokenFilterFactoryFactory` and `PreBuiltAnalyzerProviderFactory`. Closes #18.
Due to fix [3790](elastic/elasticsearch#3790) in core, upgrading an analyzer provided as a plugin now fails. See elastic/elasticsearch#4936 for details. Issue is in elasticsearch core code but can be fixed in plugins by overloading `PreBuiltTokenFilterFactoryFactory` and `PreBuiltAnalyzerProviderFactory`. Closes #18. (cherry picked from commit fc68d81)
Due to fix [3790](elastic/elasticsearch#3790) in core, upgrading an analyzer provided as a plugin now fails. See elastic/elasticsearch#5030 for details. Issue is in elasticsearch core code but can be fixed in plugins by overloading `PreBuiltAnalyzerProviderFactory`, `PreBuiltTokenFilterFactoryFactory`, `PreBuiltTokenizerFactoryFactory` or `PreBuiltCharFilterFactoryFactory ` when used. Closes #21 (cherry picked from commit 3401c21)
Due to fix [3790](elastic/elasticsearch#3790) in core, upgrading an analyzer provided as a plugin now fails. See elastic/elasticsearch#5030 for details. Issue is in elasticsearch core code but can be fixed in plugins by overloading `PreBuiltAnalyzerProviderFactory`, `PreBuiltTokenFilterFactoryFactory`, `PreBuiltTokenizerFactoryFactory` or `PreBuiltCharFilterFactoryFactory ` when used. Closes #21
This patch takes the version of the created index into account when a prebuilt analyzer is created. So, if an index was created with 0.90.4, then the prebuilt analyzers will be the same than on the 0.90.4 release. One reason for this feature is the possibility to change pre built analyzers like the standard one. The patch tries to reuse analyzers as mutch as possible. So even if version X.Y.Z and X.Y.A use the same lucene analyzers, the same instance is reused in order to prevent overcreation of lucene analyzer instances. Closes elastic#3790
This relates somewhat to #3775 since we want to change the default analyzer in 1.0 we somehow need to decide which version of an analyzer we need to load for a name in a mapping. For instance if an index was created with
0.90.x
or earlier the olddefault
analyzer must be used in order to maintain index backwards compatibility for searches etc.We don't necessarily need this in
0.90
but for now I flagged it as0.90
unless it's breaking anythingThe text was updated successfully, but these errors were encountered: