Skip to content
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

Ignore 3x segment upgrade if unneeded #11383

Merged
merged 1 commit into from May 28, 2015

Conversation

dakrone
Copy link
Member

@dakrone dakrone commented May 27, 2015

If the index was created with 0.90.x or later, skip the check for 3x
segments, since Lucene 4.x was used for those versions.

This helps in particular with sharedfs recoveries, where the check for
upgrading segments can cause FS race conditions.

(Note, this is for 1.x only)

Slightly related to #11361

@dakrone
Copy link
Member Author

dakrone commented May 28, 2015

@s1monw pushed another commit making this encapsulated into the InternalEngine

@@ -118,7 +119,24 @@ public InternalEngine(EngineConfig engineConfig) throws EngineException {
boolean success = false;
try {
try {
upgrade3xSegments(store);
String version = engineConfig.getIndexSettings().get("index.version.created");
boolean autoUpgrade = true;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

can you use Version#indexCreated(Settings) here instead?

@s1monw
Copy link
Contributor

s1monw commented May 28, 2015

left one comment otherwise LGTM

If the index was created with 0.90.x or later, skip the check for 3x
segments, since Lucene 4.x was used for those versions.

This helps in particular with sharedfs recoveries, where the check for
upgrading segments can cause FS race conditions.
@imotov
Copy link
Contributor

imotov commented May 28, 2015

@s1monw Are we saying that v1.6 will not be compatible with indices created before v0.19?

@imotov
Copy link
Contributor

imotov commented May 29, 2015

@s1monw I see. Thanks! It looks like this is going to be a problem only in master, which cannot open these files anyway. It might be a good idea to improve the error message though. I will take a look.

@clintongormley clintongormley changed the title [ENGINE] Ignore 3x segment upgrade if unneeded Ignore 3x segment upgrade if unneeded May 29, 2015
@dakrone dakrone deleted the ignore-segment-upgrade branch June 1, 2015 22:34
@clintongormley clintongormley added :Distributed/Distributed A catch all label for anything in the Distributed Area. If you aren't sure, use this one. :Distributed/Engine Anything around managing Lucene and the Translog in an open shard. and removed :Engine :Distributed/Distributed A catch all label for anything in the Distributed Area. If you aren't sure, use this one. labels Feb 13, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
>bug :Distributed/Engine Anything around managing Lucene and the Translog in an open shard. v1.6.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants