Re: [webrtc-pc] Should garbage collecting RTCDataChannels be observable? (#2624)

> For logical consistency, I think it's the SctpTransport that should have a strong reference to the data channels it carries, not the RTCPeerConnection. But the RTCPeerConnection should have a strong reference to the SctpTransport (assumption to be verified!), so the result is equivalent.

The problem there is that you don't have a `RTCSctpTransport` object before negotiation if I read the spec correctly. But you can create as many data channel objects before negotiation as you want. Because of this reason, the data channels should be owned by the `RTCPeerConnection` object.

I would advocate the data channels could have a reference to their `RTCSctpTransport` object, it'd make it easier for them to check the `max-message-size` during a `send()`.

GitHub Notification of comment by Orphis
Please view or discuss this issue at using your GitHub account

Sent via github-notify-ml as configured in

Received on Tuesday, 5 July 2022 09:34:25 UTC