Re: [rtcweb] New Version Notification for draft-jesup-rtcweb-data-01.txt

Randell Jesup <randell-ietf@jesup.org> Sat, 12 November 2011 00:15 UTC

Return-Path: <randell-ietf@jesup.org>
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 06FC821F84A7 for <rtcweb@ietfa.amsl.com>; Fri, 11 Nov 2011 16:15:11 -0800 (PST)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -2.562
X-Spam-Level:
X-Spam-Status: No, score=-2.562 tagged_above=-999 required=5 tests=[AWL=0.037, 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 amzwpRMEjU7Q for <rtcweb@ietfa.amsl.com>; Fri, 11 Nov 2011 16:15:10 -0800 (PST)
Received: from r2-chicago.webserversystems.com (r2-chicago.webserversystems.com [173.236.101.58]) by ietfa.amsl.com (Postfix) with ESMTP id 1A36221F84A1 for <rtcweb@ietf.org>; Fri, 11 Nov 2011 16:15:09 -0800 (PST)
Received: from pool-173-49-135-74.phlapa.fios.verizon.net ([173.49.135.74] helo=[192.168.1.12]) by r2-chicago.webserversystems.com with esmtpsa (TLSv1:AES256-SHA:256) (Exim 4.69) (envelope-from <randell-ietf@jesup.org>) id 1RP1FV-0007Qs-I6 for rtcweb@ietf.org; Fri, 11 Nov 2011 18:15:09 -0600
Message-ID: <4EBDBA63.7010809@jesup.org>
Date: Fri, 11 Nov 2011 19:14:27 -0500
From: Randell Jesup <randell-ietf@jesup.org>
User-Agent: Mozilla/5.0 (Windows NT 5.1; rv:8.0) Gecko/20111105 Thunderbird/8.0
MIME-Version: 1.0
To: rtcweb@ietf.org
References: <20111031211134.8188.49554.idtracker@ietfa.amsl.com> <4EAF64FF.8020101@jesup.org> <02485FF93524F8408ECA9608E47D9F2007CACFFAC2@nambx05.corp.adobe.com> <474200CA-F509-438B-A9CD-71742F4AF6B7@lurchi.franken.de> <02485FF93524F8408ECA9608E47D9F2007CAE80473@nambx05.corp.adobe.com> <E1C96764-9AD2-4925-A3C9-DCC1EF6E9D98@lurchi.franken.de>
In-Reply-To: <E1C96764-9AD2-4925-A3C9-DCC1EF6E9D98@lurchi.franken.de>
Content-Type: text/plain; charset=ISO-8859-1; format=flowed
Content-Transfer-Encoding: 7bit
X-AntiAbuse: This header was added to track abuse, please include it with any abuse report
X-AntiAbuse: Primary Hostname - r2-chicago.webserversystems.com
X-AntiAbuse: Original Domain - ietf.org
X-AntiAbuse: Originator/Caller UID/GID - [47 12] / [47 12]
X-AntiAbuse: Sender Address Domain - jesup.org
X-Source:
X-Source-Args:
X-Source-Dir:
Subject: Re: [rtcweb] New Version Notification for draft-jesup-rtcweb-data-01.txt
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: Sat, 12 Nov 2011 00:15:11 -0000

On 11/11/2011 4:14 PM, Michael Tuexen wrote:
> On Nov 11, 2011, at 8:52 PM, Michael Thornburgh wrote:
>
>>>> o (most important for real-time communication): each user data fragment/chunk is assigned an SCTP Transmission Sequence Number (TSN) at the time of first transmission. that means even if your SCTP implementation supported stream prioritization somehow, the priority decision is only made at first transmission time. since there's just one TSN space and the Gap Ack structure only talks about TSNs, it's undesirable for gaps to persist (else the Gap Ack structure will continue to grow as more losses naturally happen). therefore it's desirable to repair gaps as quickly as possible. this may inappropriately increase the priority of a low priority fragment/chunk/stream during periods of congestion, which is exactly when priority matters (this is a "priority inversion").
>>> What might help is that messages have priorities and the sender is allowed to abandon messages
>>> with low priorities in case of congestion (timer based retransmissions). Something which is supported by PR-SCTP.
>> sure. but the problem here is the low priority stream is likely to be one that needs full reliability (like a bulk data transfer that you want to use "background" bandwidth but still eventually get delivered). in that case you don't want the sender to abandon the low priority message, and that's what leads to the priority inversion.
> So you want to send the bulk transfer with low priority but full reliability?


Yes, this would be quite common for things like background file 
transfers and data synchronization.

> And have some other messages, for example with high priority, but only limited reliability?
> You could do this. The only point: You need something to drop to improve things.


Yes, the background reliable flow *should* slow down, but it must remain 
reliable.  It would probably be ok if the background flow slowed down, 
and the high-priority flow also slowed down.

Note that we're talking about interactions with congestion-control here, 
and the algorithm can be modified (and we're talking about integrated 
congestion control between media and data anyways).

> Or do you want everything with full reliability?

No.

>> priority doesn't solve the problem at all. the issue is that if the receiver needs to stop accepting data on one stream, the only indication of reverse pressure to the sender is the association-wide receive window advertisement. the only in-protocol flow control is association-wide. the only solution is to not have the receiver suspend reading any stream and to use application-layer flow control to signal the sender to stop sending data on one stream or another.
> We have looked into this. Providing per stream flow control is hard to do as an extension
> to SCTP without introducing deadlocks. Looking at the SCTP socket API, there is a socket
> per association, so you can't read per stream. If you want signaling from the receiver,
> it must be done at the application layer. You can't use the flow control mechanism for that.

We can probably state that the app must deal with getting data for all 
streams; it can't decide not to service one stream of data, or implement 
application-level flow control.

>
>>>> o the semantics of unordered messages are confusing and not a good map to WebRTC. they are semantically equivalent to an entirely separate stream loosely associated to the ordered stream of the same number. there's no way to tell (without application layer sequencing) if an unordered message has been lost/abandoned by the sender. at the protocol level, TSNs can be used to recover the queuing order of received unordered messages, but the TSNs are semantically disconnected from the SCTP user. recovering the original queuing order over a short reorder/reassembly window period is desirable in some real-time applications.
>>> The concept of PR-SCTP is that the receiver can handle this. Since the sender decided that the sequencing
>>> is not important, why should be receiver care?
>> my main point was that, specifically in the case of PR-SCTP, since unordered messages don't have a stream sequence number there's no way to tell at the receiver if one (or more) has been abandoned. gaps in the ordered message space can be detected.
> Conceptual question: Why does unordered  data need some ordering information.
> It sounds to me that you don't have unordered stuff in mind, but ordered unreliable stuff.


Because of state:  If you have datagrams A, B, C, and it's delivered B, 
A, C, you may throw away A *if* the data in A was already provided or 
updated in B, but not throw it away if B and A are independent.  You 
need to know the original ordering to know that.  Games will do stuff 
like this.

Also, with datagrams you may need to know about losses when in-order 
(gaps), to change how you process data (simple example: PR-SCTP for 
lossy audio; on a missing packet you synthesize a replacement instead of 
ignoring the loss.)

Yes, these can be done with application sequence numbers (so long as 
out-of-order delivery is allowed).  It's moderately inefficient to do so 
if the sequence data is available in the protocol.

>>>> o an SCTP receiver should be able to choose to receive stream messages in originally-queued order or as-received-on-the-network order on a per-stream basis, and be able to recover the original queuing order to whatever extent desired (potentially limited by real-time constraints) when receiving in network order. SCTP's unordered message semantics are designed for "out-of-band" messages, and are not a good fit for general "real-time" data. transmission order should be determined by the sender, reception order should be determined by the receiver.
>>> It is a sender side thing. If the sender requires in-sequence delivery, you want the receiver to ignore
>>> this requirement? If there is not sequencing constraint, the sender should not send it ordered.
>> it's natural to use unordered messages for real-time data, since they can be delivered to the user as soon as they arrive even if there are gaps. however, in exactly these real-time scenarios, it's still often useful to know the original queuing order of the messages, and to allow the receiver to partially recover the original queuing order in, for example, a jitter/reorder buffer. this can be accomplished with application-layer sequence numbers, but it seems silly to have to duplicate existing protocol-level functionality (see my point about flow control above).
> Hmm. Looking at the service you want doesn't seem be unordered. For me this looks like
> an ordered unreliable service, taking some timing requirements into account.


A jitter buffer is in fact inherently an in-order partial-reliability 
service, true - but with different characteristics from SCTP 
partial-reliability (adaptive to the jitter level, perhaps to appearance 
of spikes or bulk-delay changes, concealment, whether it's isochronous 
in output, etc).  As mentioned before, there are other uses of true 
out-of-order delivery.

> So the problem is not, that SCTP does not provide a SSN for unordered DATA chunks,
> but that you use unordered messages instead of ordered and that currently you can't
> tell SCTP to deliver messages if they stayed for some time in the receive buffer.
> However, this is a receiver side only thing which could be done. This would be
> a local receiver side only modification supporting partial reliability. It could be
> done. It is more an API issue.


Right: After reading a datagram, do GetLastSerialNum() or some such.

> However, I would assume that this applies mostly to multi media stuff. Isn't RTP
> the protocol being considered for that?


Yes, and *we* don't plan to operate RTP jitter buffers through SCTP.  
But an application built on webrtc might, and certainly they may do the 
B, A, C stuff I mentioned above (and react in their app to whether there 
was any loss).


-- 
Randell Jesup
randell-ietf@jesup.org