Skip to content
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

Undefined RTCPeerConnectionState states #2446

Closed
henbos opened this issue Jan 22, 2020 · 4 comments
Closed

Undefined RTCPeerConnectionState states #2446

henbos opened this issue Jan 22, 2020 · 4 comments
Assignees

Comments

@henbos
Copy link
Contributor

henbos commented Jan 22, 2020

There are combinations of transport states that don't apply to any of the states in the table. For example, if all transports are "connecting" except one that is "closed", there is no corresponding RTCPeerConnectionState (because for PC/"connecting" none of the transports can be "closed" and for PC/"closed" the PC has to be closed - what if one of the transports closed due to close() or due to a close_notify alert?).

@alvestrand
Copy link
Contributor

alvestrand commented Jan 30, 2020

when the remote party sends a DTLS close (which happens when the remote party calls pc.close()), the DTLSTransport will go to "closed". I think that's the only way for a DTLSTransport to get to closed state. It's a final state for the DTLSTransport.

@henbos
Copy link
Contributor Author

henbos commented Jan 30, 2020

"closed" refers to [[IsClosed]], I think reusing that to mean "the other guy told us they closed" would be a breaking change.

So "failed" or "disconnected" makes more sense.
I propose to make a PR that makes DTLS "closed" cause PC "disconnected" since it's not a failure code it's a close code.

@henbos henbos self-assigned this Jan 30, 2020
@henbos
Copy link
Contributor Author

henbos commented Jan 30, 2020

Might also want to see what existing implementations do...

@henbos
Copy link
Contributor Author

henbos commented Apr 23, 2020

Merging this into #2499

@henbos henbos closed this as completed Apr 23, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants