Package org.opensearch.client
Class TimedRequest
java.lang.Object
org.opensearch.client.TimedRequest
- All Implemented Interfaces:
Validatable
- Direct Known Subclasses:
CloseIndexRequest,CreateIndexRequest,DeleteAliasRequest,DeleteComponentTemplateRequest,DeleteComposableIndexTemplateRequest,DeleteSnapshotLifecyclePolicyRequest,ExecuteSnapshotLifecyclePolicyRequest,ExecuteSnapshotLifecycleRetentionRequest,GetIndexRequest,GetMappingsRequest,GetSnapshotLifecyclePolicyRequest,GetSnapshotLifecycleStatsRequest,PutComponentTemplateRequest,PutComposableIndexTemplateRequest,PutMappingRequest,PutSnapshotLifecyclePolicyRequest,ResizeRequest,RolloverRequest,SimulateIndexTemplateRequest,SnapshotLifecycleManagementStatusRequest,StartSLMRequest,StopSLMRequest
A base request for any requests that supply timeouts.
Please note, any requests that use a ackTimeout should set timeout as they
represent the same backing field on the server.
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final org.opensearch.common.unit.TimeValuestatic final org.opensearch.common.unit.TimeValuestatic final org.opensearch.common.unit.TimeValueDeprecated.Fields inherited from interface org.opensearch.client.Validatable
EMPTY -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionorg.opensearch.common.unit.TimeValueReturns the timeout for the request to be completed on the cluster-manager nodeorg.opensearch.common.unit.TimeValueDeprecated.As of 2.2, because supporting inclusive language, replaced byclusterManagerNodeTimeout()voidsetClusterManagerTimeout(org.opensearch.common.unit.TimeValue clusterManagerTimeout) Sets the timeout to connect to the cluster-manager nodevoidsetMasterTimeout(org.opensearch.common.unit.TimeValue clusterManagerTimeout) Deprecated.As of 2.2, because supporting inclusive language, replaced bysetClusterManagerTimeout(TimeValue)voidsetTimeout(org.opensearch.common.unit.TimeValue timeout) Sets the timeout to wait for the all the nodes to acknowledgeorg.opensearch.common.unit.TimeValuetimeout()Returns the request timeoutMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.opensearch.client.Validatable
validate
-
Field Details
-
DEFAULT_ACK_TIMEOUT
public static final org.opensearch.common.unit.TimeValue DEFAULT_ACK_TIMEOUT -
DEFAULT_CLUSTER_MANAGER_NODE_TIMEOUT
public static final org.opensearch.common.unit.TimeValue DEFAULT_CLUSTER_MANAGER_NODE_TIMEOUT -
DEFAULT_MASTER_NODE_TIMEOUT
Deprecated.As of 2.2, because supporting inclusive language, replaced byDEFAULT_CLUSTER_MANAGER_NODE_TIMEOUT
-
-
Constructor Details
-
TimedRequest
public TimedRequest()
-
-
Method Details
-
setTimeout
public void setTimeout(org.opensearch.common.unit.TimeValue timeout) Sets the timeout to wait for the all the nodes to acknowledge- Parameters:
timeout- timeout as aTimeValue
-
setClusterManagerTimeout
public void setClusterManagerTimeout(org.opensearch.common.unit.TimeValue clusterManagerTimeout) Sets the timeout to connect to the cluster-manager node- Parameters:
clusterManagerTimeout- timeout as aTimeValue
-
setMasterTimeout
@Deprecated public void setMasterTimeout(org.opensearch.common.unit.TimeValue clusterManagerTimeout) Deprecated.As of 2.2, because supporting inclusive language, replaced bysetClusterManagerTimeout(TimeValue)Sets the timeout to connect to the cluster-manager node- Parameters:
clusterManagerTimeout- timeout as aTimeValue
-
timeout
public org.opensearch.common.unit.TimeValue timeout()Returns the request timeout -
clusterManagerNodeTimeout
public org.opensearch.common.unit.TimeValue clusterManagerNodeTimeout()Returns the timeout for the request to be completed on the cluster-manager node -
masterNodeTimeout
Deprecated.As of 2.2, because supporting inclusive language, replaced byclusterManagerNodeTimeout()Returns the timeout for the request to be completed on the cluster-manager node
-
DEFAULT_CLUSTER_MANAGER_NODE_TIMEOUT