Change deprecation message for API parameter value 'master_node' of parameter 'metric' (#2880)

Signed-off-by: Tianli Feng <ftianli@amazon.com>
This commit is contained in:
Tianli Feng 2022-04-12 14:58:19 -07:00 committed by GitHub
parent a89b7e6216
commit 455fad34ee
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 3 additions and 3 deletions

View File

@ -169,7 +169,7 @@ setup:
cluster.state: cluster.state:
metric: [ master_node, version ] metric: [ master_node, version ]
allowed_warnings: allowed_warnings:
- 'Parameter [master_timeout] is deprecated and will be removed in 3.0. To support inclusive language, please use [cluster_manager_timeout] instead.' - 'Assigning [master_node] to parameter [metric] is deprecated and will be removed in 3.0. To support inclusive language, please use [cluster_manager_node] instead.'
- match: { cluster_uuid: $cluster_uuid } - match: { cluster_uuid: $cluster_uuid }
- is_true: master_node - is_true: master_node

View File

@ -83,7 +83,7 @@ public class RestClusterRerouteAction extends BaseRestHandler {
// It's used to log deprecation when request parameter 'metric' contains 'master_node', or request parameter 'master_timeout' is used. // It's used to log deprecation when request parameter 'metric' contains 'master_node', or request parameter 'master_timeout' is used.
private static final DeprecationLogger deprecationLogger = DeprecationLogger.getLogger(RestClusterRerouteAction.class); private static final DeprecationLogger deprecationLogger = DeprecationLogger.getLogger(RestClusterRerouteAction.class);
private static final String DEPRECATED_MESSAGE_MASTER_NODE = private static final String DEPRECATED_MESSAGE_MASTER_NODE =
"Deprecated value [master_node] used for parameter [metric]. To promote inclusive language, please use [cluster_manager_node] instead. It will be unsupported in a future major version."; "Assigning [master_node] to parameter [metric] is deprecated and will be removed in 3.0. To support inclusive language, please use [cluster_manager_node] instead.";
@Override @Override
public List<Route> routes() { public List<Route> routes() {

View File

@ -76,7 +76,7 @@ public class RestClusterStateAction extends BaseRestHandler {
// It's used to log deprecation when request parameter 'metric' contains 'master_node', or request parameter 'master_timeout' is used. // It's used to log deprecation when request parameter 'metric' contains 'master_node', or request parameter 'master_timeout' is used.
private static final DeprecationLogger deprecationLogger = DeprecationLogger.getLogger(RestClusterStateAction.class); private static final DeprecationLogger deprecationLogger = DeprecationLogger.getLogger(RestClusterStateAction.class);
private static final String DEPRECATED_MESSAGE_MASTER_NODE = private static final String DEPRECATED_MESSAGE_MASTER_NODE =
"Deprecated value [master_node] used for parameter [metric]. To promote inclusive language, please use [cluster_manager_node] instead. It will be unsupported in a future major version."; "Assigning [master_node] to parameter [metric] is deprecated and will be removed in 3.0. To support inclusive language, please use [cluster_manager_node] instead.";
@Override @Override
public String getName() { public String getName() {