Class RSProcedureDispatcher.ExecuteProceduresRemoteCall
java.lang.Object
org.apache.hadoop.hbase.master.procedure.RSProcedureDispatcher.ExecuteProceduresRemoteCall
- All Implemented Interfaces:
Runnable
,RSProcedureDispatcher.RemoteProcedureResolver
- Direct Known Subclasses:
RSProcedureDispatcher.DeadRSRemoteCall
- Enclosing class:
- RSProcedureDispatcher
protected class RSProcedureDispatcher.ExecuteProceduresRemoteCall
extends Object
implements RSProcedureDispatcher.RemoteProcedureResolver, Runnable
-
Field Summary
Modifier and TypeFieldDescriptionprivate static final int
The default retry limit.private static final int
private final int
private long
private int
private final Set<RemoteProcedureDispatcher.RemoteProcedure>
private org.apache.hadoop.hbase.shaded.protobuf.generated.AdminProtos.ExecuteProceduresRequest.Builder
private static final String
Config to determine the retry limit while executing remote regionserver procedure.private static final String
private final long
private final ServerName
-
Constructor Summary
ConstructorDescriptionExecuteProceduresRemoteCall
(ServerName serverName, Set<RemoteProcedureDispatcher.RemoteProcedure> remoteProcedures) -
Method Summary
Modifier and TypeMethodDescriptionvoid
dispatchCloseRequests
(MasterProcedureEnv env, List<RSProcedureDispatcher.RegionCloseOperation> operations) void
dispatchOpenRequests
(MasterProcedureEnv env, List<RSProcedureDispatcher.RegionOpenOperation> operations) void
dispatchServerOperations
(MasterProcedureEnv env, List<RSProcedureDispatcher.ServerOperation> operations) private long
private AsyncRegionServerAdmin
protected final ServerName
private boolean
Returns true if the error or its cause is of type ConnectionClosedException.private boolean
Returns true if the error type can allow fail-fast.private boolean
protected final void
void
run()
private boolean
protected org.apache.hadoop.hbase.shaded.protobuf.generated.AdminProtos.ExecuteProceduresResponse
sendRequest
(ServerName serverName, org.apache.hadoop.hbase.shaded.protobuf.generated.AdminProtos.ExecuteProceduresRequest request) private boolean
The category of exceptions where we can ensure that the request has not yet been received and/or processed by the target regionserver yet and hence we can determine whether it is safe to choose different regionserver as the target.private IOException
-
Field Details
-
serverName
-
remoteProcedures
-
numberOfAttemptsSoFar
-
maxWaitTime
-
rsRpcRetryInterval
-
RS_RPC_RETRY_INTERVAL_CONF_KEY
- See Also:
-
DEFAULT_RS_RPC_RETRY_INTERVAL
- See Also:
-
RS_REMOTE_PROC_FAIL_FAST_LIMIT
Config to determine the retry limit while executing remote regionserver procedure. This retry limit applies to only specific errors. These errors could potentially get the remote procedure stuck for several minutes unless the retry limit is applied.- See Also:
-
DEFAULT_RS_REMOTE_PROC_RETRY_LIMIT
The default retry limit. Waiting for more than 5 attempts is not going to help much for genuine connectivity errors. Therefore, consider fail-fast after 5 retries. Value = 5- See Also:
-
failFastRetryLimit
-
request
private org.apache.hadoop.hbase.shaded.protobuf.generated.AdminProtos.ExecuteProceduresRequest.Builder request
-
-
Constructor Details
-
ExecuteProceduresRemoteCall
public ExecuteProceduresRemoteCall(ServerName serverName, Set<RemoteProcedureDispatcher.RemoteProcedure> remoteProcedures)
-
-
Method Details
-
getRsAdmin
- Throws:
IOException
-
getServerName
-
scheduleForRetry
-
unableToConnectToServer
The category of exceptions where we can ensure that the request has not yet been received and/or processed by the target regionserver yet and hence we can determine whether it is safe to choose different regionserver as the target.- Parameters:
e
- IOException thrown by the underlying rpc framework.- Returns:
- true if the exception belongs to the category where the regionserver has not yet received the request yet.
-
isSaslError
-
isConnectionClosedError
Returns true if the error or its cause is of type ConnectionClosedException.- Parameters:
e
- IOException thrown by the underlying rpc framework.- Returns:
- True if the error or its cause is of type ConnectionClosedException.
-
isErrorTypeFailFast
Returns true if the error type can allow fail-fast.- Parameters:
e
- IOException thrown by the underlying rpc framework.- Returns:
- True if the error type can allow fail-fast.
-
getMaxWaitTime
-
unwrapException
-
run
-
dispatchOpenRequests
public void dispatchOpenRequests(MasterProcedureEnv env, List<RSProcedureDispatcher.RegionOpenOperation> operations) - Specified by:
dispatchOpenRequests
in interfaceRSProcedureDispatcher.RemoteProcedureResolver
-
dispatchCloseRequests
public void dispatchCloseRequests(MasterProcedureEnv env, List<RSProcedureDispatcher.RegionCloseOperation> operations) - Specified by:
dispatchCloseRequests
in interfaceRSProcedureDispatcher.RemoteProcedureResolver
-
dispatchServerOperations
public void dispatchServerOperations(MasterProcedureEnv env, List<RSProcedureDispatcher.ServerOperation> operations) - Specified by:
dispatchServerOperations
in interfaceRSProcedureDispatcher.RemoteProcedureResolver
-
sendRequest
protected org.apache.hadoop.hbase.shaded.protobuf.generated.AdminProtos.ExecuteProceduresResponse sendRequest(ServerName serverName, org.apache.hadoop.hbase.shaded.protobuf.generated.AdminProtos.ExecuteProceduresRequest request) throws IOException - Throws:
IOException
-
remoteCallFailed
-