Package io.aeron.driver
Class TaggedMulticastFlowControl
java.lang.Object
io.aeron.driver.AbstractMinMulticastFlowControl
io.aeron.driver.TaggedMulticastFlowControl
- All Implemented Interfaces:
FlowControl
,AutoCloseable
- Direct Known Subclasses:
PreferredMulticastFlowControl
Minimum multicast sender flow control strategy only for tagged members identified by a receiver tag or ASF key.
Flow control is set to minimum of tracked tagged receivers.
Tracking of tagged receivers is done as long as they continue to send Status Messages. Once SMs stop, the receiver tracking for that receiver will time out after a given number of nanoseconds.
-
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
-