Skip to content

Fix after restore Lucene.pruneUnreferencedFiles() conditional#81047

Merged
tlrx merged 1 commit intoelastic:masterfrom
tlrx:fix-after-restore-condi
Nov 25, 2021
Merged

Fix after restore Lucene.pruneUnreferencedFiles() conditional#81047
tlrx merged 1 commit intoelastic:masterfrom
tlrx:fix-after-restore-condi

Conversation

@tlrx
Copy link
Copy Markdown
Member

@tlrx tlrx commented Nov 25, 2021

In #68821 we introduced a condition to skip the pruning of unreferenced files after the restore of a snapshot for searchable snapshot shards. Sadly I managed to mess this up in a refactoring (#75308) few months after.

This commit reintroduces the right conditional which is to NOT prune Lucene files for searchable snapshot shards.

@tlrx tlrx added >bug :Distributed/Snapshot/Restore Anything directly related to the `_snapshot/*` APIs v8.0.0 v7.16.1 v8.1.0 labels Nov 25, 2021
@elasticmachine elasticmachine added the Team:Distributed Meta label for distributed team. label Nov 25, 2021
@tlrx tlrx requested a review from ywelsch November 25, 2021 12:57
Copy link
Copy Markdown
Contributor

@ywelsch ywelsch left a comment

Choose a reason for hiding this comment

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

LGTM. I will follow-up with a change to remove this logic altogether

@tlrx tlrx merged commit 8ee05f9 into elastic:master Nov 25, 2021
@tlrx tlrx deleted the fix-after-restore-condi branch November 25, 2021 14:26
@tlrx
Copy link
Copy Markdown
Member Author

tlrx commented Nov 25, 2021

Thanks Yannick!

tlrx added a commit to tlrx/elasticsearch that referenced this pull request Nov 25, 2021
…c#81047)

In elastic#68821 we introduced a condition to skip the pruning of 
unreferenced files after the restore of a snapshot for 
searchable snapshot shards. Sadly I managed to mess 
this up in a refactoring (elastic#75308) few months after.

This commit reintroduces the right conditional which is 
to NOT prune Lucene files for searchable snapshot shards.
tlrx added a commit to tlrx/elasticsearch that referenced this pull request Nov 25, 2021
…c#81047)

In elastic#68821 we introduced a condition to skip the pruning of 
unreferenced files after the restore of a snapshot for 
searchable snapshot shards. Sadly I managed to mess 
this up in a refactoring (elastic#75308) few months after.

This commit reintroduces the right conditional which is 
to NOT prune Lucene files for searchable snapshot shards.
@elasticsearchmachine
Copy link
Copy Markdown
Collaborator

💚 Backport successful

Status Branch Result
8.0
7.16

elasticsearchmachine pushed a commit that referenced this pull request Nov 25, 2021
#81051)

In #68821 we introduced a condition to skip the pruning of 
unreferenced files after the restore of a snapshot for 
searchable snapshot shards. Sadly I managed to mess 
this up in a refactoring (#75308) few months after.

This commit reintroduces the right conditional which is 
to NOT prune Lucene files for searchable snapshot shards.
elasticsearchmachine pushed a commit that referenced this pull request Nov 26, 2021
#81050)

In #68821 we introduced a condition to skip the pruning of 
unreferenced files after the restore of a snapshot for 
searchable snapshot shards. Sadly I managed to mess 
this up in a refactoring (#75308) few months after.

This commit reintroduces the right conditional which is 
to NOT prune Lucene files for searchable snapshot shards.

Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
@danhermann danhermann added v7.16.0 and removed v7.16.1 labels Dec 3, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

>bug :Distributed/Snapshot/Restore Anything directly related to the `_snapshot/*` APIs Team:Distributed Meta label for distributed team. v7.16.0 v8.0.0 v8.1.0

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants