Skip to content

Conversation

@alpar-t
Copy link
Contributor

@alpar-t alpar-t commented Oct 1, 2019

Before this PR we always ever ran ElasticsearchCluster.start once, and
the common node config was never done.
This becomes apparent in upgrading from 6.x to 7.x as the new config
is missing preventing the cluster from starting.

Before this PR we always ever ran `ElasticsearchCluster.start` once, and
the common node config was never done.
This becomes apparent in upgrading from `6.x` to `7.x` as the new config
is missing preventing the cluster from starting.
@alpar-t alpar-t added :Delivery/Build Build or test infrastructure v8.0.0 v7.5.0 labels Oct 1, 2019
@alpar-t alpar-t requested a review from mark-vieira October 1, 2019 13:47
@elasticmachine
Copy link
Collaborator

Pinging @elastic/es-core-infra

Copy link
Contributor

@mark-vieira mark-vieira left a comment

Choose a reason for hiding this comment

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

When we can we should prefer putting this kind of logic in ElasticsearchNode vs ElasticsearchCluster.

In any case, we need to address refactoring all this stuff to try and separate configuration from node-handling logic ASAP. All this handling of version-specific edge cases is starting to compound and make things hard to follow.

// Can only configure master nodes if we have node names defined
if (nodeNames != null) {
if (node.getVersion().onOrAfter("7.0.0")) {
node.defaultConfig.keySet().stream()
Copy link
Contributor

Choose a reason for hiding this comment

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

I'm pretty sure that, with the exception of initial_master_nodes all this can, and probably should, go in ElasticsearchNode#start().

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Technically yes, but these are settings relating to how the cluster forms that relate to each-other,
so the settings are per node, but relate to the cluster itself.
Granted we could pull other such settings up to the cluster level.
I agree on your points on refactoring but would like to complete the back-port first.

@alpar-t alpar-t merged commit 3a7ad13 into elastic:master Oct 4, 2019
@alpar-t alpar-t deleted the testclusters-cluster-config branch October 4, 2019 08:03
@mark-vieira mark-vieira added the Team:Delivery Meta label for Delivery team label Nov 11, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

:Delivery/Build Build or test infrastructure Team:Delivery Meta label for Delivery team v7.5.0 v8.0.0-alpha1

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants