Package io.aeron.driver
Class MinMulticastFlowControl
java.lang.Object
io.aeron.driver.AbstractMinMulticastFlowControl
io.aeron.driver.MinMulticastFlowControl
- All Implemented Interfaces:
FlowControl
,AutoCloseable
Minimum multicast sender flow control strategy. Uses the
AbstractMinMulticastFlowControl
, but specifies that
the group membership for a given receiver is always true
, so it tracks the minimum for all receivers.-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final String
URI param value to identify thisFlowControl
strategy. -
Method Summary
Modifier and TypeMethodDescriptionvoid
onError
(ErrorFlyweight errorFlyweight, InetSocketAddress receiverAddress, long timeNs) Update the sender flow control strategy if an error comes from one of the receivers.long
onStatusMessage
(StatusMessageFlyweight flyweight, InetSocketAddress receiverAddress, long senderLimit, int initialTermId, int positionBitsToShift, long timeNs) Update the sender flow control strategy based on a status message from the receiver.void
onTriggerSendSetup
(StatusMessageFlyweight flyweight, InetSocketAddress receiverAddress, long timeNs) Update the sender flow control strategy based on a Status Message received triggering a setup to be sent.Methods inherited from class io.aeron.driver.AbstractMinMulticastFlowControl
close, groupMinSize, groupTag, hasGroupTag, hasRequiredReceivers, initialize, maxRetransmissionLength, onIdle, onSetup, processError, processSendSetupTrigger, processStatusMessage, receiverTimeoutNs
-
Field Details
-
FC_PARAM_VALUE
URI param value to identify thisFlowControl
strategy.- See Also:
-
-
Method Details
-
onStatusMessage
public long onStatusMessage(StatusMessageFlyweight flyweight, InetSocketAddress receiverAddress, long senderLimit, int initialTermId, int positionBitsToShift, long timeNs) Update the sender flow control strategy based on a status message from the receiver.- Parameters:
flyweight
- over the status message received.receiverAddress
- 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).- Returns:
- the new position limit to be employed by the sender.
-
onTriggerSendSetup
public void onTriggerSendSetup(StatusMessageFlyweight flyweight, InetSocketAddress receiverAddress, long timeNs) Update the sender flow control strategy based on a Status Message received triggering a setup to be sent.- Parameters:
flyweight
- over the Status Message receivedreceiverAddress
- of the receiver.timeNs
- current time (in nanoseconds).
-
onError
Update the sender flow control strategy if an error comes from one of the receivers.- Parameters:
errorFlyweight
- over the error received.receiverAddress
- the address of the receiver.timeNs
- current time in nanoseconds
-