Re: [rtcweb] #13: Transport of DATA_CHANNEL_OPEN

Cullen Jennings <fluffy@iii.ca> Fri, 26 April 2013 17:57 UTC

Return-Path: <fluffy@iii.ca>
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 AE1E421F99D3 for <rtcweb@ietfa.amsl.com>; Fri, 26 Apr 2013 10:57:42 -0700 (PDT)
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 ([12.22.58.30]) by localhost (ietfa.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 69vW6UKx5D-S for <rtcweb@ietfa.amsl.com>; Fri, 26 Apr 2013 10:57:41 -0700 (PDT)
Received: from mxout-07.mxes.net (mxout-07.mxes.net [216.86.168.182]) by ietfa.amsl.com (Postfix) with ESMTP id 9FCAD21F99CA for <rtcweb@ietf.org>; Fri, 26 Apr 2013 10:57:41 -0700 (PDT)
Received: from [192.168.4.100] (unknown [128.107.239.233]) (using TLSv1 with cipher AES128-SHA (128/128 bits)) (No client certificate requested) by smtp.mxes.net (Postfix) with ESMTPSA id D92D722E259; Fri, 26 Apr 2013 13:57:34 -0400 (EDT)
Content-Type: text/plain; charset="windows-1252"
Mime-Version: 1.0 (Mac OS X Mail 6.3 \(1503\))
From: Cullen Jennings <fluffy@iii.ca>
In-Reply-To: <5179A362.2000309@jesup.org>
Date: Fri, 26 Apr 2013 11:57:33 -0600
Content-Transfer-Encoding: quoted-printable
Message-Id: <E2ADFEA8-5900-4098-9857-031E6FFBF1B9@iii.ca>
References: <066.3120a55540cacaa74ee5fda0b5273a48@trac.tools.ietf.org> <5174C8D2.40504@matthew.at> <5177F7EE.1010909@matthew.at> <CAJrXDUGa1=Nqq9WPL57=OkUU9mG7yHz0uzG1KncS8yVzbSAM0A@mail.gmail.com> <AE1A6B5FD507DC4FB3C5166F3A05A484162816C1@tk5ex14mbxc272.redmond.corp.microsoft.com> <C5E08FE080ACFD4DAE31E4BDBF944EB11349F9B5@xmb-aln-x02.cisco.com> <5179A362.2000309@jesup.org>
To: Randell Jesup <randell-ietf@jesup.org>
X-Mailer: Apple Mail (2.1503)
Cc: rtcweb@ietf.org
Subject: Re: [rtcweb] #13: Transport of DATA_CHANNEL_OPEN
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: Fri, 26 Apr 2013 17:57:42 -0000

Thank you summarizing all this. 

On Apr 25, 2013, at 3:42 PM, Randell Jesup <randell-ietf@jesup.org> wrote:

> On 4/25/2013 5:10 PM, Cullen Jennings (fluffy) wrote:
>> So with my co-chair hat on hereā€¦
>> 
>> It seems we have been around the need for OPEN several times and have come to consensus on it in the past. Can someone please:
>> 
>> 1) summarize the arguments that in the past that lead us to think we need OPEN
> 
> The Open message has some important and useful properties:
> 
> 1) It's easier to work with.  JS isn't an ideal language for writing network protocols, especially for non-network-programmers (i.e. a large portion of the expected developer community).  Open makes it really easy for a developer to get the type of bidirectional stream them want with little fuss, and in a manner that maps easily to APIs they're already used to (e.g. WebSockets).  In many cases the label field will avoid the JS programmer having to build their own mini-protocol to identify their channels (and this is especially painful for them if it's an unreliable channel).
> 
> 2) It makes it possible to have different applications exchange data, by having an IANA-registered protocol name, like WebSockets (and there was strong agreement on it's being needed for that at Atlanta.)  With external-negotiation-only, it would be very hard for different apps to interoperate, since they'd need to agree on negotiation protocols as well, which are likely to be highly divergent between apps.
> 
> 3) The Open message, being in-channel, reliable and in-order, makes the issue that was the genesis of this thread (what to do with data that arrives unexpectedly) simpler.  With Open, only degenerate cases can cause more than a relatively small amount of data to be buffered.  With external notification, the external negotiation channel can fail (or be very slow), or the app can have a bug and fail to install the negotiated values, leading to larger or unbounded buffering requirements - or you punt the problem to the application by delivering the data, but the application is facing the same conundrum of buffer it or throw it away.
> 
>> 2) sketch out the range of possible solutions to deal with unexpected data before the OPEN
> 
> 
> The issue exists regardless of whether Open is used or external negotiation (and in fact is much simpler for Open).
> 
> *tl;dr: *I'm ok with any setting of maximum sizes and/or times that would not adversely impact temporary buffering for normal cases with Open of unordered channels.  This is option C below.  I also would be ok with B, but I realize others may not be.
> 
> Regardless of supporting Open or not, any external negotiation of dynamic channels must use one of these:
> 
> A) a 2-or-3-way handshake so the sender knows the receiver is ready to receive the data on the specified channel before sending it, or
> 
> B) unbounded buffering of data if the external negotiation messages are delayed (again, what we're discussing in this thread), or
> 
> C) bounded buffering of data (bounded by time, size or both), with data being dropped and the channel closed if the limits are exceeded, or
> 
> D) deliver unexpected data to the application, which will do .... I don't know what with it.
> 
> For (D), the application will likely drop it on the floor (leading to hard-to-test-for problems if the channel is later configured by Open or external negotiation), or buffer it waiting for the channel to open.
> 
> Supporting Open or not has little bearing on these scenarios -- and in fact, since Open is in-channel, reliable, and ordered, it reduces the problem set (when Open is used) to only unordered channels (in ordered channels Open will always be first).
> 
> Buffering unexpected data on channels (options B or C) is useful. It means that in the external negotiation case, one side asking for a new channel to open by some private means doesn't need to wait to start sending data on that channel.  Note that with external negotiation (possibly on a non p2p path, like via signaling), the receiver might not know what to install for a short while, especially if there's a routing issue or server issue (not a problem that happens with Open).
> 
> Since normal Open cases have very little chance of triggering this problem (triggering buffering), some arbitrary size limit seems reasonable (option C).  Often in network protocols there are small buffers (4, 16, 64KB).  I prefer a larger value of say 256KB so that apps using external negotiation can just send largish data immediately - and note: actually buffering data is still an unlikely occurrence even in most external negotiation cases.  If people want to bikeshed on the buffersize or timeout, that's fine. ;-)
> 
> Also, external negotiation is the only case where more than a trivial amount of data can "pile up" in the buffer waiting for the receiving side to finish it's side of the negotiation (i.e. if your external negotiation channel fails or the app has a brain fart).
> 
> 
> -- 
> Randell Jesup
> randell-ietf@jesup.org
> 
> _______________________________________________
> rtcweb mailing list
> rtcweb@ietf.org
> https://www.ietf.org/mailman/listinfo/rtcweb