public class LatencyMonitorComputation extends LatencyTrackerComputation
| Modifier and Type | Field and Description |
|---|---|
protected String |
basePrefix |
protected com.codahale.metrics.graphite.GraphiteSender |
graphite |
protected String |
host |
protected int |
port |
protected boolean |
udp |
codec, count, intervalMs, logGroups, logNames, manager, OUTPUT_STREAM, remaining, verbose| Constructor and Description |
|---|
LatencyMonitorComputation(LogManager manager,
List<String> logNames,
String host,
int port,
boolean udp,
String basePrefix,
String computationName,
int intervalSecond,
int count,
boolean verbose,
Codec<Record> codec) |
| Modifier and Type | Method and Description |
|---|---|
void |
destroy()
Called when the framework is ready to shutdown the computation.
|
void |
init(ComputationContext context)
Called when the framework has registered the computation successfully.
|
void |
processTimer(ComputationContext context,
String key,
long timestamp)
Process a timer callback previously set via
ComputationContext.setTimer(String, long). |
debug, decodeKey, encodeKey, encodeLatency, error, getLatenciesForPartition, info, processRecordmetadata, processFailure, processRetryclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitsignalStopprotected final int port
protected final boolean udp
protected final String basePrefix
protected com.codahale.metrics.graphite.GraphiteSender graphite
public LatencyMonitorComputation(LogManager manager, List<String> logNames, String host, int port, boolean udp, String basePrefix, String computationName, int intervalSecond, int count, boolean verbose, Codec<Record> codec)
public void init(ComputationContext context)
Computationinit in interface Computationinit in class LatencyTrackerComputationcontext - The computation context object provided by the system.public void processTimer(ComputationContext context, String key, long timestamp)
ComputationComputationContext.setTimer(String, long).processTimer in interface ComputationprocessTimer in class LatencyTrackerComputationcontext - The computation context object provided by the system.key - The name of the timer.timestamp - The timestamp (in ms) for which the callback was scheduled.public void destroy()
Computationdestroy in interface Computationdestroy in class LatencyTrackerComputationCopyright © 2018 Nuxeo. All rights reserved.