aeron icon indicating copy to clipboard operation
aeron copied to clipboard

Reduce unicast publication linger when SM indicates it is safe to do so

Open mjpt777 opened this issue 4 years ago • 0 comments

UDP publications are lingered so tail loss can be detected and recovered. The majority of time loss will not occur and thus the resources tied up with a publication stay around longer than necessary. This is can impact short lived connections. This is a similar issue to what TCP faces with TIMED_WAIT.

A optimisation for this is to cut short the linger period once a status message has been received indicating a new window is available from the end-of-stream position. This state can be flagged and then used in the onTimedEvent to shorten the linger period and reclaim the resources.

The default linger period is 5 seconds which may need to be increased on high latency networks where this optimisation would be even more effective.

This optimisation would not be applicable to multicast or multi-destination-cast.

mjpt777 avatar Jul 11 '20 11:07 mjpt777