-
Notifications
You must be signed in to change notification settings - Fork 87
Description
The connection state machine tracks which streams have recently been reset in order to account for the timing window between the stream being reset locally and the remote receiving that reset stream frame. During that timing window the remote may send frames on the recently reset stream (because it doesn't yet know it's been reset). The local peer should ignore those frames.
At the moment the number of recently reset streams is limited to a hardcoded value of 32. This should be made configurable via the ConnectionConfiguration.
We likely need to exercise a little bit of caution here: the collection of recently reset streams is currently a circular buffer. Some operations do a linear scan to check for the presence of a stream which is fine for the fixed size of 32, but less so if the configured size was much larger.
This likely means we want a bimodal data structure where below a certain configured size it remains a circular buffer and beyond that size it's augmented with a set for fast lookups.