Skip to content

Exclude low level events from re-dispatch #64

@tegefaulkes

Description

@tegefaulkes

Specification

Events such as the EventQuicStreamSend and EventQuicConnectionSend and any other very low level events needs to be excluded from re-dispatch.

Currently events bubble upwards through re-dispatching at every level . A QUICStream event will be created in QUICStream and then cloned and dispatched in the QUICConnection, QuicClient, QuicServer, and in Polykey through the NodeConnection and NodeConnectionManager. As a result a QUICStream event can be cloned 4-ish times. This will be a severe performance hit for send events which are dispatched for every packet.

To solve this, we need to special case and exclude these events from re-dispatch inside the QUICConnection for the EventQuicStreamSend and inside the QUICSocket for the EventQUICConnectionSend event.

Additional context

Tasks

  1. Exclude all send events from being re-dispatched further than they're needed.
  2. Review and do the same for any event that happens often through normal usage. 'Once' events can be ignored here.

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions