@NotThreadSafe public final class BlockMasterSync extends Object implements HeartbeatExecutor
BlockMasterClient
.
When running, this task first requests a block report from the
BlockWorker
, then sends it to the master. The master may
respond to the heartbeat with a command which will be executed. After which, the task will wait
for the elapsed time since its last heartbeat has reached the heartbeat interval. Then the cycle
will continue.
If the task fails to heartbeat to the master, it will destroy its old master client and recreate
it before retrying.Modifier and Type | Method and Description |
---|---|
void |
close()
Cleans up any resources used by the heartbeat executor.
|
void |
heartbeat()
Heartbeats to the master node about the change in the worker's managed space.
|
public void heartbeat()
heartbeat
in interface HeartbeatExecutor
public void close()
HeartbeatExecutor
close
in interface HeartbeatExecutor
close
in interface Closeable
close
in interface AutoCloseable
Copyright © 2023. All Rights Reserved.