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

[DSL] Introduce data stream global retention - Part 3 #105682

Merged

Conversation

gmarouli
Copy link
Contributor

@gmarouli gmarouli commented Feb 21, 2024

In this PR we introduce the API that will expose the global retention configuration and will allow users to take advantage of it.

These APIs are protected by the dedicated introduced privileges:

  • manage_data_stream_global_retention or higher, which allows all operations on the global retention configuration
  • monitor_data_stream_retention or higher, which allows the retrieval of the global retention configuration

This PR is not delivering the complete feature since the global retention is not used yet.

Relevant documentation:

Copy link

Documentation preview:

@gmarouli gmarouli added the :Data Management/Data streams Data streams and their lifecycles label Feb 21, 2024
@gmarouli gmarouli marked this pull request as ready for review March 4, 2024 15:40
@elasticsearchmachine elasticsearchmachine added the Team:Data Management Meta label for data/management team label Mar 4, 2024
@elasticsearchmachine
Copy link
Collaborator

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

@gmarouli
Copy link
Contributor Author

gmarouli commented Mar 4, 2024

Investigating the bwc failures

@gmarouli
Copy link
Contributor Author

gmarouli commented Mar 4, 2024

The bwc failures, happened because of the missing feature health.extended_repository_indicator. It was fixed as soon as I updated the branch with main. I expect the tests will pass now.

@@ -1,7 +1,7 @@
---
"Explain backing index lifecycle":
- skip:
version: " - 8.13.99"
cluster_features: ["datastream_lifecycle", "data_stream.lifecycle.global_retention"]
Copy link
Contributor

Choose a reason for hiding this comment

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

This is cool, much nicer than than specifying a numeric version. I think I need to go change a yaml test I just wrote ...

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Yes, I also liked it a lot, but I couldn't make it work in one test. I do not know yet why, it's in my todo list to see if it has a conflict when there is a skip with a version in the setup step :(. It looks like it works in most tests though.

@gmarouli
Copy link
Contributor Author

I am leaning towards that test failure MixedClusterClientYamlTestSuiteIT » test {p0=mlt/30_unlike/Basic mlt query is not related to this PR. Because:

  • It is not using any lifecycle related features, it just creates an index and searches on it, so I can't imagine how this test can fail because of the global retention feature.
  • All the global retention tests are skipped because this test is using 7.17.19, so I do not see any test interference.
  • I found the same failure back in January.

Copy link
Contributor

@parkertimmins parkertimmins left a comment

Choose a reason for hiding this comment

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

LGTM, great tutorial btw!

@elasticsearchmachine
Copy link
Collaborator

Hi @gmarouli, I've updated the changelog YAML for you. Note that since this PR is labelled release highlight, you need to update the changelog YAML to fill out the extended information sections.

Copy link
Member

@masseyke masseyke left a comment

Choose a reason for hiding this comment

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

LGTM

@gmarouli gmarouli merged commit 2122da3 into elastic:main Mar 28, 2024
14 checks passed
@elasticsearchmachine
Copy link
Collaborator

@gmarouli according to this PR's labels, I need to update the changelog YAML, but I can't because the PR is closed. Please either update the changelog yourself on the appropriate branch, or adjust the labels. Specifically:

  • The PR is not labelled release highlight but the changelog has a highlight section

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
:Data Management/Data streams Data streams and their lifecycles >feature Team:Data Management Meta label for data/management team v8.14.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

6 participants