Skip to content

Conversation

DaveCTurner
Copy link
Contributor

Rather than hard-coding a region name we should always auto-generate it
randomly during test execution. This commit replaces the remaining fixed
String arguments with a Supplier<String> argument to enable this.

Rather than hard-coding a region name we should always auto-generate it
randomly during test execution. This commit replaces the remaining fixed
`String` arguments with a `Supplier<String>` argument to enable this.
@DaveCTurner DaveCTurner added >test Issues or PRs that are addressing/adding tests :Distributed Coordination/Snapshot/Restore Anything directly related to the `_snapshot/*` APIs :Distributed Coordination/Discovery-Plugins Anything related to our integration plugins with EC2, GCP and Azure v8.19.0 v9.1.0 labels Apr 4, 2025
@elasticsearchmachine elasticsearchmachine added the Team:Distributed Coordination Meta label for Distributed Coordination team label Apr 4, 2025
@elasticsearchmachine
Copy link
Collaborator

Pinging @elastic/es-distributed-coordination (Team:Distributed Coordination)

Copy link
Contributor

@DiannaHohensee DiannaHohensee left a comment

Choose a reason for hiding this comment

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

Looks fine to me 👍 Though I'm not sure where you're headed with the change.

IIUC, a Supplier was used to get around static requirements for random string generation. There then isn't a need for a Supplier beyond feeding an initial method call: is this symmetry or are you heading someplace else with the change?

@DaveCTurner DaveCTurner added auto-merge-without-approval Automatically merge pull request when CI checks pass (NB doesn't wait for reviews!) auto-backport Automatically create backport pull requests when merged labels Apr 4, 2025
@DaveCTurner
Copy link
Contributor Author

In the v2 SDK upgrade I want to assert these regions more strongly since the region behaviour is changing, but I don't really want to continue to generate them statically, thought it'd be better to do this up front.

@elasticsearchmachine elasticsearchmachine merged commit 7239540 into elastic:main Apr 4, 2025
17 checks passed
@DaveCTurner DaveCTurner deleted the 2025/04/04/dynamic-aws-regions-everywhere branch April 4, 2025 15:27
DaveCTurner added a commit to DaveCTurner/elasticsearch that referenced this pull request Apr 4, 2025
Rather than hard-coding a region name we should always auto-generate it
randomly during test execution. This commit replaces the remaining fixed
`String` arguments with a `Supplier<String>` argument to enable this.
@elasticsearchmachine
Copy link
Collaborator

💚 Backport successful

Status Branch Result
8.x

elasticsearchmachine pushed a commit that referenced this pull request Apr 4, 2025
…26323)

Rather than hard-coding a region name we should always auto-generate it
randomly during test execution. This commit replaces the remaining fixed
`String` arguments with a `Supplier<String>` argument to enable this.
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 auto-merge-without-approval Automatically merge pull request when CI checks pass (NB doesn't wait for reviews!) :Distributed Coordination/Discovery-Plugins Anything related to our integration plugins with EC2, GCP and Azure :Distributed Coordination/Snapshot/Restore Anything directly related to the `_snapshot/*` APIs Team:Distributed Coordination Meta label for Distributed Coordination team >test Issues or PRs that are addressing/adding tests v8.19.0 v9.1.0

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants