Skip to content

[8.1] Make DiscoveryNodes behave like a collection (#83453)#83535

Merged
arteam merged 1 commit intoelastic:8.1from
arteam:backport-discovery-nodes
Feb 4, 2022
Merged

[8.1] Make DiscoveryNodes behave like a collection (#83453)#83535
arteam merged 1 commit intoelastic:8.1from
arteam:backport-discovery-nodes

Conversation

@arteam
Copy link
Copy Markdown
Contributor

@arteam arteam commented Feb 4, 2022

Backports #83453 to 8.1

Extend from `AbstractCollection`. Advantages:

* Optimized version of `spliterator` based on the size implemented in `AbstractCollection` by default
* Exposed `stream` method, so consumers don't need to call `StreamSupport.stream(discoveryNodes.spliterator(), false)`

Backports elastic#83453 to 8.1

```
Extend from `AbstractCollection`. Advantages:

* Optimized version of `spliterator` based on the size implemented in `AbstractCollection` by default
* Exposed `stream` method, so consumers don't need to call `StreamSupport.stream(discoveryNodes.spliterator(), false)`
```
@arteam arteam added the backport label Feb 4, 2022
@arteam arteam merged commit 36dde7a into elastic:8.1 Feb 4, 2022
@arteam arteam deleted the backport-discovery-nodes branch February 4, 2022 17:38
arteam added a commit that referenced this pull request Feb 14, 2022
arteam added a commit that referenced this pull request Feb 14, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants