public class DefaultMetricsMaster extends AbstractMaster implements MetricsMaster
mBackupManager, mClock, mPauseStateLock, mSafeModeManager, mStateChangeLock
Modifier and Type | Method and Description |
---|---|
protected void |
addAggregator(MultiValueMetricsAggregator aggregator) |
protected void |
addAggregator(SingleValueAggregator aggregator) |
void |
clientHeartbeat(String clientId,
String hostname,
List<Metric> metrics)
Handles the client's heartbeat request for metrics collection.
|
Iterator<Journal.JournalEntry> |
getJournalEntryIterator() |
MetricsMasterClientServiceHandler |
getMasterServiceHandler() |
String |
getName() |
Map<String,org.apache.thrift.TProcessor> |
getServices() |
void |
processJournalEntry(Journal.JournalEntry entry)
Applies a journal entry to the state machine.
|
void |
resetState()
Resets the journaled internal state of the state machine.
|
void |
start(Boolean isLeader)
Starts the Alluxio server.
|
void |
workerHeartbeat(String hostname,
List<Metric> metrics)
Handles the worker heartbeat and puts the metrics from an instance with a hostname.
|
createJournalContext, getDependencies, getExecutorService, stop
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
createJournalContext
getDependencies, stop
protected void addAggregator(SingleValueAggregator aggregator)
protected void addAggregator(MultiValueMetricsAggregator aggregator)
public String getName()
getName
in interface JournalEntryStateMachine
getName
in interface Server<Boolean>
public void processJournalEntry(Journal.JournalEntry entry) throws IOException
JournalEntryStateMachine
processJournalEntry
in interface JournalEntryStateMachine
entry
- the entry to process to update the state of the state machineIOException
public void resetState()
JournalEntryStateMachine
resetState
in interface JournalEntryStateMachine
public Iterator<Journal.JournalEntry> getJournalEntryIterator()
getJournalEntryIterator
in interface JournalEntryIterable
Iterator
that iterates all the journal entriespublic Map<String,org.apache.thrift.TProcessor> getServices()
getServices
in interface Server<Boolean>
TProcessor
s that serve RPCs for this serverpublic void start(Boolean isLeader) throws IOException
Server
start
in interface Server<Boolean>
start
in class AbstractMaster
isLeader
- the start optionsIOException
public void clientHeartbeat(String clientId, String hostname, List<Metric> metrics)
MetricsMaster
clientHeartbeat
in interface MetricsMaster
clientId
- the client idhostname
- the client hostnamemetrics
- client-side metricspublic MetricsMasterClientServiceHandler getMasterServiceHandler()
getMasterServiceHandler
in interface MetricsMaster
public void workerHeartbeat(String hostname, List<Metric> metrics)
MetricsMaster
workerHeartbeat
in interface MetricsMaster
hostname
- the hostname of the instancemetrics
- the new worker metricsCopyright © 2023. All Rights Reserved.