public interface FlowControl
Sender.| Modifier and Type | Method and Description |
|---|---|
void |
initialize(int initialTermId,
int termBufferLength)
Initialize the flow control strategy
|
long |
onIdle(long timeNs,
long senderLimit,
long senderPosition,
boolean isEos)
Perform any maintenance needed by the flow control strategy and return current position
|
long |
onStatusMessage(StatusMessageFlyweight flyweight,
java.net.InetSocketAddress receiverAddress,
long senderLimit,
int initialTermId,
int positionBitsToShift,
long timeNs)
Update the sender flow control strategy based on a status message from the receiver.
|
boolean |
shouldLinger(long timeNs)
Called from the
DriverConductor to check should the NetworkPublication linger or not. |
long onStatusMessage(StatusMessageFlyweight flyweight, java.net.InetSocketAddress receiverAddress, long senderLimit, int initialTermId, int positionBitsToShift, long timeNs)
flyweight - the Status Message contentsreceiverAddress - of the receiver.senderLimit - the current sender position limit.initialTermId - for the term buffers.positionBitsToShift - in use for the length of each term buffer.timeNs - current time (in nanoseconds). System.nanoTime()void initialize(int initialTermId,
int termBufferLength)
initialTermId - for the term bufferstermBufferLength - to use as the length of each term bufferlong onIdle(long timeNs,
long senderLimit,
long senderPosition,
boolean isEos)
timeNs - current time in nanoseconds.senderLimit - for the current sender position.senderPosition - for the currentisEos - is this end-of-stream for the sender.boolean shouldLinger(long timeNs)
DriverConductor to check should the NetworkPublication linger or not.timeNs - current time in nanoseconds.Copyright © 2014-2018 Real Logic Ltd. All Rights Reserved.