Re: [rtcweb] Proposal for PeerConnection cloning

Christer Holmberg <christer.holmberg@ericsson.com> Mon, 07 May 2012 06:22 UTC

Return-Path: <christer.holmberg@ericsson.com>
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 372DA21F84DF for <rtcweb@ietfa.amsl.com>; Sun, 6 May 2012 23:22:07 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -6.152
X-Spam-Level:
X-Spam-Status: No, score=-6.152 tagged_above=-999 required=5 tests=[AWL=0.097, BAYES_00=-2.599, HELO_EQ_SE=0.35, RCVD_IN_DNSWL_MED=-4]
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 mH2TwS-06uaO for <rtcweb@ietfa.amsl.com>; Sun, 6 May 2012 23:22:06 -0700 (PDT)
Received: from mailgw2.ericsson.se (mailgw2.ericsson.se [193.180.251.37]) by ietfa.amsl.com (Postfix) with ESMTP id D61C521F84DA for <rtcweb@ietf.org>; Sun, 6 May 2012 23:22:05 -0700 (PDT)
X-AuditID: c1b4fb25-b7b09ae000007d0f-13-4fa76a0c2e73
Received: from esessmw0191.eemea.ericsson.se (Unknown_Domain [153.88.253.125]) (using TLS with cipher AES128-SHA (AES128-SHA/128 bits)) (Client did not present a certificate) by mailgw2.ericsson.se (Symantec Mail Security) with SMTP id AF.89.32015.C0A67AF4; Mon, 7 May 2012 08:22:04 +0200 (CEST)
Received: from ESESSCMS0356.eemea.ericsson.se ([169.254.1.64]) by esessmw0191.eemea.ericsson.se ([153.88.115.84]) with mapi; Mon, 7 May 2012 08:22:03 +0200
From: Christer Holmberg <christer.holmberg@ericsson.com>
To: Randell Jesup <randell-ietf@jesup.org>, "rtcweb@ietf.org" <rtcweb@ietf.org>
Date: Mon, 07 May 2012 08:22:03 +0200
Thread-Topic: [rtcweb] Proposal for PeerConnection cloning
Thread-Index: Ac0sExCiE1bGQO68R827nRhMUccxOQABc8Og
Message-ID: <7F2072F1E0DE894DA4B517B93C6A05852C4435E11F@ESESSCMS0356.eemea.ericsson.se>
References: <6F428EFD2B8C2F49A2FB1317291A76C11364EC028C@USNAVSXCHMBSA1.ndc.alcatel-lucent.com> <7F2072F1E0DE894DA4B517B93C6A05852C44001342@ESESSCMS0356.eemea.ericsson.se> <6F428EFD2B8C2F49A2FB1317291A76C11364EC0293@USNAVSXCHMBSA1.ndc.alcatel-lucent.com> <4FA75E92.2050007@jesup.org>
In-Reply-To: <4FA75E92.2050007@jesup.org>
Accept-Language: en-US
Content-Language: en-US
X-MS-Has-Attach:
X-MS-TNEF-Correlator:
acceptlanguage: en-US
Content-Type: text/plain; charset="us-ascii"
Content-Transfer-Encoding: quoted-printable
MIME-Version: 1.0
X-Brightmail-Tracker: AAAAAA==
Subject: Re: [rtcweb] Proposal for PeerConnection cloning
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, 07 May 2012 06:22:07 -0000

Hi,

>> Hi Christer,
>> Question 1: I agree that for parallel forking, as long as a PC is cloned before the unused parent resources are
>> released, it is not necessary to allow cloning later.  I would be ok to remove this feature.  I threw it in because 
>> it seemed not too expensive to implement (others have to comment on this) and it might be useful to allow
>> delaying of cloning to the last possible instant (and for potentially other applications).
>>
>> Question 2: I do not think we want to automatically remove all related PCs when one gets a final answer, else we
>> could not support Partha's nested O/A scenario.  I propose that this be done manually (so it is not mentioned in the
>> proposal).  This allows  ICE and DTLS to progress independently with multiple targets until a winner is selected 
>> and the others are closed.
>
> If you want to support the usecase I suggested, where a single offer can result in parallel forking, but where you don't
> want to lock down to a single answerer: then you obviously need to support forking, and likely you need/want to support
> it irrespective of the 'final' state of the original PeerConnection.  You *can* require cloning before the final answer is 
> applied, though I would argue that you don't gain much by doing so.
>
> So this is the usecase: you send a single offer (say to a conference server controller, or to a game server) and you get 
> a separate answer from each other endpoint, such as in a mesh conference, or who are in the same 'area' of the game, 
> or in hearing (at that moment) in a VR environment.  You might get these answers well after the initial answer or burst 
> of answers.

Yes. And, my idea would be that each of those answers are provided to the browser as PRE_ANSWERS.

Then, at some point, you decide that you are not going to accept any more answers, and you provide an ANSWER to one of the (C)PCs, which will release all other associated (C)PCs.

Regards,

Christer



> -----Original Message-----
> From: Christer Holmberg [mailto:christer.holmberg@ericsson.com]
> Sent: Sunday, May 06, 2012 2:01 PM
> To: Ejzak, Richard P (Richard); rtcweb@ietf.org
> Subject: RE: [rtcweb] Proposal for PeerConnection cloning
>
> Hi Richard,
>
> Interesting proposal.
>
> In bullet 11, you say that, if a final answer has been received (and unused resources released), resources would have to be reallocated once a clone is created.
>
> A couple of questions:
>
> 1. Is there a need to allow cloning once a final answer has been received?
>
> 2. Once a final answer is received on a given PC, would it automatically remove all associated CPCs?
>
> The basic question is really whether there is a need for clones once a final answer has been received. After all, there is a reason we call it "final" :)
>
> Regards,
>
> Christer
>
> ________________________________
> From: rtcweb-bounces@ietf.org [rtcweb-bounces@ietf.org] On Behalf Of Ejzak, Richard P (Richard) [richard.ejzak@alcatel-lucent.com]
> Sent: Sunday, May 06, 2012 9:54 PM
> To: rtcweb@ietf.org
> Subject: [rtcweb] Proposal for PeerConnection cloning
>
> Harald asked for a proposal for PeerConnection cloning, so here it goes:
>
> I propose to create a new constructor "ClonePeerConnection" (CPC below) with the following semantics.
>
>
>   1.  CPC will create a new PeerConnection object when successful.  The resulting PC behaves just like any other PC except as described below.
>   2.  CPC will take as input a reference to an existing PeerConnection (PC) object (no configuration or IceCallback parameters).
>   3.  CPC can clone any other PC (including a cloned PC).  The sequence of cloning is not important and parents have no particular status different from any generation of clone.
>   4.  CPC will fail if either the local description of the parent PC is not set or the parent PC ICE is in ICE_CLOSED or ICE_GATHERING state.  The parent PC can be in the OPENING or ACTIVE state.
>   5.  The CPC object will inherit the local streams, local ICE candidates, and local description of the PC.
>   6.  The remote streams and remote description for the CPC object will be set to empty.
>   7.  The CPC object will be set to the OPENING state to reflect that only the local description is set.
>   8.  The ICE states other than CLOSED and GATHERING will be handled independently for each PC and its clones (as is true in standard forking scenarios).
>   9.  The ICE state for this clone will be set to ICE_WAITING to reflect that all candidates are available but the remote configuration is not yet set.
>   10. The PC and its clone(s) use a common pool of media resources.
>   11. If the parent PC object has already released unused resources (final ANSWER), resources are reallocated as available to reflect the capabilities for each stream (as they would be reflected in a createOffer).
>   12. The local streams might multicast toward the remote targets depending on the directionality attributes independently set for each PC and clone.
>   13. The application should manage the directionality attributes for remote streams from different targets to avoid resource conflicts.
>
> CPC will be used primarily if forking is anticipated or actually occurs.  It can also be used to clone a stable PC if desired for other reasons.  When used for SIP forking, creation of the clone can be delayed until an ANSWER actually arrives from a 2nd target as long as final ANSWER hasn't been applied to the parent (PRANSWER is OK).  The parent always handles the first target; the first clone handles the 2nd target; etc.  The application can even try to clone for forking after the first ANSWER is applied to the parent and resources are released, as long as the local description has not changed, at the risk that some resources needed for the 2nd target are no longer available and must be renegotiated.
>
> Comments on this proposal are welcome.
>
> Richard

-- 
Randell Jesup
randell-ietf@jesup.org

_______________________________________________
rtcweb mailing list
rtcweb@ietf.org
https://www.ietf.org/mailman/listinfo/rtcweb