when setting timeout on cluster health, automatically set the master node timeout as well if it was not explicitly set
This commit is contained in:
parent
d3b2a2cf66
commit
759d948335
|
@ -70,6 +70,9 @@ public class ClusterHealthRequest extends MasterNodeOperationRequest {
|
|||
|
||||
public ClusterHealthRequest timeout(TimeValue timeout) {
|
||||
this.timeout = timeout;
|
||||
if (masterNodeTimeout == DEFAULT_MASTER_NODE_TIMEOUT) {
|
||||
masterNodeTimeout = timeout;
|
||||
}
|
||||
return this;
|
||||
}
|
||||
|
||||
|
|
|
@ -33,7 +33,7 @@ public abstract class MasterNodeOperationRequest implements ActionRequest {
|
|||
|
||||
public static TimeValue DEFAULT_MASTER_NODE_TIMEOUT = TimeValue.timeValueSeconds(30);
|
||||
|
||||
private TimeValue masterNodeTimeout = DEFAULT_MASTER_NODE_TIMEOUT;
|
||||
protected TimeValue masterNodeTimeout = DEFAULT_MASTER_NODE_TIMEOUT;
|
||||
|
||||
@Override
|
||||
public boolean listenerThreaded() {
|
||||
|
|
Loading…
Reference in New Issue