-
Notifications
You must be signed in to change notification settings - Fork 1.9k
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
Add support of default replica count change #5610
Changes from 1 commit
65a1d52
f563943
ebe089a
58d9f7c
dba0e3e
5b7ec7a
d28ae15
2eac09c
bd851a3
472c9d6
7ebab23
63c39e5
bfc3915
0aa504f
045617b
b9c406e
40e8706
615e81c
099a7d1
3a1afc0
4fa42d8
231858d
80f8da0
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
Signed-off-by: Arpit Bandejiya <abandeji@amazon.com>
- Loading branch information
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -11,15 +11,18 @@ | |
import org.apache.logging.log4j.LogManager; | ||
import org.apache.logging.log4j.Logger; | ||
import org.opensearch.cluster.metadata.AutoExpandReplicas; | ||
import org.opensearch.cluster.metadata.MetadataCreateIndexService; | ||
import org.opensearch.common.settings.ClusterSettings; | ||
import org.opensearch.common.settings.Setting; | ||
import org.opensearch.common.settings.Settings; | ||
import org.opensearch.indices.replication.common.ReplicationType; | ||
|
||
import java.util.*; | ||
|
||
import static java.lang.Math.log; | ||
import java.util.Iterator; | ||
import java.util.List; | ||
import java.util.Map; | ||
import java.util.Optional; | ||
import java.util.Collections; | ||
import java.util.HashMap; | ||
|
||
import static java.lang.Math.max; | ||
import static org.opensearch.cluster.routing.allocation.decider.AwarenessAllocationDecider.CLUSTER_ROUTING_ALLOCATION_AWARENESS_ATTRIBUTE_SETTING; | ||
import static org.opensearch.cluster.routing.allocation.decider.AwarenessAllocationDecider.CLUSTER_ROUTING_ALLOCATION_AWARENESS_FORCE_GROUP_SETTING; | ||
|
@@ -35,7 +38,6 @@ | |
public class AwarenessReplicaBalance { | ||
public static final String SETTING_CLUSTER_ROUTING_ALLOCATION_AWARENESS_BALANCE = "cluster.routing.allocation.awareness.balance"; | ||
public static final String SETTING_USE_FORCE_ZONE_FOR_REPLICA = "cluster.use_force_zone_for_replica"; | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. rename to @Bukhtawar : your thoughts on this name ? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. maybe There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. How about |
||
private static final Logger logger = LogManager.getLogger(AwarenessReplicaBalance.class); | ||
public static final Setting<Boolean> CLUSTER_ROUTING_ALLOCATION_AWARENESS_BALANCE_SETTING = Setting.boolSetting( | ||
SETTING_CLUSTER_ROUTING_ALLOCATION_AWARENESS_BALANCE, | ||
false, | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nit: do we need this?