Skip to content

Restrict failure stores from replicating via CCR #126355

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

Merged
merged 3 commits into from
Apr 9, 2025

Conversation

jbaiera
Copy link
Member

@jbaiera jbaiera commented Apr 5, 2025

Checks to see if an index belongs to a data stream's failure store before following it. If the index is a failure index, the follow operation is rejected. Also updates the logic in the auto follower API's to exclude failure indices on data streams from being followed if their parent data stream matches the follow pattern.

The auto follow test for data stream replication has been updated to operate on a data stream that has failure indices on it to ensure they are not replicated. The CCRLicenseChecker (where a surprising amount of validation for the put follow API takes place) has been updated to throw an exception when a failure store index is encountered.

Without this in place, when replicating a data stream with auto follow, the remote data stream's failure store indices are replicated to the local cluster and added to the data stream's backing index set instead of to its own failure store set. We have additional work/thinking that needs to be done before we can fix this and replicate them correctly. See #126356.

@jbaiera jbaiera added >non-issue :Distributed Indexing/CCR Issues around the Cross Cluster State Replication features :Data Management/Data streams Data streams and their lifecycles labels Apr 5, 2025
@elasticsearchmachine elasticsearchmachine added v9.1.0 Team:Data Management Meta label for data/management team Team:Distributed Indexing Meta label for Distributed Indexing team labels Apr 5, 2025
@elasticsearchmachine
Copy link
Collaborator

Pinging @elastic/es-distributed-indexing (Team:Distributed Indexing)

@elasticsearchmachine
Copy link
Collaborator

Pinging @elastic/es-data-management (Team:Data Management)

@jbaiera
Copy link
Member Author

jbaiera commented Apr 7, 2025

@elasticmachine update branch

@jbaiera jbaiera requested a review from a team April 7, 2025 20:31
Copy link
Contributor

@arteam arteam left a comment

Choose a reason for hiding this comment

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

LGTM! Thank you for the test verifying failure modes on different primitives!

@jbaiera jbaiera added auto-backport Automatically create backport pull requests when merged v8.19.0 labels Apr 9, 2025
@jbaiera jbaiera merged commit 6d86b20 into elastic:main Apr 9, 2025
17 checks passed
@jbaiera jbaiera deleted the failure-store-ccr-restriction branch April 9, 2025 18:52
@elasticsearchmachine
Copy link
Collaborator

💚 Backport successful

Status Branch Result
8.x

jbaiera added a commit to jbaiera/elasticsearch that referenced this pull request Apr 9, 2025
Checks to see if an index belongs to a data stream's failure store before following it. If the index is a 
failure index, the follow operation is rejected. Also updates the logic in the auto follower API's to 
exclude failure indices on data streams from being followed if their parent data stream matches the 
follow pattern.
elasticsearchmachine pushed a commit that referenced this pull request Apr 9, 2025
Checks to see if an index belongs to a data stream's failure store before following it. If the index is a 
failure index, the follow operation is rejected. Also updates the logic in the auto follower API's to 
exclude failure indices on data streams from being followed if their parent data stream matches the 
follow pattern.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
auto-backport Automatically create backport pull requests when merged :Data Management/Data streams Data streams and their lifecycles :Distributed Indexing/CCR Issues around the Cross Cluster State Replication features >non-issue Team:Data Management Meta label for data/management team Team:Distributed Indexing Meta label for Distributed Indexing team v8.19.0 v9.1.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants