Support Draining promise for WebTransport
Categories
(Core :: Networking, enhancement, P2)
Tracking
()
| Tracking | Status | |
|---|---|---|
| firefox155 | --- | fixed |
People
(Reporter: jesup, Assigned: jesup, NeedInfo)
References
(Depends on 1 open bug, Blocks 1 open bug)
Details
(Whiteboard: [necko-triaged], [wptsync upstream])
Attachments
(4 files, 1 obsolete file)
Support the new Draining promise in the spec.
3.1:
A WebTransport session session is draining when the CONNECT stream is asked to gracefully close by the server, as described in [WEB-TRANSPORT-OVERVIEW] Section 4.1.
One part is handling lifetimes:
6.8. Garbage Collection
A WebTransport object whose [[State]] is "connecting" must not be garbage collected if [[IncomingBidirectionalStreams]], [[IncomingUnidirectionalStreams]], any WebTransportReceiveStream, or [[Datagrams]].[[Readable]] are locked, or if the ready, draining, or closed promise is being observed.
A WebTransport object whose [[State]] is "connected" must not be garbage collected if [[IncomingBidirectionalStreams]], [[IncomingUnidirectionalStreams]], any WebTransportReceiveStream, or [[Datagrams]].[[Readable]] are locked, or if the draining or closed promise is being observed.
A WebTransport object whose [[State]] is "draining" must not be garbage collected if [[IncomingBidirectionalStreams]], [[IncomingUnidirectionalStreams]], any WebTransportReceiveStream, or [[Datagrams]].[[Readable]] are locked, or if the closed promise is being observed.
| Assignee | ||
Comment 1•7 months ago
|
||
Updated•7 months ago
|
| Assignee | ||
Comment 2•6 months ago
|
||
Updated•6 months ago
|
| Assignee | ||
Comment 3•6 months ago
|
||
Updated•5 months ago
|
| Assignee | ||
Comment 4•5 months ago
|
||
Updated•5 months ago
|
Comment 5•5 months ago
|
||
Comment on attachment 9539722 [details]
Bug 2007160: Update WebTransport getStats tests to include all fields r=jib!
Revision D280255 was moved to bug 2007202. Setting attachment 9539722 [details] to obsolete.
Backed out for causing build bustages
Backout link
Push with failures
Failure log(s)
Created web-platform-tests PR https://github.com/web-platform-tests/wpt/pull/61596 for changes under testing/web-platform/tests
Upstream PR merged by moz-wptsync-bot
Comment 10•14 days ago
|
||
Comment 11•14 days ago
|
||
| bugherder | ||
https://hg.mozilla.org/mozilla-central/rev/1673048dc8a8
https://hg.mozilla.org/mozilla-central/rev/84a190af0b88
https://hg.mozilla.org/mozilla-central/rev/44bc740ec952
| Assignee | ||
Comment 12•14 days ago
|
||
WebTransportSessionProxy::OnDraining() consulted mTarget directly, unlike
its siblings (OnSessionClosed, OnAtomicWriteResult, OnDatagramReceivedInternal,
OnMaxDatagramSizeInternal), which all check mStopRequestCalled first. Since
the listener's OnSessionReady runs on the main thread and retargets mTarget
to the socket thread from there, a Draining event that arrives before that
retargeting completes sees the stale main-thread default and misdelivers
the listener call to the main thread instead of the socket thread. For
WebTransportParent, whose methods assert socket-thread affinity, this sends
the PWebTransport IPC message off its bound thread and crashes - observable
whenever a server drains a session immediately upon connecting. Queue the
event like the other listener callbacks do until OnStopRequest has run.
Comment 13•13 days ago
|
||
A patch has been attached on this bug, which was already closed. Filing a separate bug will ensure better tracking. If this was not by mistake and further action is needed, please alert the appropriate party. (Or: if the patch doesn't change behavior -- e.g. landing a test case, or fixing a typo -- then feel free to disregard this message)
Description
•