-
Notifications
You must be signed in to change notification settings - Fork 115
Prevent GC of non-closed RTCDataChannels #2902
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
Test forthcoming in https://phabricator.services.mozilla.com/D190744. |
], | ||
"closing-procedure": [ | ||
{ | ||
"description": "Prevent GC of non-closed RTCDataChannels", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
non-closing/non-closed
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Given where we're removing the channel I'm not sure we're preventing GC of non-closing channels?
webrtc.html
Outdated
</li> | ||
<li> | ||
<p> | ||
Remove <var>channel</var> from <var>connection</var>.{{RTCPeerConnection/[[DataChannels]]}}. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It seems good to do it there so that calling close() will remove synchronously the dc from the set.
What about the case of a transport that gets errored?
Shouldn't we also do the same in https://w3c.github.io/webrtc-pc/#announcing-a-data-channel-as-closed?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hmm, that "procedure" is also an algorithm called from https://w3c.github.io/webrtc-pc/#data-transport-closing-procedure
There's also this note suggesting the closing procedure is called from somewhere other than close()
but it's not.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
My only nit here is that "Ordered set" sounds prescriptive of implementation while seeming to have no JS-visible effect. I like minimally-constraining descriptions.
Fixes #2624.
Preview | Diff