Skip to content

Simplify entitlement rest test discovery #125449

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 4 commits into from
Apr 9, 2025

Conversation

rjernst
Copy link
Member

@rjernst rjernst commented Mar 21, 2025

This commit cleans up how entitlement test methods are discovered. It also adds another robustness check to ensure an annotation doesn't exist on a private method.

This commit cleans up how entitlement test methods are discovered. It
also adds another robustness check to ensure an annotation doesn't exist
on a private method.
@rjernst rjernst added >test Issues or PRs that are addressing/adding tests auto-backport Automatically create backport pull requests when merged v8.18.1 v8.19.0 v9.0.1 v9.1.0 :Core/Infra/Entitlements Entitlements infrastructure labels Mar 21, 2025
@rjernst rjernst requested a review from a team as a code owner March 21, 2025 22:28
@elasticsearchmachine elasticsearchmachine added the Team:Core/Infra Meta label for core/infra team label Mar 21, 2025
@elasticsearchmachine
Copy link
Collaborator

Pinging @elastic/es-core-infra (Team:Core/Infra)

getTestEntries(entries, testClass, a -> a.fromJavaVersion() == null || Runtime.version().feature() >= a.fromJavaVersion());
}
@SuppressWarnings("unchecked")
Entry<String, CheckAction>[] entriesArray = entries.toArray(new Entry[0]);
Copy link
Contributor

@mosche mosche Apr 9, 2025

Choose a reason for hiding this comment

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

@rjernst this doesn't compile atm

warning: [rawtypes] found raw type: Entry
--
  | Entry<String, CheckAction>[] entriesArray = entries.toArray(new Entry[0]);

Copy link
Member Author

Choose a reason for hiding this comment

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

Oops. I've brought this PR up to date now and fixed this warning, see 647f97d

@dieferperalta
Copy link

No utilizo elastic

Copy link
Contributor

@mosche mosche left a comment

Choose a reason for hiding this comment

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

lgtm

@rjernst rjernst merged commit 2986d73 into elastic:main Apr 9, 2025
17 checks passed
@rjernst rjernst deleted the entitlements/it_test_cleanup3 branch April 9, 2025 14:24
@elasticsearchmachine
Copy link
Collaborator

💔 Backport failed

Status Branch Result
8.18 Commit could not be cherrypicked due to conflicts
8.x Commit could not be cherrypicked due to conflicts
9.0

You can use sqren/backport to manually backport by running backport --upstream elastic/elasticsearch --pr 125449

rjernst added a commit to rjernst/elasticsearch that referenced this pull request Apr 9, 2025
This commit cleans up how entitlement test methods are discovered. It
also adds another robustness check to ensure an annotation doesn't exist
on a private method.
rjernst added a commit to rjernst/elasticsearch that referenced this pull request Apr 9, 2025
This commit cleans up how entitlement test methods are discovered. It
also adds another robustness check to ensure an annotation doesn't exist
on a private method.
rjernst added a commit to rjernst/elasticsearch that referenced this pull request Apr 9, 2025
This commit cleans up how entitlement test methods are discovered. It
also adds another robustness check to ensure an annotation doesn't exist
on a private method.
elasticsearchmachine pushed a commit that referenced this pull request Apr 9, 2025
This commit cleans up how entitlement test methods are discovered. It
also adds another robustness check to ensure an annotation doesn't exist
on a private method.
elasticsearchmachine pushed a commit that referenced this pull request Apr 9, 2025
This commit cleans up how entitlement test methods are discovered. It
also adds another robustness check to ensure an annotation doesn't exist
on a private method.
elasticsearchmachine pushed a commit that referenced this pull request Apr 9, 2025
This commit cleans up how entitlement test methods are discovered. It
also adds another robustness check to ensure an annotation doesn't exist
on a private method.
donoghuc added a commit to donoghuc/logstash that referenced this pull request Apr 9, 2025
With a recent change in ES elastic/elasticsearch#125449
configuring path.data or path.logs to directories that do not exist cause ES to
not be able to start up. This commit ensures those directories exist. The
teardown script already ensures they are removed https://github.com/elastic/logstash/blob/712b37e1df333e8d156cb5d26fbc24aafcbfd2cd/qa/integration/services/elasticsearch_teardown.sh#L26-L27
mashhurs pushed a commit to elastic/logstash that referenced this pull request Apr 9, 2025
With a recent change in ES elastic/elasticsearch#125449
configuring path.data or path.logs to directories that do not exist cause ES to
not be able to start up. This commit ensures those directories exist. The
teardown script already ensures they are removed https://github.com/elastic/logstash/blob/712b37e1df333e8d156cb5d26fbc24aafcbfd2cd/qa/integration/services/elasticsearch_teardown.sh#L26-L27
mergify bot pushed a commit to elastic/logstash that referenced this pull request Apr 9, 2025
With a recent change in ES elastic/elasticsearch#125449
configuring path.data or path.logs to directories that do not exist cause ES to
not be able to start up. This commit ensures those directories exist. The
teardown script already ensures they are removed https://github.com/elastic/logstash/blob/712b37e1df333e8d156cb5d26fbc24aafcbfd2cd/qa/integration/services/elasticsearch_teardown.sh#L26-L27

(cherry picked from commit 8e6e183)
mergify bot pushed a commit to elastic/logstash that referenced this pull request Apr 9, 2025
With a recent change in ES elastic/elasticsearch#125449
configuring path.data or path.logs to directories that do not exist cause ES to
not be able to start up. This commit ensures those directories exist. The
teardown script already ensures they are removed https://github.com/elastic/logstash/blob/712b37e1df333e8d156cb5d26fbc24aafcbfd2cd/qa/integration/services/elasticsearch_teardown.sh#L26-L27

(cherry picked from commit 8e6e183)
mergify bot pushed a commit to elastic/logstash that referenced this pull request Apr 9, 2025
With a recent change in ES elastic/elasticsearch#125449
configuring path.data or path.logs to directories that do not exist cause ES to
not be able to start up. This commit ensures those directories exist. The
teardown script already ensures they are removed https://github.com/elastic/logstash/blob/712b37e1df333e8d156cb5d26fbc24aafcbfd2cd/qa/integration/services/elasticsearch_teardown.sh#L26-L27

(cherry picked from commit 8e6e183)
mergify bot pushed a commit to elastic/logstash that referenced this pull request Apr 9, 2025
With a recent change in ES elastic/elasticsearch#125449
configuring path.data or path.logs to directories that do not exist cause ES to
not be able to start up. This commit ensures those directories exist. The
teardown script already ensures they are removed https://github.com/elastic/logstash/blob/712b37e1df333e8d156cb5d26fbc24aafcbfd2cd/qa/integration/services/elasticsearch_teardown.sh#L26-L27

(cherry picked from commit 8e6e183)
mergify bot pushed a commit to elastic/logstash that referenced this pull request Apr 9, 2025
With a recent change in ES elastic/elasticsearch#125449
configuring path.data or path.logs to directories that do not exist cause ES to
not be able to start up. This commit ensures those directories exist. The
teardown script already ensures they are removed https://github.com/elastic/logstash/blob/712b37e1df333e8d156cb5d26fbc24aafcbfd2cd/qa/integration/services/elasticsearch_teardown.sh#L26-L27

(cherry picked from commit 8e6e183)
mergify bot pushed a commit to elastic/logstash that referenced this pull request Apr 9, 2025
With a recent change in ES elastic/elasticsearch#125449
configuring path.data or path.logs to directories that do not exist cause ES to
not be able to start up. This commit ensures those directories exist. The
teardown script already ensures they are removed https://github.com/elastic/logstash/blob/712b37e1df333e8d156cb5d26fbc24aafcbfd2cd/qa/integration/services/elasticsearch_teardown.sh#L26-L27

(cherry picked from commit 8e6e183)

# Conflicts:
#	qa/integration/services/elasticsearch_setup.sh
donoghuc added a commit to elastic/logstash that referenced this pull request Apr 9, 2025
…#17533)

With a recent change in ES elastic/elasticsearch#125449
configuring path.data or path.logs to directories that do not exist cause ES to
not be able to start up. This commit ensures those directories exist. The
teardown script already ensures they are removed https://github.com/elastic/logstash/blob/712b37e1df333e8d156cb5d26fbc24aafcbfd2cd/qa/integration/services/elasticsearch_teardown.sh#L26-L27

(cherry picked from commit 8e6e183)

Co-authored-by: Cas Donoghue <[email protected]>
donoghuc added a commit to elastic/logstash that referenced this pull request Apr 9, 2025
…#17536)

With a recent change in ES elastic/elasticsearch#125449
configuring path.data or path.logs to directories that do not exist cause ES to
not be able to start up. This commit ensures those directories exist. The
teardown script already ensures they are removed https://github.com/elastic/logstash/blob/712b37e1df333e8d156cb5d26fbc24aafcbfd2cd/qa/integration/services/elasticsearch_teardown.sh#L26-L27

(cherry picked from commit 8e6e183)

Co-authored-by: Cas Donoghue <[email protected]>
donoghuc added a commit to elastic/logstash that referenced this pull request Apr 9, 2025
…#17537)

With a recent change in ES elastic/elasticsearch#125449
configuring path.data or path.logs to directories that do not exist cause ES to
not be able to start up. This commit ensures those directories exist. The
teardown script already ensures they are removed https://github.com/elastic/logstash/blob/712b37e1df333e8d156cb5d26fbc24aafcbfd2cd/qa/integration/services/elasticsearch_teardown.sh#L26-L27

(cherry picked from commit 8e6e183)

Co-authored-by: Cas Donoghue <[email protected]>
donoghuc added a commit to elastic/logstash that referenced this pull request Apr 9, 2025
…#17534)

With a recent change in ES elastic/elasticsearch#125449
configuring path.data or path.logs to directories that do not exist cause ES to
not be able to start up. This commit ensures those directories exist. The
teardown script already ensures they are removed https://github.com/elastic/logstash/blob/712b37e1df333e8d156cb5d26fbc24aafcbfd2cd/qa/integration/services/elasticsearch_teardown.sh#L26-L27

(cherry picked from commit 8e6e183)

Co-authored-by: Cas Donoghue <[email protected]>
donoghuc added a commit to elastic/logstash that referenced this pull request Apr 9, 2025
With a recent change in ES elastic/elasticsearch#125449
configuring path.data or path.logs to directories that do not exist cause ES to
not be able to start up. This commit ensures those directories exist. The
teardown script already ensures they are removed https://github.com/elastic/logstash/blob/712b37e1df333e8d156cb5d26fbc24aafcbfd2cd/qa/integration/services/elasticsearch_teardown.sh#L26-L27

(cherry picked from commit 8e6e183)
donoghuc added a commit to elastic/logstash that referenced this pull request Apr 9, 2025
…#17535)

With a recent change in ES elastic/elasticsearch#125449
configuring path.data or path.logs to directories that do not exist cause ES to
not be able to start up. This commit ensures those directories exist. The
teardown script already ensures they are removed https://github.com/elastic/logstash/blob/712b37e1df333e8d156cb5d26fbc24aafcbfd2cd/qa/integration/services/elasticsearch_teardown.sh#L26-L27

(cherry picked from commit 8e6e183)

Co-authored-by: Cas Donoghue <[email protected]>
donoghuc added a commit to elastic/logstash that referenced this pull request Apr 10, 2025
…#17538)

With a recent change in ES elastic/elasticsearch#125449
configuring path.data or path.logs to directories that do not exist cause ES to
not be able to start up. This commit ensures those directories exist. The
teardown script already ensures they are removed https://github.com/elastic/logstash/blob/712b37e1df333e8d156cb5d26fbc24aafcbfd2cd/qa/integration/services/elasticsearch_teardown.sh#L26-L27

(cherry picked from commit 8e6e183)

Co-authored-by: Cas Donoghue <[email protected]>
@prdoyle
Copy link
Contributor

prdoyle commented Apr 22, 2025

Backports:

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 :Core/Infra/Entitlements Entitlements infrastructure Team:Core/Infra Meta label for core/infra team >test Issues or PRs that are addressing/adding tests v8.18.1 v8.19.0 v9.0.1 v9.1.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants