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

Always enforce cluster-wide shard limit #34892

Merged
merged 10 commits into from
Nov 27, 2018
Merged

Conversation

gwbrown
Copy link
Contributor

@gwbrown gwbrown commented Oct 25, 2018

This removes the option to run a cluster without enforcing the
cluster-wide shard limit, making strict enforcement the default and only
behavior. The limit can still be adjusted as desired using the cluster
settings API.

This is a follow-up to #34021

Closes #20705

This removes the option to run a cluster without enforcing the
cluster-wide shard limit, making strict enforcement the default and only
behavior.  The limit can still be adjusted as desired using the cluster
settings API.
@gwbrown gwbrown added >enhancement >breaking :Data Management/Indices APIs APIs to create and manage indices and templates v7.0.0 labels Oct 25, 2018
@gwbrown gwbrown requested a review from jasontedor October 25, 2018 23:07
@elasticmachine
Copy link
Collaborator

Pinging @elastic/es-core-infra

Copy link
Member

@jasontedor jasontedor left a comment

Choose a reason for hiding this comment

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

I am so sorry @gwbrown for the delay in reviewing. This is looking really great! I left a few incredibly minor nits. No need for another round.

Elasticsearch 7.0, as strict enforcement of the limit will be the default and
only behavior.
There is a soft limit on the number of shards in a cluster, based on the number
of nodes in the cluster. This is intended to prevent operations which may
Copy link
Member

Choose a reason for hiding this comment

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

Nit: a single space is fine; the CSS/HTML ensures consistent style anyway.


dataNodes = ensureMultipleDataNodes(dataNodes);

int firstShardCount = between(2,10);
Copy link
Member

Choose a reason for hiding this comment

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

Nit: space after the comma

int firstIndexShards = firstIndexFactor * dataNodes;
int firstIndexReplicas = 0;

int secondIndexFactor = between(1,3);
Copy link
Member

Choose a reason for hiding this comment

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

Nit: space after comma

@@ -29,7 +29,7 @@ private DeprecationChecks() {

static List<Function<ClusterState, DeprecationIssue>> CLUSTER_SETTINGS_CHECKS =
Collections.unmodifiableList(Arrays.asList(
Copy link
Member

Choose a reason for hiding this comment

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

Collections.emptyList is unmodifiable too?

@gwbrown
Copy link
Contributor Author

gwbrown commented Nov 26, 2018

Thanks for the review @jasontedor!

@gwbrown
Copy link
Contributor Author

gwbrown commented Nov 26, 2018

The failure does not reproduce locally and appears to be unrelated.

@elasticmachine run the gradle build tests 2 please

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants