OpenSearch/x-pack/plugin/ilm
Armin Braun 3c20541823
Cleanup Concurrent RepositoryData Loading (#48329) (#48834)
The loading of `RepositoryData` is not an atomic operation.
It uses a list + get combination of calls.
This lead to accidentally returning an empty repository data
for generations >=0 which can never not exist unless the repository
is corrupted.
In the test #48122 (and other SLM tests) there was a low chance of
running into this concurrent modification scenario and the repository
actually moving two index generations between listing out the
index-N and loading the latest version of it. Since we only keep
two index-N around at a time this lead to unexpectedly absent
snapshots in status APIs.
Fixing the behavior to be more resilient is non-trivial but in the works.
For now I think we should simply throw in this scenario. This will also
help prevent corruption in the unlikely event but possible of running into this
issue in a snapshot create or delete operation on master failover on a
repository like S3 which doesn't have the "no overwrites" protection on
writing a new index-N.

Fixes #48122
2019-11-02 20:42:29 +01:00
..
qa Fix ilm/20_move_to_step basic moving to step (#48821) 2019-11-01 13:58:24 -06:00
src Cleanup Concurrent RepositoryData Loading (#48329) (#48834) 2019-11-02 20:42:29 +01:00
build.gradle Add retention to Snapshot Lifecycle Management (backport of #4… (#46506) 2019-09-10 09:08:09 -06:00