Re: Proposal for SctpTransport

On Mon, Nov 3, 2014 at 1:28 PM, Peter Thatcher <pthatcher@google.com> wrote:

> At TPAC (2014), we dicussed the possibility of an "SCTP doohickey".  This
> would be able to answer the following questions to the JS:
>
> - What is the max message size for the data channel?
> - Which DtlsTransport are the data channels going over?
> - Which IceTransport are the data channels going over?
>
> For that, I propose we add:
>
> interface RTCSctpTransport {
>     readonly attribute RTCDtlsTransport transport;
>     unsigned int maxMessageSize;
> };
>
> partial interface RTCDataChannel {
>     // null until negotiation of the transport is complete
>     readonly attributed RTCSctpTransport? transport;
> };
>
> Which can be used like this:
>
> // What is the max message size I can use?
> var dc = pc.createDataChannel();
> dc.transport.maxMessageSize;
>
> // What DTLS transport is my data going over?
> dc.transport.transport;  // dtls
>
> // What ICE transport is my data going over?
> pc.transport.transport.transport;  // ice
>

I think you mean dc.transport.transport.transport.

I happen to like the use of "transport" as a unprefixed name, since it
works even if years down the road, we decide to use a different protocol at
some layer in the stack.

>
>
> That last bit is slightly ugly, and if it mattered enough, we could make
> it something like:
> dc.transport.dtls;
> dc.transport.ice;
>
> But I don't think it's worth it to do so.
>
>
> Now, I do have a question to ask the group:  Should we also have
> RTCPeerConnection.getDataTransport()?  It seems like it would only be
> useful to have one if we can have a data transport without having a data
> channel, and that doesn't seem very useful to me.  Is there a worthwhile
> use case?
>
>
>

Received on Tuesday, 4 November 2014 00:44:44 UTC