@ThreadSafe public final class RetryHandlingJobMasterClient extends AbstractJobMasterClient implements JobMasterClient
AbstractClient.RpcCallable<V>
JobMasterClient.Factory
mConfAddress
mAlwaysEnableTLS, mChannel, mClosed, mConnected, mContext, mServerAddress, mServiceVersion, mVersionService
Constructor and Description |
---|
RetryHandlingJobMasterClient(JobMasterClientContext conf)
Creates a new job master client.
|
Modifier and Type | Method and Description |
---|---|
protected void |
afterConnect()
This method is called after the connection is made to the remote.
|
protected ServiceType |
getRemoteServiceType() |
protected String |
getServiceName() |
protected long |
getServiceVersion() |
List<JobCommand> |
heartbeat(JobWorkerHealth jobWorkerHealth,
List<JobInfo> taskInfoList)
Periodic heartbeats to update the tasks' status from a worker, and returns the commands.
|
long |
registerWorker(WorkerNetAddress address)
Returns a worker id for a workers net address.
|
getConfAddress
afterDisconnect, beforeConnect, queryGrpcServerAddress
beforeDisconnect, checkVersion, close, connect, connectWithRuntimeException, createChannel, disconnect, getRemoteHostName, getRemoteServiceVersion, getRemoteSockAddress, isClosed, isConnected, retryRPC, retryRPC
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
connect, disconnect, getConfAddress, getRemoteHostName, getRemoteSockAddress, isClosed, isConnected
public RetryHandlingJobMasterClient(JobMasterClientContext conf)
conf
- job master client configurationprotected ServiceType getRemoteServiceType()
getRemoteServiceType
in class AbstractClient
protected String getServiceName()
getServiceName
in class AbstractClient
protected long getServiceVersion()
getServiceVersion
in class AbstractClient
protected void afterConnect()
AbstractClient
afterConnect
in class AbstractClient
public long registerWorker(WorkerNetAddress address) throws IOException
JobMasterClient
registerWorker
in interface JobMasterClient
address
- the net address to get a worker id forIOException
- if an I/O error occurspublic List<JobCommand> heartbeat(JobWorkerHealth jobWorkerHealth, List<JobInfo> taskInfoList) throws IOException
JobMasterClient
heartbeat
in interface JobMasterClient
jobWorkerHealth
- the job worker infotaskInfoList
- the list of the task informationIOException
- if an I/O error occursCopyright © 2023. All Rights Reserved.