Re: [rtcweb] Open data channel issues

"Makaraju, Maridi Raju (Raju)" <Raju.Makaraju@alcatel-lucent.com> Mon, 03 March 2014 22:19 UTC

Return-Path: <Raju.Makaraju@alcatel-lucent.com>
X-Original-To: rtcweb@ietfa.amsl.com
Delivered-To: rtcweb@ietfa.amsl.com
Received: from localhost (ietfa.amsl.com [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id E91EB1A00C9 for <rtcweb@ietfa.amsl.com>; Mon, 3 Mar 2014 14:19:33 -0800 (PST)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -6.899
X-Spam-Level:
X-Spam-Status: No, score=-6.899 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, HTML_MESSAGE=0.001, RCVD_IN_DNSWL_HI=-5] autolearn=ham
Received: from mail.ietf.org ([4.31.198.44]) by localhost (ietfa.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id PE3QmNISMaoM for <rtcweb@ietfa.amsl.com>; Mon, 3 Mar 2014 14:19:29 -0800 (PST)
Received: from ihemail1.lucent.com (ihemail1.lucent.com [135.245.0.33]) by ietfa.amsl.com (Postfix) with ESMTP id 657AC1A006A for <rtcweb@ietf.org>; Mon, 3 Mar 2014 14:19:28 -0800 (PST)
Received: from us70tusmtp2.zam.alcatel-lucent.com (h135-5-2-64.lucent.com [135.5.2.64]) by ihemail1.lucent.com (8.13.8/IER-o) with ESMTP id s23MJNRN027031 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=FAIL); Mon, 3 Mar 2014 16:19:24 -0600 (CST)
Received: from US70UWXCHHUB02.zam.alcatel-lucent.com (us70uwxchhub02.zam.alcatel-lucent.com [135.5.2.49]) by us70tusmtp2.zam.alcatel-lucent.com (GMO) with ESMTP id s23MJNpi023244 (version=TLSv1/SSLv3 cipher=AES128-SHA bits=128 verify=FAIL); Mon, 3 Mar 2014 17:19:23 -0500
Received: from US70UWXCHMBA02.zam.alcatel-lucent.com ([169.254.8.212]) by US70UWXCHHUB02.zam.alcatel-lucent.com ([135.5.2.49]) with mapi id 14.02.0247.003; Mon, 3 Mar 2014 17:19:23 -0500
From: "Makaraju, Maridi Raju (Raju)" <Raju.Makaraju@alcatel-lucent.com>
To: Justin Uberti <juberti@google.com>, Randell Jesup <randell-ietf@jesup.org>
Thread-Topic: [rtcweb] Open data channel issues
Thread-Index: AQHPNvTjdPPAuXGnm0CBoOmgEn8ul5rP+SYA///UOvA=
Date: Mon, 03 Mar 2014 22:19:23 +0000
Message-ID: <E1FE4C082A89A246A11D7F32A95A17826E006069@US70UWXCHMBA02.zam.alcatel-lucent.com>
References: <31B9253D-E826-4D07-A8A1-1B062B50F163@lurchi.franken.de> <530D9CC5.5080508@ericsson.com> <5312FBBC.5080006@jesup.org> <CAOJ7v-2GHt37u8raWDKquNFLCjSv-ptP0YGojPwuLv02da_m1Q@mail.gmail.com> <5313EC0D.9030808@jesup.org> <CAOJ7v-3L5_V2wuwVLKpz61VHey7yx3LnG_xrPLb5W+6DOLiEJw@mail.gmail.com> <53146B2C.8080008@jesup.org> <CABkgnnV1BdAMvFqGq8xiL0Zu28aZBCAdPwZB8whpMeXrCD7AHQ@mail.gmail.com> <53149F0C.6070001@jesup.org> <CAOJ7v-0xSq2xvF_5Do-R4SG6yAVNdqELwRvt_VBU69ir6nHhGQ@mail.gmail.com>
In-Reply-To: <CAOJ7v-0xSq2xvF_5Do-R4SG6yAVNdqELwRvt_VBU69ir6nHhGQ@mail.gmail.com>
Accept-Language: en-US
Content-Language: en-US
X-MS-Has-Attach:
X-MS-TNEF-Correlator:
x-originating-ip: [135.5.27.16]
Content-Type: multipart/alternative; boundary="_000_E1FE4C082A89A246A11D7F32A95A17826E006069US70UWXCHMBA02z_"
MIME-Version: 1.0
Archived-At: http://mailarchive.ietf.org/arch/msg/rtcweb/1kxWX9K31cSRktYUFBh-wyQQsHs
Cc: "rtcweb@ietf.org" <rtcweb@ietf.org>
Subject: Re: [rtcweb] Open data channel issues
X-BeenThere: rtcweb@ietf.org
X-Mailman-Version: 2.1.15
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, 03 Mar 2014 22:19:34 -0000

Sorry to jump in from middle of nowhere in this interesting conversation. I couldn’t resist providing this feedback and I hope it is useful.

First, on “EOR solving monopolization issue”:
I could be wrong, but I am not sure how EOR based approach avoids SCTP link monopolization?! Per my understanding EOR is a local send () utility rather than receive side utility and it is implemented on top of base SCTP RFC (so no indication of special EOR in SCTP headers other than base SCTP RFC B/E fragment indication bits). Once a send () with EOR set to false is called, on a stream id, the SCTP link is monopolized until send () on same stream id with EOR set to true is called; so same limitation exist.  EOR allows sending side to start sending chunks without waiting for complete data. EOR has no impact on receiving side, the SCTP stack waits for last chunk (which is the result of sending side setting EOR=true) and delivers entire message to app.

New PC approach:
If an application is sensitive to SCTP link monopolisation then there is another option it can consider – use of separate new PeerConnection (PC) for the data channel(s) which may monopolize the link.
Depending on how an application is designed, using a new PC could be simpler than having an application level chunking protocol (fragmentation and reassembly).  If app needs such “heavy” data channel infrequently then it can create new PC as needed; if it is needed frequently then a dedicated PC can be allocated and keep it open all the time.

One disadvantage with application level chunking protocol is both the peers need to use it; so it may not work between clients of different types or same clients with different versions. New PC based approach obviously does not have this issue as no chunking is involved.

At first, new PC approach may appear heavy weight wrt # of PCs in use (which I don’t think an issue on browsers), ICE overhead for new PC etc. But in comparision to application level chunking new PC approach may not be that bad.

Please see additional comments inline.

-Raju

From: rtcweb [mailto:rtcweb-bounces@ietf.org] On Behalf Of Justin Uberti
Sent: Monday, March 03, 2014 11:54 AM
To: Randell Jesup
Cc: rtcweb@ietf.org
Subject: Re: [rtcweb] Open data channel issues



On Mon, Mar 3, 2014 at 7:26 AM, Randell Jesup <randell-ietf@jesup.org<mailto:randell-ietf@jesup.org>> wrote:
On 3/3/2014 8:53 AM, Martin Thomson wrote:
On 3 March 2014 03:44, Randell Jesup <randell-ietf@jesup.org<mailto:randell-ietf@jesup.org>> wrote:
Hopefully so, though I hate forcing apps to include a bunch of code for
backwards compat for a year or two (and many won't, or won't test it, etc).
That hurts the feature.  And today no one has ndata.
Since WebRTC is behind a flag, I don't find this particularly
convincing.  We can implement ndata.

I don't understand the "behind a flag" comment; an app using DataChannels for anything variable-length (unless with low bounds) must care until all old implementations are gone.  Since we already have DataChannel impls in  ESR releases, there's no avoiding this if we rely on that (even worse, since this undefined property doesn't exist yet (let alone in ESR), the app has to handle that case as well).  Or add browser and version sniffing to all the apps...

I think that we could even remove our temporary length restriction.

Sure, we can.  This will reduce or eliminate source changes for apps that don't care about interleaving, which is a plus.  It will cause total stall of all other DataChannels during  transmission of one large message, which some applications would be ok with, and others would not, and so those that would not would have to somehow deal with it.

So, applications that are ok with blocking other channels with large sends could be allowed to send arbitrary-sized messages, and receivers would be required to receive them (without chunking). Applications that do care about other channels would need to restrict their sending size when ndata isn't available at both ends.  We really only need to know if ndata is available and expose that fact to the application, not a receive size from the receiver.

So this plan would be:
1) We expose ndata being agreed to (currently == false);
2) We turn off the PPID chunking in Firefox (and live with ESR24 and current revs of Firefox not being compatible; see 2a)
2a) we make sure the app can detect if the local client has the ndata property at all (supports this solution).
3) We make sure Chrome and Firefox both implement both EOR sending and EOR reception and unlimited (or virtually) send/receive sizes.
[Raju] This requires PeerConnection API to indicate EOR during send(). Right? Which may be useful in some cases where app wants to send partial data as it is available/ready. But as explained above, in my opinion EOR won’t solve SCTP link monopolization and unncessarily introduces overhead at application.

For bonus points, on EOR reception of a blob, spool it to disk in the browser (if over some limit perhaps), and on EOR send of a blob, optimize it to avoid send-side memory hits and performance issues.

This will break large send/receive between Chrome and current/older Firefox - but those are broken today by Chrome not implement PPID chunking and Firefox doing so.  Firefox can still fall back on PPID chunking if it knows it's talking to another Firefox until we decide that this no longer matters.  I could be wrong, but I think Chrome doesn't support EOR sending currently; I know Firefox doesn't since we were using PPID chunking, so we'd need to add that.

Once ndata is supported, all will work well, and applications that didn't care about interleaving don't have to change, and those that do will trigger on ndata and switch (and they can test ndata==true mode reasonably well by forcing it in the app, since send(large) will work).

While I agree with the final outcome of #3, I don't think going down the 1/2/2a path makes
sense, since it leads to an additional intermediate state over the current situation. i.e. we end up with 3 states:
a) today: max safe send is 16 KB
b) soon: ndata exists, but large sends lock out other sends
c) final: ndata exists, and large sends work OK

I would rather maintain a) or similar for now (using the max-message-size param) and jump to c) when we have the right stuff in SCTP.
[Raju] With 16KB safe size won’t applications have to have their own chunking protocol? as per my understanding EOR won’t solve the monopolization issue, so it adds no value.

To avoid applications coming up with their own chunking protocol, an attractive alternative would be to use the PPID chunking that’s already mentioned abovr and implemented by Firefox. Then the issue of interworking pushed down to browser from application area. But this obviously requires browsers on both the ends to support this PPID based chunking.

-Raju



--
Randell Jesup -- rjesup a t mozilla d o t com
_______________________________________________
rtcweb mailing list
rtcweb@ietf.org<mailto:rtcweb@ietf.org>
https://www.ietf.org/mailman/listinfo/rtcweb