public class MQComputationManager extends Object implements ComputationManager
Constructor and Description |
---|
MQComputationManager(MQManager<Record> manager,
Topology topology,
Settings settings) |
Modifier and Type | Method and Description |
---|---|
boolean |
drainAndStop(Duration timeout)
Stop computations when input streams are empty.
|
long |
getLowWatermark() |
long |
getLowWatermark(String computationName) |
boolean |
isDone(long timestamp) |
void |
shutdown()
Shutdown immediately
|
void |
start()
Run the computations
|
boolean |
stop() |
boolean |
stop(Duration timeout)
Stop computations gracefully after processing a record or a timer.
|
boolean |
waitForAssignments(Duration timeout)
Wait for the computations to have assigned partitions ready to process records.
|
public MQComputationManager(MQManager<Record> manager, Topology topology, Settings settings)
public void start()
ComputationManager
start
in interface ComputationManager
public boolean waitForAssignments(Duration timeout) throws InterruptedException
ComputationManager
true
if all computations have assigned partitions during the timeout delay.waitForAssignments
in interface ComputationManager
InterruptedException
public boolean stop(Duration timeout)
ComputationManager
stop
in interface ComputationManager
public boolean stop()
stop
in interface ComputationManager
public boolean drainAndStop(Duration timeout)
ComputationManager
true
if computations are stopped during the timeout delay.drainAndStop
in interface ComputationManager
public void shutdown()
ComputationManager
shutdown
in interface ComputationManager
public long getLowWatermark()
getLowWatermark
in interface ComputationManager
public long getLowWatermark(String computationName)
getLowWatermark
in interface ComputationManager
public boolean isDone(long timestamp)
isDone
in interface ComputationManager
Copyright © 2017 Nuxeo. All rights reserved.