Re: [rtcweb] Data Channel Negotiation

Michael Tuexen <Michael.Tuexen@lurchi.franken.de> Mon, 11 February 2013 20:14 UTC

Return-Path: <Michael.Tuexen@lurchi.franken.de>
X-Original-To: rtcweb@ietfa.amsl.com
Delivered-To: rtcweb@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id E2E4A21F8837 for <rtcweb@ietfa.amsl.com>; Mon, 11 Feb 2013 12:14:56 -0800 (PST)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -2.599
X-Spam-Level:
X-Spam-Status: No, score=-2.599 tagged_above=-999 required=5 tests=[BAYES_00=-2.599]
Received: from mail.ietf.org ([64.170.98.30]) by localhost (ietfa.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id U75DhB31iGgm for <rtcweb@ietfa.amsl.com>; Mon, 11 Feb 2013 12:14:56 -0800 (PST)
Received: from mail-n.franken.de (drew.ipv6.franken.de [IPv6:2001:638:a02:a001:20e:cff:fe4a:feaa]) by ietfa.amsl.com (Postfix) with ESMTP id 9040921F879B for <rtcweb@ietf.org>; Mon, 11 Feb 2013 12:14:55 -0800 (PST)
Received: from [192.168.1.101] (p508FA903.dip.t-dialin.net [80.143.169.3]) (Authenticated sender: macmic) by mail-n.franken.de (Postfix) with ESMTP id 7A4BC1C0C069D; Mon, 11 Feb 2013 21:14:54 +0100 (CET)
Mime-Version: 1.0 (Apple Message framework v1283)
Content-Type: text/plain; charset="us-ascii"
From: Michael Tuexen <Michael.Tuexen@lurchi.franken.de>
In-Reply-To: <CABkgnnWWF5LCm7YqfUT9LY4mkHS5E5n2miihA_ymStcOBcbgrw@mail.gmail.com>
Date: Mon, 11 Feb 2013 21:14:53 +0100
Content-Transfer-Encoding: 7bit
Message-Id: <F472FE00-D8F8-4D28-BC9F-201E6DE1E2C0@lurchi.franken.de>
References: <CABkgnnWUpMSBLioSD2+p82vGszX9R0Q4WFfME5j-DuK+B7KVJw@mail.gmail.com> <C6503CC4-34D6-408A-8EFC-037F1668DDD0@lurchi.franken.de> <CABkgnnWWF5LCm7YqfUT9LY4mkHS5E5n2miihA_ymStcOBcbgrw@mail.gmail.com>
To: Martin Thomson <martin.thomson@gmail.com>
X-Mailer: Apple Mail (2.1283)
Cc: Randell Jesup <randell-ietf@jesup.org>, "rtcweb@ietf.org" <rtcweb@ietf.org>
Subject: Re: [rtcweb] Data Channel Negotiation
X-BeenThere: rtcweb@ietf.org
X-Mailman-Version: 2.1.12
Precedence: list
List-Id: Real-Time Communication in WEB-browsers working group list <rtcweb.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/rtcweb>, <mailto:rtcweb-request@ietf.org?subject=unsubscribe>
List-Archive: <http://www.ietf.org/mail-archive/web/rtcweb>
List-Post: <mailto:rtcweb@ietf.org>
List-Help: <mailto:rtcweb-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/rtcweb>, <mailto:rtcweb-request@ietf.org?subject=subscribe>
X-List-Received-Date: Mon, 11 Feb 2013 20:14:57 -0000

On Feb 11, 2013, at 8:40 PM, Martin Thomson wrote:

> On 8 February 2013 09:43, Michael Tuexen
> <Michael.Tuexen@lurchi.franken.de> wrote:
>>> Creating a new data channel triggers the onnegotiationneeded event.
>> The signaling channel might have a different RTT than the peer to peer
>> connections. So you prefer to do take always the signaling channel.
> 
> But since you have a short path for this, you can take that path.
> Some people may prefer to take the slower signaling path for this, but
> those that care about speed will use the data channel to do channel
> establishment (and they will probably do what I suggest below).
> 
>> Taking down a data channel is not signaled via SDP, right?
> 
> I believe that you are able to use in-band mechanisms (6525) for take-down.
Sure. The goal of my questions is to understand your proposal better...
> 
>> How do you handle a shortage in the number of streams? How do you
>> handle collisions if both sides want to open a data channel and
>> chose the same streams?
> 
> A shortage is easy, createDataChannel can throw an exception.
> 
> Collisions are also easy - if you care about consistency, then do an
> offer/answer, which has inbuilt glare resolution.  If you don't care
> about consistency, both sides can create and use channels without
> having to agree on the details.  (That's mostly based on the stuff
> below.
However, *if* data channels are bidirectional (which they currently are),
then you need to tie two streams together. This has to be done somehow.
I'm wondering how you envision this without using SDP and without the
data channel protocol...
> 
>> There is also a limitation of lifetime in milli seconds.
> 
> Sure, let's have that too.  All this is per-message, so consistency
> isn't really a required property.
OK.
> 
>> So basically a data channel is not symmetric anymore. Do you consider
>> it bidirectional or unidirectional?
> 
> Yes.  Depending on the needs of your application.  Inherently, they
> are unidirectional.  But if you care about the bidirectional property,
> then you are free to perform a signaling negotiation to ensure
> consistency (which is the only property that was provided by the
> negotiation as designed previously).
If we change to data channels being uni-directional, then most of
the stuff done by the data channel protocol is not required... I agree
with that conclusion.
However, currently that the bi-directional.
> 
>>> Firstly, the arrival of a packet on a stream that is not negotiated
>>> will require the creation of a data channel.  The properties of this
>> If you consider a data channel to be bidirectional, what makes sure
>> that a stream for the backwards direction is available? How do you
>> now the pairing?
> 
> There is no guarantee.  Two reasons for this, neither of which I find
> particularly dire:
> 
> a. I don't recall there being any signalling of the stream limit, so
> there is a possibility that the stream limit in one direction will
> exceed the limit in the other.  Streams with numbers that exceed the
> lower limit will of course be unable to be reciprocal.  Two solutions
> occur to me: 1. prevent the sending of return messages, or 2. cap the
Instead of "prevent sending the return message" which would one side
waiting forever, I would prefer sending some sort of error message
(which is currently not specified enough in the data channel protocol).
> number of channels to the lower of the two stream limits.  I prefer
> the latter.
As long as you know this limit... But RFC 6525 allows you to increase the
number of streams (unless the peer agrees to do so). 
> 
> b. There is no guarantee that the other side hasn't already created a
> data channel on the same number.  That's not a problem - you just end
> up with asymmetry.
This is a normal case with the current data channel protocol. The
stream identifiers might not be the same in both directions.
When testing with the current implementation in Firefox, this actually
happens a lot.
> 
> Note: deferring the allocation of a stream number until messages are
> sent on streams does allow the browser implementation some flexibility
> in how it manages assignment of streams.
> 
>> Not sure why you refer to RFC 4920... RFC 4960 (SCTP) doesn't have such
>> a limit.
> Crossed wires :)
... that was my guess.
>