Re: [rtcweb] My Opinion: Why I think a negotiating protocol is a Good Thing

Neil Stratford <> Tue, 18 October 2011 12:20 UTC

Return-Path: <>
Received: from localhost (localhost []) by (Postfix) with ESMTP id 6CB4521F8B39 for <>; Tue, 18 Oct 2011 05:20:14 -0700 (PDT)
X-Virus-Scanned: amavisd-new at
X-Spam-Flag: NO
X-Spam-Score: -2.955
X-Spam-Status: No, score=-2.955 tagged_above=-999 required=5 tests=[AWL=0.021, BAYES_00=-2.599, FM_FORGED_GMAIL=0.622, HTML_MESSAGE=0.001, RCVD_IN_DNSWL_LOW=-1]
Received: from ([]) by localhost ( []) (amavisd-new, port 10024) with ESMTP id pvGMEaHHjVif for <>; Tue, 18 Oct 2011 05:20:13 -0700 (PDT)
Received: from ( []) by (Postfix) with ESMTP id AEED721F8B37 for <>; Tue, 18 Oct 2011 05:20:06 -0700 (PDT)
Received: by iabn5 with SMTP id n5so752156iab.31 for <>; Tue, 18 Oct 2011 05:20:05 -0700 (PDT)
MIME-Version: 1.0
Received: by with SMTP id u32mr970450ibb.61.1318940404701; Tue, 18 Oct 2011 05:20:04 -0700 (PDT)
Received: by with HTTP; Tue, 18 Oct 2011 05:20:04 -0700 (PDT)
In-Reply-To: <>
References: <>
Date: Tue, 18 Oct 2011 13:20:04 +0100
X-Google-Sender-Auth: kGWo55iLuMOqk8tp7S2Ceu4_0Rc
Message-ID: <>
From: Neil Stratford <>
To: Harald Alvestrand <>
Content-Type: multipart/alternative; boundary="0015177414284d594204af91becd"
Cc: "" <>
Subject: Re: [rtcweb] My Opinion: Why I think a negotiating protocol is a Good Thing
X-Mailman-Version: 2.1.12
Precedence: list
List-Id: Real-Time Communication in WEB-browsers working group list <>
List-Unsubscribe: <>, <>
List-Archive: <>
List-Post: <>
List-Help: <>
List-Subscribe: <>, <>
X-List-Received-Date: Tue, 18 Oct 2011 12:20:14 -0000

On Tue, Oct 18, 2011 at 12:43 PM, Harald Alvestrand <>wrote:

> I believe we need to standardize a negotiation protocol as part of RTCWEB.
> This needs to be described as a protocol, and cannot usefully be described
> as an API.

I strongly disagree. We need an API, not a protocol. This is a fundamentally
different problem to traditional RTC due to the presence of the javascript
execution engine that can implement the protocol.

> A design criterion for RTCWEB has been that it should be possible to write
> applications on top of RTCWEB simply - that is, without deep knowledge about
> the world of codecs, RTP sessions and the like.

Which can be achieved even with a low-level javascript API by leveraging
library code. We do not need to embed every bit of intelligence into the
browser to enable that to happen.

> Another design criterion is that interworking should be possible - which
> means that SOMEWHERE in the system, deep knowledge about the world of
> codecs, RTP sessions and the like must be embedded; we can’t just simplify
> our options until everything’s simple.
> There’s one place in the ecosystem where this knowledge HAS to be - and
> that is within the browser, the component that takes care of implementing
> the codecs, the RTP sessions and the related features. If we can avoid
> requiring embedding it twice, that’s a feature.

Agreed - the browser handles RTP and codecs, and the javascript should
handle negotiation and protocol state machines.

> It used to be that I was a believer in APIs - that we should make the API
> the “king”, and describe the way you generate an RTP session as “you turn
> this knob, and get this effect”.
> After looking at the problem of Web applications that don’t have domain
> knowledge for a while, I’ve concluded that this doesn’t work. There’s the
> need for one browser to communicate with the other browser, and if the
> intermediate components are to have the ability to ignore the details,
> what’s communicated has to be treated like a blob - something passed out of
> one browser’s API and into another browser’s API, unchanged by the
> application - because the application must be able to ignore the details.

The application can equally ignore what a library does if it wants to, but
it's not tied to one library, it can pick the one most suited to the task in

> What’s more - we DO want to enable applications that are NOT simple.
> Including gateways, which are not browsers. So applications must be free to
> look inside the blob - break the blob boundary - when they need to. So this
> pulls in the same direction as the need for interoperability - the format,
> semantics and handling rules for these blobs has to be specified. In some
> detail.

This is the problem with passing blobs through an API. If we had a low-level
API we wouldn't be passing blobs.