-
Notifications
You must be signed in to change notification settings - Fork 115
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
Add RTCSctpTransportState #1620
Conversation
transport.</p> | ||
<div> | ||
<pre class="idl">enum RTCSctpTransportState { | ||
"new", |
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.
I'm not sure we need "new", since we decided the RTCSctpTransport is only created on applying an answer, in which case it already has enough information to connect? Though maybe we should revisit that decision.
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.
There might be an advantage to having the RTCSctpTransport
created earlier, in which case the "new" state might be used. But I agree that if it is only created on applying an Answer it should be initialized to "connecting".
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.
Opening another issue relating to the transition text.
webrtc.html
Outdated
"idlAttrType"><a>RTCSctpTransportState</a></span>, readonly</dt> | ||
<dd> | ||
<p>The current state of the SCTP transport. The attribute returns | ||
the value of the <dfn>[[\SctpTransportState]]</dfn> internal slot.</p> |
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.
Similar to my comment on the PR that added [[DtlsTransportState]]: we need to either describe when the slot's value is changed, or not use a slot.
In this case it's probably pretty simple:
- When it's first created, the value is
connecting
? (See below comment) - When the four-way startup handshake finishes, queue a task to update the state to
connected
- When a SHUTDOWN or ABORT chunk is received, queue a task to update the state to
closed
- Also can go to
closed
from applying a description that rejects the data m= section, or changes the sctp-port. Or if the application closes the PeerConnection,
Fix for Issue #1612
Preview | Diff