
From stpeter@stpeter.im  Fri May  1 13:27:34 2009
Return-Path: <stpeter@stpeter.im>
X-Original-To: hybi@core3.amsl.com
Delivered-To: hybi@core3.amsl.com
Received: from localhost (localhost [127.0.0.1]) by core3.amsl.com (Postfix) with ESMTP id 8DB2A28C200 for <hybi@core3.amsl.com>; Fri,  1 May 2009 13:27:34 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -2.387
X-Spam-Level: 
X-Spam-Status: No, score=-2.387 tagged_above=-999 required=5 tests=[AWL=0.212,  BAYES_00=-2.599]
Received: from mail.ietf.org ([64.170.98.32]) by localhost (core3.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id EpzJ1K06Elq9 for <hybi@core3.amsl.com>; Fri,  1 May 2009 13:27:33 -0700 (PDT)
Received: from dizzyd.com (dizzyd.com [207.210.219.225]) by core3.amsl.com (Postfix) with ESMTP id 5A1DE3A6FBA for <hybi@ietf.org>; Fri,  1 May 2009 13:27:25 -0700 (PDT)
Received: from squire.local (dsl-240-91.dynamic-dsl.frii.net [216.17.240.91]) (Authenticated sender: stpeter) by dizzyd.com (Postfix) with ESMTPSA id EFA08E803D for <hybi@ietf.org>; Fri,  1 May 2009 14:28:43 -0600 (MDT)
Message-ID: <49FB5B73.1020909@stpeter.im>
Date: Fri, 01 May 2009 14:28:35 -0600
From: Peter Saint-Andre <stpeter@stpeter.im>
User-Agent: Thunderbird 2.0.0.21 (Macintosh/20090302)
MIME-Version: 1.0
To: hybi@ietf.org
X-Enigmail-Version: 0.95.7
OpenPGP: url=http://www.saint-andre.com/me/stpeter.asc
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 7bit
Subject: [hybi] [Fwd: [AVT] iPhone streaming Internet-Draft posted]
X-BeenThere: hybi@ietf.org
X-Mailman-Version: 2.1.9
Precedence: list
List-Id: Server-Initiated HTTP <hybi.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/listinfo/hybi>, <mailto:hybi-request@ietf.org?subject=unsubscribe>
List-Archive: <http://www.ietf.org/mail-archive/web/hybi>
List-Post: <mailto:hybi@ietf.org>
List-Help: <mailto:hybi-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/hybi>, <mailto:hybi-request@ietf.org?subject=subscribe>
X-List-Received-Date: Fri, 01 May 2009 20:27:34 -0000

This I-D might be of interest here:

http://www.ietf.org/internet-drafts/draft-pantos-http-live-streaming-00.txt

-------- Original Message --------
Subject: [AVT] iPhone streaming Internet-Draft posted
Date: Fri, 1 May 2009 13:24:48 -0700
From: Roger Pantos <rpantos@apple.com>
To: avt@ietf.org
CC: http-live-streaming-review@group.apple.com


My apologies if this is a bit off-topic - it concerns Audio/Video
Transport
rather than RTP specifically.

I just posted draft-pantos-http-live-streaming-00.txt:

   This document describes a protocol for transmitting unbounded
streams
   of multimedia data over HTTP.  It specifies the data format of the
   files and the actions to be taken by the server (sender) and the
   clients (receivers) of the streams.  It describes version 1.0 of
this
   protocol.

The complete draft  is available here:

https://datatracker.ietf.org/drafts/draft-pantos-http-live-streaming/

We appreciate feedback on the protocol. Please send it to
http-live-streaming-review@group.apple.com.


thank you,

Roger Pantos
Apple, Inc.
_______________________________________________
Audio/Video Transport Working Group
avt@ietf.org
https://www.ietf.org/mailman/listinfo/avt



From john.fallows@kaazing.com  Mon May  4 10:55:15 2009
Return-Path: <john.fallows@kaazing.com>
X-Original-To: hybi@core3.amsl.com
Delivered-To: hybi@core3.amsl.com
Received: from localhost (localhost [127.0.0.1]) by core3.amsl.com (Postfix) with ESMTP id 563383A706E for <hybi@core3.amsl.com>; Mon,  4 May 2009 10:55:15 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -0.12
X-Spam-Level: 
X-Spam-Status: No, score=-0.12 tagged_above=-999 required=5 tests=[AWL=-0.557,  BAYES_40=-0.185, FM_FORGED_GMAIL=0.622]
Received: from mail.ietf.org ([64.170.98.32]) by localhost (core3.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id edVY9ItuSXd9 for <hybi@core3.amsl.com>; Mon,  4 May 2009 10:55:14 -0700 (PDT)
Received: from mail-ew0-f224.google.com (mail-ew0-f224.google.com [209.85.219.224]) by core3.amsl.com (Postfix) with ESMTP id D41CD3A69FC for <hybi@ietf.org>; Mon,  4 May 2009 10:55:09 -0700 (PDT)
Received: by ewy24 with SMTP id 24so4185615ewy.37 for <hybi@ietf.org>; Mon, 04 May 2009 10:56:33 -0700 (PDT)
MIME-Version: 1.0
Received: by 10.142.238.20 with SMTP id l20mr2269787wfh.169.1241459791974;  Mon, 04 May 2009 10:56:31 -0700 (PDT)
In-Reply-To: <49F963D9.7020009@webtide.com>
References: <c5b3a7130904291207g51201c23q156ac76bce9efaf4@mail.gmail.com> <49F963D9.7020009@webtide.com>
Date: Mon, 4 May 2009 10:56:31 -0700
Message-ID: <c5b3a7130905041056t50f2b9f5k118f2607a8aaa3ae@mail.gmail.com>
From: John Fallows <john.fallows@kaazing.com>
To: Greg Wilkins <gregw@webtide.com>
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: quoted-printable
Cc: hybi@ietf.org
Subject: Re: [hybi] Divide and conquer?
X-BeenThere: hybi@ietf.org
X-Mailman-Version: 2.1.9
Precedence: list
List-Id: Server-Initiated HTTP <hybi.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/listinfo/hybi>, <mailto:hybi-request@ietf.org?subject=unsubscribe>
List-Archive: <http://www.ietf.org/mail-archive/web/hybi>
List-Post: <mailto:hybi@ietf.org>
List-Help: <mailto:hybi-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/hybi>, <mailto:hybi-request@ietf.org?subject=subscribe>
X-List-Received-Date: Mon, 04 May 2009 17:55:15 -0000

Greg,

On Thu, Apr 30, 2009 at 1:39 AM, Greg Wilkins <gregw@webtide.com> wrote:
>
> John,
>
> I think this is a good plan, but with some caveats.

Great.

> The current websocket API is described in very network related
> way. Eg it is about opening connections and connection state etc.
>
> If the separation of concerns that you describe is to be successful
> then the websocket API is going need to be recast in less
> network centric language - ie saying channel/conduit/pipe or similar
> instead of connection. =A0 =A0 From the API point of view, it should not
> matter if that channel/conduit/pipe is carried over a dedicated
> socket or some other possibly shared transport.

So far on the mailing list, we've been discussing a number of
different intermingled issues that contribute to this complex problem
space.
The steps outlined in the plan provide a common sense step-by-step
approach to help us solve this problem together.
Discussions related to the specific API that we'll define are more
productive after gaining the relevant insights from prerequisite
network characteristics, otherwise we run the risk eliminating the
benefits of our common-sense approach.

> There would need to be a good dialog between the API concerns
> and the network concerns. =A0 =A0Perhaps that could start by the
> API writing up some requirements that they would like the
> network concerns to provide.

I'm sure we'll be able to hear everyone's focused and constructive
feedback in the relevant threads.  Next up - the "Connection Strategy"
thread.

Kind Regards,
John Fallows.

> John Fallows wrote:
>> Folks,
>>
>> In an effort to help organize our thoughts and discussion, I propose
>> we divide the problem into chunks and tackle each one separately.
>>
>> =A0 o Connection strategy - eg. crossdomain.xml + raw TCP, HTTP 101
>> Switching Protocols, etc
>> =A0 o Proxy traversal strategy - eg. transparent proxies,
>> non-transparent proxies, reverse proxies, etc
>> =A0 o Wire protocol - eg. raw TCP, text/binary frames, higher-level
>> messaging protocols, etc
>> =A0 o JavaScript APIs - eg. event-driven data, notify then read,
>> higher-level messaging protocols, etc
>>
>> Does this seem like a reasonable separation of concerns that would
>> help us to make useful progress?
>>
>> Based on the separation of responsibilities between the IETF and the
>> W3C, it seems that connection strategy, proxy traversal strategy and
>> wire protocol would fall under the IETF whereas JavaScript APIs would
>> fall under the W3C.
>>
>> Therefore, assuming that the above separation of topics is useful, I'm
>> planning to wait a day or so to give folks a chance to respond, then
>> start a thread on each of the topics that pertain to the IETF.
>>
>> Kind Regards,
>> John Fallows.
>>
>> Disclaimer: =A0Kaazing currently offers (emulated) WebSocket-based
>> products that implement both the wire protocol (when possible,
>> otherwise fallback to HTTP) and JavaScript API from a draft of the
>> specification(s). =A0Our goal in participating with the IETF and the W3C
>> is offer insights gained from customer feedback to help standardize
>> the future of real-time communications on the Web.
>>
>
>



--=20
>|< Kaazing Corporation >|<
John Fallows | CTO | +1.650.960.8148
888 Villa St, Ste 410 | Mountain View, CA 94041, USA

From john.fallows@kaazing.com  Mon May  4 13:20:02 2009
Return-Path: <john.fallows@kaazing.com>
X-Original-To: hybi@core3.amsl.com
Delivered-To: hybi@core3.amsl.com
Received: from localhost (localhost [127.0.0.1]) by core3.amsl.com (Postfix) with ESMTP id 1CB2828C263 for <hybi@core3.amsl.com>; Mon,  4 May 2009 13:20:02 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -1.141
X-Spam-Level: 
X-Spam-Status: No, score=-1.141 tagged_above=-999 required=5 tests=[AWL=0.836,  BAYES_00=-2.599, FM_FORGED_GMAIL=0.622]
Received: from mail.ietf.org ([64.170.98.32]) by localhost (core3.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id iQv4F-PIB0Ja for <hybi@core3.amsl.com>; Mon,  4 May 2009 13:20:01 -0700 (PDT)
Received: from wf-out-1314.google.com (wf-out-1314.google.com [209.85.200.172]) by core3.amsl.com (Postfix) with ESMTP id 2C31828C23D for <hybi@ietf.org>; Mon,  4 May 2009 13:20:01 -0700 (PDT)
Received: by wf-out-1314.google.com with SMTP id 29so3445855wff.31 for <hybi@ietf.org>; Mon, 04 May 2009 13:21:25 -0700 (PDT)
MIME-Version: 1.0
Received: by 10.142.82.13 with SMTP id f13mr2505441wfb.301.1241468485813; Mon,  04 May 2009 13:21:25 -0700 (PDT)
Date: Mon, 4 May 2009 13:21:25 -0700
Message-ID: <c5b3a7130905041321n35c55096gd75041b33011aa34@mail.gmail.com>
From: John Fallows <john.fallows@kaazing.com>
To: hybi@ietf.org
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: 7bit
Subject: [hybi] Connection Strategy
X-BeenThere: hybi@ietf.org
X-Mailman-Version: 2.1.9
Precedence: list
List-Id: Server-Initiated HTTP <hybi.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/listinfo/hybi>, <mailto:hybi-request@ietf.org?subject=unsubscribe>
List-Archive: <http://www.ietf.org/mail-archive/web/hybi>
List-Post: <mailto:hybi@ietf.org>
List-Help: <mailto:hybi-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/hybi>, <mailto:hybi-request@ietf.org?subject=subscribe>
X-List-Received-Date: Mon, 04 May 2009 20:20:02 -0000

Folks,

As promised, this "Connection Strategy" thread is the first of our
focused IETF discussions outlined previously.

o Connection strategy (now)
o Proxy traversal strategy (next)
o Wire protocol (after that)

The overall goal for this thread is to define a connection strategy
that can be used by future browsers for full-duplex, bidirectional
communication, while integrating with the browser security model.
This connection strategy discussion does not cover any details of the
specific bytes on the wire after the connection has been established,
and is therefore post-connection protocol agnostic.  Hopefully, the
connection strategy would be sufficiently general-purpose to apply
beyond the browser usecase as well.

I plan to present a discussion of the requirements for the connection
strategy, my understanding of the available alternatives and a logical
conclusion based on the preceding analysis.

The browser security model defines the trust boundary between
different code served by different "origin" servers.  The origin
concept is defined by HTML5 [1] as follows:

"The origin of a resource and the effective script origin of a
resource are both either opaque identifiers or tuples consisting of a
scheme component, a host component, a port component, and optionally
extra data."

The Cross-Origin Resource Sharing specification [2] relaxes the
same-origin request constraint by defining an opt-in cross-origin
communication strategy that uses the "Origin" HTTP header.

The rationale for relaxing the same-origin request constraint for HTTP
resources applies equally well to bidirectional communication, which
seems well-matched by an HTTP-based "Origin" header connection
strategy.

There are a number of different bidirectional communication connection
strategies available, such as:
  o crossdomain.xml + separate raw TCP connection
  o HTTP Upgrade in-band to raw TCP
  o Multiple HTTP requests representing independent upstream and downstream
  o Multiple HTTP requests representing overlapping upstream and
downstream (BOSH)

Are there other connection strategies worth considering here?

Note: Using a non-HTTP protocol such as XMPP or BEEP to establish
communication is not a separate connection strategy as it would fall
under crossdomain.xml with separate TCP connection.

In-band upgrade from HTTP to raw TCP (remember discussion of specific
protocol bytes sent over TCP comes later) has some
potentially-significant security benefits over separate control and
data channels such as crossdomain.xml.  The concept of domain is
equivalent to origin but without the port, which can introduce an
attack vector for virtual hosting environments where different users
may have control over different ports.  In this case, the trust model
assumed by the plug-in runtime does not match the trust model enforced
at the server.  In-band upgrade from HTTP using "Origin" header forces
these trust models to match scheme, host and port.

When an in-band HTTP Upgrade is successful, the server responds with a
101 Switching Protocols status code, as specified by RFC2616, section
10.1.2.

"The server understands and is willing to comply with the client's
request, via the Upgrade message header field (section 14.42), for a
change in the application protocol being used on this connection. The
server will switch protocols to those defined by the response's
Upgrade header field immediately after the empty line which terminates
the 101 response.

The protocol SHOULD be switched only when it is advantageous to do so.
For example, switching to a newer version of HTTP is advantageous over
older versions, and switching to a real-time, synchronous protocol
might be advantageous when delivering resources that use such
features."

Using multiple different HTTP requests to provide full-duplex
bidirectional communication is a necessary compromise for today's
browser implementations, and is still subject to the HTTP 2 connection
limit recommended by RFC2616, section 8.1.4 Practical Considerations
[3].  A single post-connection TCP stream makes more efficient use of
the network, and gives us the most flexibility in designing the wire
protocol framing for future browser implementations, and seems to be
more general purpose for use by non-browser clients.

In conclusion, an HTTP Upgrade with Origin header strategy seems to do
a good job of balancing the requirements.

Looking forward to a fun and productive discussion.

Kind Regards,
John Fallows

[1] http://dev.w3.org/html5/spec/Overview.html#origin
[2] http://www.w3.org/TR/access-control/
[3] http://www.ietf.org/rfc/rfc2616.txt

--
>|< Kaazing Corporation >|<
John Fallows | CTO | +1.650.960.8148
888 Villa St, Ste 410 | Mountain View, CA 94041, USA

From gregw@webtide.com  Mon May  4 20:50:27 2009
Return-Path: <gregw@webtide.com>
X-Original-To: hybi@core3.amsl.com
Delivered-To: hybi@core3.amsl.com
Received: from localhost (localhost [127.0.0.1]) by core3.amsl.com (Postfix) with ESMTP id 902773A6C71 for <hybi@core3.amsl.com>; Mon,  4 May 2009 20:50:27 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -2.549
X-Spam-Level: 
X-Spam-Status: No, score=-2.549 tagged_above=-999 required=5 tests=[AWL=0.050,  BAYES_00=-2.599]
Received: from mail.ietf.org ([64.170.98.32]) by localhost (core3.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id TGAEeJlQ4XFD for <hybi@core3.amsl.com>; Mon,  4 May 2009 20:50:26 -0700 (PDT)
Received: from yw-out-2324.google.com (yw-out-2324.google.com [74.125.46.29]) by core3.amsl.com (Postfix) with ESMTP id 554FE3A6CE4 for <hybi@ietf.org>; Mon,  4 May 2009 20:50:24 -0700 (PDT)
Received: by yw-out-2324.google.com with SMTP id 3so4998897ywj.49 for <hybi@ietf.org>; Mon, 04 May 2009 20:51:49 -0700 (PDT)
Received: by 10.90.80.18 with SMTP id d18mr5957376agb.1.1241495508522; Mon, 04 May 2009 20:51:48 -0700 (PDT)
Received: from ?10.10.1.13? (60-242-119-126.tpgi.com.au [60.242.119.126]) by mx.google.com with ESMTPS id 7sm12002492agc.7.2009.05.04.20.51.45 (version=TLSv1/SSLv3 cipher=RC4-MD5); Mon, 04 May 2009 20:51:47 -0700 (PDT)
Message-ID: <49FFB7CD.50609@webtide.com>
Date: Tue, 05 May 2009 13:51:41 +1000
From: Greg Wilkins <gregw@webtide.com>
User-Agent: Thunderbird 2.0.0.21 (X11/20090409)
MIME-Version: 1.0
To: John Fallows <john.fallows@kaazing.com>
References: <c5b3a7130905041321n35c55096gd75041b33011aa34@mail.gmail.com>
In-Reply-To: <c5b3a7130905041321n35c55096gd75041b33011aa34@mail.gmail.com>
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: 7bit
Cc: hybi@ietf.org
Subject: Re: [hybi] Message Strategy Was: Connection Strategy.
X-BeenThere: hybi@ietf.org
X-Mailman-Version: 2.1.9
Precedence: list
List-Id: Server-Initiated HTTP <hybi.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/listinfo/hybi>, <mailto:hybi-request@ietf.org?subject=unsubscribe>
List-Archive: <http://www.ietf.org/mail-archive/web/hybi>
List-Post: <mailto:hybi@ietf.org>
List-Help: <mailto:hybi-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/hybi>, <mailto:hybi-request@ietf.org?subject=subscribe>
X-List-Received-Date: Tue, 05 May 2009 03:50:27 -0000

John,


I don't mean to be disruptive to your good attempt to
bring some order to the wide ranging discussions here....

but...


I've relabelled this phase "Message Strategy", because
I don't think we can assume that connections are the
starting point of this discussion.


The references that you cite discuss origins and cross domain
as they apply to individual resources - not connections.
HTTP allows resources from different origins to
be transported over the same connection (proxies).


With HTTP, every client to server message semantically
has it's own URL, and thus it's own origin/domain.

With WebSocket, there is only a single origin/domain
that is associated with an entire connection.


I don't we should assume either model and should have
a discussion about which of these (or other models)
we prefer.  Indeed some may advocate streaming rather
than messaging.

It is a later transport discussion when we can discuss
how messages might relate to connections etc.

-------------

For my contribution to messaging strategy:



I advocate messaging over streaming because streamed
data is essentially small messages at the quantum of bytes
or bits.     The arguments for streaming and against messaging
are essentially transport discussions about the efficiency of
appropriate framing.  So let's defer that discussion (and if
we have lots of 1 bytes messages, then the framing can be
designed to match that).


I advocate messaging over connection based abstraction
because making connections a non-transport
issue can be very limiting.

For example, assuming a single origin per connection limits
multiplexing and it would not be possible to offload bidirectional
SSL to dedicated hardware that terminated all the SSL connections
and forwarded messages to the server over fewer connections.

Another example is a mashup page that contains javascript
from multiple origins, but all of them wish to establish
bidirectional communications with the same cross domain.
If we assume connection semantics, then multiple connections
will be required to the same server just to convey the
multiple origins involved.

I'm not opposed to specific transports being developed
that do allow origin and domain to be assumed for all
messages on a connection (and thus not have to send them),
but that is a transport efficiency issue and not something
that should be part of the central design of the communications
paradygm.



I agree with John that the definition of Origin should
be adopted from his [1] reference.  This implies that
each message has an associated URL.

I think the cross domain access control referred to in
[2] should also be closely followed where appropriate -
although some of it is very request/response oriented.

This needs to be extended to unrequested messages
that are sent.  So for example, if every message
from sent from a server has an associated set
of allowed origins, then the user-agent can ensure
that the message is not delivered to code from
a non allowed origin.

While it could be a non-trivial expense to have
the list allowable list of origins with every
message -  I see this as a transport concern to
potentially find efficient way (perhaps by
association with  a connection) to optimize this.

So semantically, it is the message that has
the allowed origins - but it may be that those
are transported by association with a connection
or they may be transported with per message
meta data.


cheers















John Fallows wrote:
> Folks,
> 
> As promised, this "Connection Strategy" thread is the first of our
> focused IETF discussions outlined previously.
> 
> o Connection strategy (now)
> o Proxy traversal strategy (next)
> o Wire protocol (after that)
> 
> The overall goal for this thread is to define a connection strategy
> that can be used by future browsers for full-duplex, bidirectional
> communication, while integrating with the browser security model.
> This connection strategy discussion does not cover any details of the
> specific bytes on the wire after the connection has been established,
> and is therefore post-connection protocol agnostic.  Hopefully, the
> connection strategy would be sufficiently general-purpose to apply
> beyond the browser usecase as well.
> 
> I plan to present a discussion of the requirements for the connection
> strategy, my understanding of the available alternatives and a logical
> conclusion based on the preceding analysis.
> 
> The browser security model defines the trust boundary between
> different code served by different "origin" servers.  The origin
> concept is defined by HTML5 [1] as follows:
> 
> "The origin of a resource and the effective script origin of a
> resource are both either opaque identifiers or tuples consisting of a
> scheme component, a host component, a port component, and optionally
> extra data."
> 
> The Cross-Origin Resource Sharing specification [2] relaxes the
> same-origin request constraint by defining an opt-in cross-origin
> communication strategy that uses the "Origin" HTTP header.
> 
> The rationale for relaxing the same-origin request constraint for HTTP
> resources applies equally well to bidirectional communication, which
> seems well-matched by an HTTP-based "Origin" header connection
> strategy.
> 
> There are a number of different bidirectional communication connection
> strategies available, such as:
>   o crossdomain.xml + separate raw TCP connection
>   o HTTP Upgrade in-band to raw TCP
>   o Multiple HTTP requests representing independent upstream and downstream
>   o Multiple HTTP requests representing overlapping upstream and
> downstream (BOSH)
> 
> Are there other connection strategies worth considering here?
> 
> Note: Using a non-HTTP protocol such as XMPP or BEEP to establish
> communication is not a separate connection strategy as it would fall
> under crossdomain.xml with separate TCP connection.
> 
> In-band upgrade from HTTP to raw TCP (remember discussion of specific
> protocol bytes sent over TCP comes later) has some
> potentially-significant security benefits over separate control and
> data channels such as crossdomain.xml.  The concept of domain is
> equivalent to origin but without the port, which can introduce an
> attack vector for virtual hosting environments where different users
> may have control over different ports.  In this case, the trust model
> assumed by the plug-in runtime does not match the trust model enforced
> at the server.  In-band upgrade from HTTP using "Origin" header forces
> these trust models to match scheme, host and port.
> 
> When an in-band HTTP Upgrade is successful, the server responds with a
> 101 Switching Protocols status code, as specified by RFC2616, section
> 10.1.2.
> 
> "The server understands and is willing to comply with the client's
> request, via the Upgrade message header field (section 14.42), for a
> change in the application protocol being used on this connection. The
> server will switch protocols to those defined by the response's
> Upgrade header field immediately after the empty line which terminates
> the 101 response.
> 
> The protocol SHOULD be switched only when it is advantageous to do so.
> For example, switching to a newer version of HTTP is advantageous over
> older versions, and switching to a real-time, synchronous protocol
> might be advantageous when delivering resources that use such
> features."
> 
> Using multiple different HTTP requests to provide full-duplex
> bidirectional communication is a necessary compromise for today's
> browser implementations, and is still subject to the HTTP 2 connection
> limit recommended by RFC2616, section 8.1.4 Practical Considerations
> [3].  A single post-connection TCP stream makes more efficient use of
> the network, and gives us the most flexibility in designing the wire
> protocol framing for future browser implementations, and seems to be
> more general purpose for use by non-browser clients.
> 
> In conclusion, an HTTP Upgrade with Origin header strategy seems to do
> a good job of balancing the requirements.
> 
> Looking forward to a fun and productive discussion.
> 
> Kind Regards,
> John Fallows
> 
> [1] http://dev.w3.org/html5/spec/Overview.html#origin
> [2] http://www.w3.org/TR/access-control/
> [3] http://www.ietf.org/rfc/rfc2616.txt
> 
> --
>> |< Kaazing Corporation >|<
> John Fallows | CTO | +1.650.960.8148
> 888 Villa St, Ste 410 | Mountain View, CA 94041, USA
> _______________________________________________
> hybi mailing list
> hybi@ietf.org
> https://www.ietf.org/mailman/listinfo/hybi


From stpeter@stpeter.im  Tue May  5 08:05:26 2009
Return-Path: <stpeter@stpeter.im>
X-Original-To: hybi@core3.amsl.com
Delivered-To: hybi@core3.amsl.com
Received: from localhost (localhost [127.0.0.1]) by core3.amsl.com (Postfix) with ESMTP id 59A713A6781 for <hybi@core3.amsl.com>; Tue,  5 May 2009 08:05:26 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -0.74
X-Spam-Level: 
X-Spam-Status: No, score=-0.74 tagged_above=-999 required=5 tests=[BAYES_20=-0.74]
Received: from mail.ietf.org ([64.170.98.32]) by localhost (core3.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id FJy04MvJxtkr for <hybi@core3.amsl.com>; Tue,  5 May 2009 08:05:25 -0700 (PDT)
Received: from dizzyd.com (dizzyd.com [207.210.219.225]) by core3.amsl.com (Postfix) with ESMTP id 514553A6D9D for <hybi@ietf.org>; Tue,  5 May 2009 08:05:25 -0700 (PDT)
Received: from dhcp-64-101-72-227.cisco.com (dhcp-64-101-72-227.cisco.com [64.101.72.227]) (Authenticated sender: stpeter) by dizzyd.com (Postfix) with ESMTPSA id B3B6EE800D for <hybi@ietf.org>; Tue,  5 May 2009 09:06:49 -0600 (MDT)
Message-ID: <4A005608.7000709@stpeter.im>
Date: Tue, 05 May 2009 09:06:48 -0600
From: Peter Saint-Andre <stpeter@stpeter.im>
User-Agent: Thunderbird 2.0.0.21 (Macintosh/20090302)
MIME-Version: 1.0
To: hybi@ietf.org
X-Enigmail-Version: 0.95.7
OpenPGP: url=http://www.saint-andre.com/me/stpeter.asc
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 7bit
Subject: [hybi] RestMS?
X-BeenThere: hybi@ietf.org
X-Mailman-Version: 2.1.9
Precedence: list
List-Id: Server-Initiated HTTP <hybi.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/listinfo/hybi>, <mailto:hybi-request@ietf.org?subject=unsubscribe>
List-Archive: <http://www.ietf.org/mail-archive/web/hybi>
List-Post: <mailto:hybi@ietf.org>
List-Help: <mailto:hybi-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/hybi>, <mailto:hybi-request@ietf.org?subject=subscribe>
X-List-Received-Date: Tue, 05 May 2009 15:05:26 -0000

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Does anyone on this list know much about RestMS? It claims to "provide
web applications with enterprise-level messaging via an asynchronous
RESTful interface that works over standard HTTP/HTTPS."

http://www.restms.org/

Peter

- --
Peter Saint-Andre
https://stpeter.im/

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.8 (Darwin)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iEYEARECAAYFAkoAVggACgkQNL8k5A2w/vweWgCePpxhjEAgvBEVCLUETZOxMoOL
htUAoICytIykEkkfmoGFrv9T2KjWJ8a1
=NXjz
-----END PGP SIGNATURE-----

From pieterh@gmail.com  Tue May  5 11:34:33 2009
Return-Path: <pieterh@gmail.com>
X-Original-To: hybi@core3.amsl.com
Delivered-To: hybi@core3.amsl.com
Received: from localhost (localhost [127.0.0.1]) by core3.amsl.com (Postfix) with ESMTP id 710463A691B for <hybi@core3.amsl.com>; Tue,  5 May 2009 11:34:33 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -1.977
X-Spam-Level: 
X-Spam-Status: No, score=-1.977 tagged_above=-999 required=5 tests=[BAYES_00=-2.599, FM_FORGED_GMAIL=0.622]
Received: from mail.ietf.org ([64.170.98.32]) by localhost (core3.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 0cw7TP2sDG7l for <hybi@core3.amsl.com>; Tue,  5 May 2009 11:34:32 -0700 (PDT)
Received: from fg-out-1718.google.com (fg-out-1718.google.com [72.14.220.153]) by core3.amsl.com (Postfix) with ESMTP id 4687428C0F5 for <hybi@ietf.org>; Tue,  5 May 2009 11:34:32 -0700 (PDT)
Received: by fg-out-1718.google.com with SMTP id l26so787905fgb.18 for <hybi@ietf.org>; Tue, 05 May 2009 11:35:56 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:sender:received:from:date :x-google-sender-auth:message-id:subject:to:content-type :content-transfer-encoding; bh=tqUl0wv1jnoU5ZPaGGYp8RYzgu5SdO8W44toQs3bHes=; b=KW0u5TuDJp14Ob47bY0fK/VsQ8wqpdF5ejyinBm6/Smy9YLEKfjSpjYJFF9mqNlEUp qvnt62PxLiwhSVPFj9Nl3D31Tgec/gu92HFDSneUfPlkhdx/3xgTw1aiRDdaJ/kXxlhu pTsuEIqe9mULp24L8PXFfAQCkkfMbYBREAVjU=
DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:sender:from:date:x-google-sender-auth:message-id :subject:to:content-type:content-transfer-encoding; b=kaX3uH2i9h/z5qAzFYwN8GASJZ10aKLZj20wwExgivj7n8VAORAaBEz/8bfSiqlPpd aAvIM3fIZTahYPYwACtRjh6Va1KTC89rxJHhHfSO4u74ynDl0Ufo5NR7Qu9DOcirG4KE uMdO760gJnaur6JyUw00B5Yvm2/m6d/bYDVzg=
MIME-Version: 1.0
Sender: pieterh@gmail.com
Received: by 10.86.95.8 with SMTP id s8mr458382fgb.23.1241548555174; Tue, 05  May 2009 11:35:55 -0700 (PDT)
From: Pieter Hintjens <ph@imatix.com>
Date: Tue, 5 May 2009 20:35:40 +0200
X-Google-Sender-Auth: f4da1057ba588cef
Message-ID: <5821ea240905051135l1de48e9cwece4c5febc26752e@mail.gmail.com>
To: hybi@ietf.org
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: 7bit
Subject: [hybi] Introduction to RestMS
X-BeenThere: hybi@ietf.org
X-Mailman-Version: 2.1.9
Precedence: list
List-Id: Server-Initiated HTTP <hybi.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/listinfo/hybi>, <mailto:hybi-request@ietf.org?subject=unsubscribe>
List-Archive: <http://www.ietf.org/mail-archive/web/hybi>
List-Post: <mailto:hybi@ietf.org>
List-Help: <mailto:hybi-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/hybi>, <mailto:hybi-request@ietf.org?subject=subscribe>
X-List-Received-Date: Tue, 05 May 2009 18:52:21 -0000

Hi Folks,

We may be able to offer some insights into the wire protocol level,
with RestMS[1], and possibly also with AMQP[2], which was one of its
ancestors.

RestMS is a XML-or-JSON-over-REST-over-HTTP protocol that does
asynchronous messaging.  I've written an introduction to RestMS[3]
that explains the idea.  We've been working on the basis of running
code / spec iterations, we're now at the third cycle or so.

Anyhow for HyBi what may be relevant (I've just joined this list so
please forgive my ignorance, the list archives seem incomplete) are
the asynchronous mechanisms:

- asynchronous retrieval using a mechanism we call an "asynclet",
where the server provides a URI for a resource that does not yet
exist, the client retrieves this URI and the server responds when the
resource exists (=arrives, since it's a message)
- asynchronous retrieval of modifications using the
When-Modified-After and When-None-Match headers.  We took the first
from Comet, and added the second to be consistent with conditional
methods.

Cheers,
--
Pieter Hintjens

[1] http://www.restms.org
[2] http://www.amqp.org
[3] http://www.zyre.com/blog:intro-to-restms

From john.fallows@kaazing.com  Tue May  5 18:52:55 2009
Return-Path: <john.fallows@kaazing.com>
X-Original-To: hybi@core3.amsl.com
Delivered-To: hybi@core3.amsl.com
Received: from localhost (localhost [127.0.0.1]) by core3.amsl.com (Postfix) with ESMTP id 77A683A6A40 for <hybi@core3.amsl.com>; Tue,  5 May 2009 18:52:55 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -1.35
X-Spam-Level: 
X-Spam-Status: No, score=-1.35 tagged_above=-999 required=5 tests=[AWL=0.627,  BAYES_00=-2.599, FM_FORGED_GMAIL=0.622]
Received: from mail.ietf.org ([64.170.98.32]) by localhost (core3.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id ku11yV1gnG15 for <hybi@core3.amsl.com>; Tue,  5 May 2009 18:52:53 -0700 (PDT)
Received: from wf-out-1314.google.com (wf-out-1314.google.com [209.85.200.172]) by core3.amsl.com (Postfix) with ESMTP id 956233A6951 for <hybi@ietf.org>; Tue,  5 May 2009 18:52:53 -0700 (PDT)
Received: by wf-out-1314.google.com with SMTP id 29so4254886wff.31 for <hybi@ietf.org>; Tue, 05 May 2009 18:54:18 -0700 (PDT)
MIME-Version: 1.0
Received: by 10.142.147.15 with SMTP id u15mr260187wfd.152.1241574858502; Tue,  05 May 2009 18:54:18 -0700 (PDT)
Date: Tue, 5 May 2009 18:54:18 -0700
Message-ID: <c5b3a7130905051854k45daefb6v46acb29d4365bfe3@mail.gmail.com>
From: John Fallows <john.fallows@kaazing.com>
To: Greg Wilkins <gregw@webtide.com>
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: quoted-printable
Cc: hybi@ietf.org
Subject: Re: [hybi] Connection Strategy
X-BeenThere: hybi@ietf.org
X-Mailman-Version: 2.1.9
Precedence: list
List-Id: Server-Initiated HTTP <hybi.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/listinfo/hybi>, <mailto:hybi-request@ietf.org?subject=unsubscribe>
List-Archive: <http://www.ietf.org/mail-archive/web/hybi>
List-Post: <mailto:hybi@ietf.org>
List-Help: <mailto:hybi-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/hybi>, <mailto:hybi-request@ietf.org?subject=subscribe>
X-List-Received-Date: Wed, 06 May 2009 01:52:55 -0000

Greg,

You've raised some very important divergent points here that really
deserve their own thread, rather than attempting to re-purpose this
one.

Therefore, in the interests of fairness, I respectfully request that
you avoid disrupting this discussion thread which is focused on the
connection strategy for streaming and instead start a new thread for
the upcoming valuable discussion about messaging.

You seem to have some fairly strong opinions about the direction we
should be taking here, but as yet I don't have a clear and concise
understanding of your perspective.  Perhaps you could provide a
concrete proposal for the list to evaluate (in a separate thread) ?

Please realize that I personally understand that messaging is a good
thing, and I also understand that streaming is a good thing, but
trying to have both discussions at once on the same thread is not
helpful in advancing either one.

Kind Regards,
John Fallows

On Mon, May 4, 2009 at 8:51 PM, Greg Wilkins <gregw@webtide.com> wrote:
>
> John,
>
>
> I don't mean to be disruptive to your good attempt to
> bring some order to the wide ranging discussions here....
>
> but...
>
>
> I've relabelled this phase "Message Strategy", because
> I don't think we can assume that connections are the
> starting point of this discussion.
>
>
> The references that you cite discuss origins and cross domain
> as they apply to individual resources - not connections.
> HTTP allows resources from different origins to
> be transported over the same connection (proxies).
>
>
> With HTTP, every client to server message semantically
> has it's own URL, and thus it's own origin/domain.
>
> With WebSocket, there is only a single origin/domain
> that is associated with an entire connection.
>
>
> I don't we should assume either model and should have
> a discussion about which of these (or other models)
> we prefer. =A0Indeed some may advocate streaming rather
> than messaging.
>
> It is a later transport discussion when we can discuss
> how messages might relate to connections etc.
>
> -------------
>
> For my contribution to messaging strategy:
>
>
>
> I advocate messaging over streaming because streamed
> data is essentially small messages at the quantum of bytes
> or bits. =A0 =A0 The arguments for streaming and against messaging
> are essentially transport discussions about the efficiency of
> appropriate framing. =A0So let's defer that discussion (and if
> we have lots of 1 bytes messages, then the framing can be
> designed to match that).
>
>
> I advocate messaging over connection based abstraction
> because making connections a non-transport
> issue can be very limiting.
>
> For example, assuming a single origin per connection limits
> multiplexing and it would not be possible to offload bidirectional
> SSL to dedicated hardware that terminated all the SSL connections
> and forwarded messages to the server over fewer connections.
>
> Another example is a mashup page that contains javascript
> from multiple origins, but all of them wish to establish
> bidirectional communications with the same cross domain.
> If we assume connection semantics, then multiple connections
> will be required to the same server just to convey the
> multiple origins involved.
>
> I'm not opposed to specific transports being developed
> that do allow origin and domain to be assumed for all
> messages on a connection (and thus not have to send them),
> but that is a transport efficiency issue and not something
> that should be part of the central design of the communications
> paradygm.
>
>
>
> I agree with John that the definition of Origin should
> be adopted from his [1] reference. =A0This implies that
> each message has an associated URL.
>
> I think the cross domain access control referred to in
> [2] should also be closely followed where appropriate -
> although some of it is very request/response oriented.
>
> This needs to be extended to unrequested messages
> that are sent. =A0So for example, if every message
> from sent from a server has an associated set
> of allowed origins, then the user-agent can ensure
> that the message is not delivered to code from
> a non allowed origin.
>
> While it could be a non-trivial expense to have
> the list allowable list of origins with every
> message - =A0I see this as a transport concern to
> potentially find efficient way (perhaps by
> association with =A0a connection) to optimize this.
>
> So semantically, it is the message that has
> the allowed origins - but it may be that those
> are transported by association with a connection
> or they may be transported with per message
> meta data.
>
>
> cheers
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
> John Fallows wrote:
>> Folks,
>>
>> As promised, this "Connection Strategy" thread is the first of our
>> focused IETF discussions outlined previously.
>>
>> o Connection strategy (now)
>> o Proxy traversal strategy (next)
>> o Wire protocol (after that)
>>
>> The overall goal for this thread is to define a connection strategy
>> that can be used by future browsers for full-duplex, bidirectional
>> communication, while integrating with the browser security model.
>> This connection strategy discussion does not cover any details of the
>> specific bytes on the wire after the connection has been established,
>> and is therefore post-connection protocol agnostic. =A0Hopefully, the
>> connection strategy would be sufficiently general-purpose to apply
>> beyond the browser usecase as well.
>>
>> I plan to present a discussion of the requirements for the connection
>> strategy, my understanding of the available alternatives and a logical
>> conclusion based on the preceding analysis.
>>
>> The browser security model defines the trust boundary between
>> different code served by different "origin" servers. =A0The origin
>> concept is defined by HTML5 [1] as follows:
>>
>> "The origin of a resource and the effective script origin of a
>> resource are both either opaque identifiers or tuples consisting of a
>> scheme component, a host component, a port component, and optionally
>> extra data."
>>
>> The Cross-Origin Resource Sharing specification [2] relaxes the
>> same-origin request constraint by defining an opt-in cross-origin
>> communication strategy that uses the "Origin" HTTP header.
>>
>> The rationale for relaxing the same-origin request constraint for HTTP
>> resources applies equally well to bidirectional communication, which
>> seems well-matched by an HTTP-based "Origin" header connection
>> strategy.
>>
>> There are a number of different bidirectional communication connection
>> strategies available, such as:
>> =A0 o crossdomain.xml + separate raw TCP connection
>> =A0 o HTTP Upgrade in-band to raw TCP
>> =A0 o Multiple HTTP requests representing independent upstream and downs=
tream
>> =A0 o Multiple HTTP requests representing overlapping upstream and
>> downstream (BOSH)
>>
>> Are there other connection strategies worth considering here?
>>
>> Note: Using a non-HTTP protocol such as XMPP or BEEP to establish
>> communication is not a separate connection strategy as it would fall
>> under crossdomain.xml with separate TCP connection.
>>
>> In-band upgrade from HTTP to raw TCP (remember discussion of specific
>> protocol bytes sent over TCP comes later) has some
>> potentially-significant security benefits over separate control and
>> data channels such as crossdomain.xml. =A0The concept of domain is
>> equivalent to origin but without the port, which can introduce an
>> attack vector for virtual hosting environments where different users
>> may have control over different ports. =A0In this case, the trust model
>> assumed by the plug-in runtime does not match the trust model enforced
>> at the server. =A0In-band upgrade from HTTP using "Origin" header forces
>> these trust models to match scheme, host and port.
>>
>> When an in-band HTTP Upgrade is successful, the server responds with a
>> 101 Switching Protocols status code, as specified by RFC2616, section
>> 10.1.2.
>>
>> "The server understands and is willing to comply with the client's
>> request, via the Upgrade message header field (section 14.42), for a
>> change in the application protocol being used on this connection. The
>> server will switch protocols to those defined by the response's
>> Upgrade header field immediately after the empty line which terminates
>> the 101 response.
>>
>> The protocol SHOULD be switched only when it is advantageous to do so.
>> For example, switching to a newer version of HTTP is advantageous over
>> older versions, and switching to a real-time, synchronous protocol
>> might be advantageous when delivering resources that use such
>> features."
>>
>> Using multiple different HTTP requests to provide full-duplex
>> bidirectional communication is a necessary compromise for today's
>> browser implementations, and is still subject to the HTTP 2 connection
>> limit recommended by RFC2616, section 8.1.4 Practical Considerations
>> [3]. =A0A single post-connection TCP stream makes more efficient use of
>> the network, and gives us the most flexibility in designing the wire
>> protocol framing for future browser implementations, and seems to be
>> more general purpose for use by non-browser clients.
>>
>> In conclusion, an HTTP Upgrade with Origin header strategy seems to do
>> a good job of balancing the requirements.
>>
>> Looking forward to a fun and productive discussion.
>>
>> Kind Regards,
>> John Fallows
>>
>> [1] http://dev.w3.org/html5/spec/Overview.html#origin
>> [2] http://www.w3.org/TR/access-control/
>> [3] http://www.ietf.org/rfc/rfc2616.txt
>>
>> --
>>> |< Kaazing Corporation >|<
>> John Fallows | CTO | +1.650.960.8148
>> 888 Villa St, Ste 410 | Mountain View, CA 94041, USA
>> _______________________________________________
>> hybi mailing list
>> hybi@ietf.org
>> https://www.ietf.org/mailman/listinfo/hybi
>
>



--=20
>|< Kaazing Corporation >|<
John Fallows | CTO | +1.650.960.8148
888 Villa St, Ste 410 | Mountain View, CA 94041, USA

From frank.salim@kaazing.com  Tue May  5 19:21:39 2009
Return-Path: <frank.salim@kaazing.com>
X-Original-To: hybi@core3.amsl.com
Delivered-To: hybi@core3.amsl.com
Received: from localhost (localhost [127.0.0.1]) by core3.amsl.com (Postfix) with ESMTP id E79173A717D for <hybi@core3.amsl.com>; Tue,  5 May 2009 19:21:39 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -1.877
X-Spam-Level: 
X-Spam-Status: No, score=-1.877 tagged_above=-999 required=5 tests=[AWL=0.100,  BAYES_00=-2.599, FM_FORGED_GMAIL=0.622]
Received: from mail.ietf.org ([64.170.98.32]) by localhost (core3.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id yKi-omZ4T4+E for <hybi@core3.amsl.com>; Tue,  5 May 2009 19:21:39 -0700 (PDT)
Received: from wa-out-1112.google.com (wa-out-1112.google.com [209.85.146.183]) by core3.amsl.com (Postfix) with ESMTP id ED6A93A712F for <hybi@ietf.org>; Tue,  5 May 2009 19:21:28 -0700 (PDT)
Received: by wa-out-1112.google.com with SMTP id l35so2006830waf.5 for <hybi@ietf.org>; Tue, 05 May 2009 19:22:54 -0700 (PDT)
MIME-Version: 1.0
Received: by 10.114.149.8 with SMTP id w8mr504493wad.39.1241576574275; Tue, 05  May 2009 19:22:54 -0700 (PDT)
In-Reply-To: <c5b3a7130905051854k45daefb6v46acb29d4365bfe3@mail.gmail.com>
References: <c5b3a7130905051854k45daefb6v46acb29d4365bfe3@mail.gmail.com>
From: Frank Salim <frank.salim@kaazing.com>
Date: Tue, 5 May 2009 19:22:39 -0700
Message-ID: <b7197f6c0905051922x5f84cfck2aead692c7701b31@mail.gmail.com>
To: John Fallows <john.fallows@kaazing.com>
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: quoted-printable
Cc: hybi@ietf.org
Subject: Re: [hybi] Connection Strategy
X-BeenThere: hybi@ietf.org
X-Mailman-Version: 2.1.9
Precedence: list
List-Id: Server-Initiated HTTP <hybi.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/listinfo/hybi>, <mailto:hybi-request@ietf.org?subject=unsubscribe>
List-Archive: <http://www.ietf.org/mail-archive/web/hybi>
List-Post: <mailto:hybi@ietf.org>
List-Help: <mailto:hybi-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/hybi>, <mailto:hybi-request@ietf.org?subject=subscribe>
X-List-Received-Date: Wed, 06 May 2009 02:21:40 -0000

> You seem to have some fairly strong opinions about the direction we
> should be taking here, but as yet I don't have a clear and concise
> understanding of your perspective. =A0Perhaps you could provide a
> concrete proposal for the list to evaluate (in a separate thread) ?

Greg,

What connection strategy do you propose to use in the transport layer?

-Frank

From gregw@webtide.com  Tue May  5 19:32:38 2009
Return-Path: <gregw@webtide.com>
X-Original-To: hybi@core3.amsl.com
Delivered-To: hybi@core3.amsl.com
Received: from localhost (localhost [127.0.0.1]) by core3.amsl.com (Postfix) with ESMTP id 3F3AC3A6DAB for <hybi@core3.amsl.com>; Tue,  5 May 2009 19:32:38 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -2.55
X-Spam-Level: 
X-Spam-Status: No, score=-2.55 tagged_above=-999 required=5 tests=[AWL=0.049,  BAYES_00=-2.599]
Received: from mail.ietf.org ([64.170.98.32]) by localhost (core3.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id DB46E5syplKD for <hybi@core3.amsl.com>; Tue,  5 May 2009 19:32:37 -0700 (PDT)
Received: from yw-out-2324.google.com (yw-out-2324.google.com [74.125.46.28]) by core3.amsl.com (Postfix) with ESMTP id 448013A6D7C for <hybi@ietf.org>; Tue,  5 May 2009 19:32:36 -0700 (PDT)
Received: by yw-out-2324.google.com with SMTP id 3so5690230ywj.49 for <hybi@ietf.org>; Tue, 05 May 2009 19:34:00 -0700 (PDT)
Received: by 10.90.86.10 with SMTP id j10mr622263agb.12.1241577240145; Tue, 05 May 2009 19:34:00 -0700 (PDT)
Received: from ?10.10.1.13? (60-242-119-126.tpgi.com.au [60.242.119.126]) by mx.google.com with ESMTPS id 9sm734107agc.62.2009.05.05.19.33.58 (version=TLSv1/SSLv3 cipher=RC4-MD5); Tue, 05 May 2009 19:33:59 -0700 (PDT)
Message-ID: <4A00F710.6050607@webtide.com>
Date: Wed, 06 May 2009 12:33:52 +1000
From: Greg Wilkins <gregw@webtide.com>
User-Agent: Thunderbird 2.0.0.21 (X11/20090409)
MIME-Version: 1.0
To: John Fallows <john.fallows@kaazing.com>
References: <c5b3a7130905051854k45daefb6v46acb29d4365bfe3@mail.gmail.com>
In-Reply-To: <c5b3a7130905051854k45daefb6v46acb29d4365bfe3@mail.gmail.com>
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: 7bit
Cc: hybi@ietf.org
Subject: [hybi] Message Strategy. Was: Connection Strategy
X-BeenThere: hybi@ietf.org
X-Mailman-Version: 2.1.9
Precedence: list
List-Id: Server-Initiated HTTP <hybi.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/listinfo/hybi>, <mailto:hybi-request@ietf.org?subject=unsubscribe>
List-Archive: <http://www.ietf.org/mail-archive/web/hybi>
List-Post: <mailto:hybi@ietf.org>
List-Help: <mailto:hybi-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/hybi>, <mailto:hybi-request@ietf.org?subject=subscribe>
X-List-Received-Date: Wed, 06 May 2009 02:32:38 -0000

John Fallows wrote:
> Greg,
> 
> You've raised some very important divergent points here that really
> deserve their own thread, rather than attempting to re-purpose this
> one.

Which is why I changed the subject line :)


> Therefore, in the interests of fairness, I respectfully request that
> you avoid disrupting this discussion thread which is focused on the
> connection strategy for streaming and instead start a new thread for
> the upcoming valuable discussion about messaging.
> 
> You seem to have some fairly strong opinions about the direction we
> should be taking here, but as yet I don't have a clear and concise
> understanding of your perspective.  Perhaps you could provide a
> concrete proposal for the list to evaluate (in a separate thread) ?

I definitely have some strong opinions about what problems that
I want solved (eg browser management of connections), but I'm actually
undecided about what is the best technically and practical
solution.

Thus what I'm asking for in this thread is for people to
discuss the message vs streaming issues, as I see that as
fundamental to all further discussions.


For my own part, I can see benefits of both approaches:

For example, we could advocate a standard HTTP upgrade mechanism
that would require proxies/firewalls to support a class of streaming
protocols (kind of like CONNECT now does for SSL or TLS etc.).
Arbitrary protocols such as Websocket, BEEP, XMPP, etc, etc could all
share that upgrade mechanism and much of our work regarding
tunneling proxies/firewalls would be done.



However, I think a pure streaming solution would leave many important
issues unresolved (eg security and connection sharing).
I think that something based around messaging semantics is going to
be much better placed at resolving these issues - even if it does not
open a playing field for arbitrary protocols to compete.

I also think that a message based solution is much better placed
to build apon the experience of other standards (eg mime encapsulation,
HTTP origin security models, etc).


Thus my own current preference is a messaging based solution that aspires
to solve more of the problems that I face with my cometd work.



cheers











From gregw@webtide.com  Tue May  5 20:04:38 2009
Return-Path: <gregw@webtide.com>
X-Original-To: hybi@core3.amsl.com
Delivered-To: hybi@core3.amsl.com
Received: from localhost (localhost [127.0.0.1]) by core3.amsl.com (Postfix) with ESMTP id 4E6643A6D90 for <hybi@core3.amsl.com>; Tue,  5 May 2009 20:04:38 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -2.551
X-Spam-Level: 
X-Spam-Status: No, score=-2.551 tagged_above=-999 required=5 tests=[AWL=0.048,  BAYES_00=-2.599]
Received: from mail.ietf.org ([64.170.98.32]) by localhost (core3.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id E0hjpolglgxs for <hybi@core3.amsl.com>; Tue,  5 May 2009 20:04:37 -0700 (PDT)
Received: from yx-out-2324.google.com (yx-out-2324.google.com [74.125.44.29]) by core3.amsl.com (Postfix) with ESMTP id 40E3A3A6D86 for <hybi@ietf.org>; Tue,  5 May 2009 20:04:37 -0700 (PDT)
Received: by yx-out-2324.google.com with SMTP id 8so5703186yxb.49 for <hybi@ietf.org>; Tue, 05 May 2009 20:06:01 -0700 (PDT)
Received: by 10.90.117.17 with SMTP id p17mr124425agc.21.1241579161590; Tue, 05 May 2009 20:06:01 -0700 (PDT)
Received: from ?10.10.1.13? (60-242-119-126.tpgi.com.au [60.242.119.126]) by mx.google.com with ESMTPS id 20sm13910509agb.25.2009.05.05.20.05.59 (version=TLSv1/SSLv3 cipher=RC4-MD5); Tue, 05 May 2009 20:06:00 -0700 (PDT)
Message-ID: <4A00FE91.4010203@webtide.com>
Date: Wed, 06 May 2009 13:05:53 +1000
From: Greg Wilkins <gregw@webtide.com>
User-Agent: Thunderbird 2.0.0.21 (X11/20090409)
MIME-Version: 1.0
To: Frank Salim <frank.salim@kaazing.com>
References: <c5b3a7130905051854k45daefb6v46acb29d4365bfe3@mail.gmail.com> <b7197f6c0905051922x5f84cfck2aead692c7701b31@mail.gmail.com>
In-Reply-To: <b7197f6c0905051922x5f84cfck2aead692c7701b31@mail.gmail.com>
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: 7bit
Cc: hybi@ietf.org
Subject: Re: [hybi] Connection Strategy
X-BeenThere: hybi@ietf.org
X-Mailman-Version: 2.1.9
Precedence: list
List-Id: Server-Initiated HTTP <hybi.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/listinfo/hybi>, <mailto:hybi-request@ietf.org?subject=unsubscribe>
List-Archive: <http://www.ietf.org/mail-archive/web/hybi>
List-Post: <mailto:hybi@ietf.org>
List-Help: <mailto:hybi-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/hybi>, <mailto:hybi-request@ietf.org?subject=subscribe>
X-List-Received-Date: Wed, 06 May 2009 03:04:38 -0000

Frank Salim wrote:
>> You seem to have some fairly strong opinions about the direction we
>> should be taking here, but as yet I don't have a clear and concise
>> understanding of your perspective.  Perhaps you could provide a
>> concrete proposal for the list to evaluate (in a separate thread) ?
> 
> Greg,
> 
> What connection strategy do you propose to use in the transport layer?


Without the context of a specific messaging system, I'm not exactly sure
I can define a connection strategy.

Firstly we should look to the connection strategies of other
messaging based protocols and see what works and what does not
work for bidirectional communication.  HTTP and BEEP are probably
good places to start.


But broadly speaking,  I believe that connection management should be
transport issue.  Applications that send/receive messages should not
care what connection(s) were used or if those connections are shared
or not (as it is for XHR/HTTP today).

With the exception that the existence of a connection can
often be used to indicate the ability (or lack of ability)
to send/receive messages

So at an application level, perhaps there can be an abstract
conduit/channel/pipe  whose existence and state can be manipulated
and tracked by the application.  Failure of a conduit can be used
to trigger application events.

However, I do not believe that there should be a 1:1 mapping between
such a conduit and a TCP/IP connection.   That should be the job of
the transport and hidden from the application/API.

[ Note that while websocket appears to expose connections
to the application - if that was renamed conduit and decoupled
from a direct relationship to the wire protocol, then I think
the API is not far from what I'm advocating. ]


For addressing and security, I agree with John that the URI and
Origin approach look appropriate.  But we need to consider what
URI and origin mean for bidirectional non request/response communication.
One possible definition is that:

 client to server:    URI is the destination of the message.
                      Origin is of the source client code, but can't be trusted.

 server to client:    URI is the source of the message
                      Origin is the source of the message
                      Accepted-origins constrains the allowed handlers in client


This is somewhat asymmetric, but probably has to be so given
that clients are mostly not addressable (else we would have this
problem) and are not trusted.


Regardless of their exact definitions, I think that address and
origin are attributes of a message (or perhaps of an abstract conduit),
but not attributes of specific connection.

Connections need to be defined so that they can be used
for mixed addressing and origins (eg in the examples I
gave of an SSL aggregation or of mashed up widget connecting
to the same server.   But it would also be good to allow
for less complex (unshared) connections that make the optimization
for a connection carrying once conduit to assume URI and origin
(as websocket currently does).

The key thing is that the application should be unaware which
type of connection is being used.



cheers












From martin.tyler@boo.org  Wed May  6 01:16:59 2009
Return-Path: <martin.tyler@boo.org>
X-Original-To: hybi@core3.amsl.com
Delivered-To: hybi@core3.amsl.com
Received: from localhost (localhost [127.0.0.1]) by core3.amsl.com (Postfix) with ESMTP id C80983A68AC for <hybi@core3.amsl.com>; Wed,  6 May 2009 01:16:59 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -1.976
X-Spam-Level: 
X-Spam-Status: No, score=-1.976 tagged_above=-999 required=5 tests=[BAYES_00=-2.599, FM_FORGED_GMAIL=0.622, HTML_MESSAGE=0.001]
Received: from mail.ietf.org ([64.170.98.32]) by localhost (core3.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id Xp6FcJsd4hTO for <hybi@core3.amsl.com>; Wed,  6 May 2009 01:16:52 -0700 (PDT)
Received: from mail-gx0-f166.google.com (mail-gx0-f166.google.com [209.85.217.166]) by core3.amsl.com (Postfix) with ESMTP id 6FB773A6A9E for <hybi@ietf.org>; Wed,  6 May 2009 01:16:26 -0700 (PDT)
Received: by gxk10 with SMTP id 10so10295842gxk.13 for <hybi@ietf.org>; Wed, 06 May 2009 01:17:50 -0700 (PDT)
MIME-Version: 1.0
Received: by 10.90.93.17 with SMTP id q17mr621921agb.69.1241597870780; Wed, 06  May 2009 01:17:50 -0700 (PDT)
In-Reply-To: <4A00FE91.4010203@webtide.com>
References: <c5b3a7130905051854k45daefb6v46acb29d4365bfe3@mail.gmail.com> <b7197f6c0905051922x5f84cfck2aead692c7701b31@mail.gmail.com> <4A00FE91.4010203@webtide.com>
Date: Wed, 6 May 2009 09:17:50 +0100
Message-ID: <44abafb90905060117n2ad24a5as989cfc70b9571dbc@mail.gmail.com>
From: Martin Tyler <martin.tyler@boo.org>
To: hybi@ietf.org
Content-Type: multipart/alternative; boundary=00163630f3670ab20604693a089d
Subject: Re: [hybi] Connection Strategy
X-BeenThere: hybi@ietf.org
X-Mailman-Version: 2.1.9
Precedence: list
List-Id: Server-Initiated HTTP <hybi.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/listinfo/hybi>, <mailto:hybi-request@ietf.org?subject=unsubscribe>
List-Archive: <http://www.ietf.org/mail-archive/web/hybi>
List-Post: <mailto:hybi@ietf.org>
List-Help: <mailto:hybi-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/hybi>, <mailto:hybi-request@ietf.org?subject=subscribe>
X-List-Received-Date: Wed, 06 May 2009 08:16:59 -0000

--00163630f3670ab20604693a089d
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: 7bit

I can see the benefit of using a single connection for, in your example,
multiple widgets to the same server - but I can also see it complicating
what seems to be a desirable level of simplicity.

It would make server side implementations more complex, which isn't that
difficult for people like you or me Greg, implementing comet servers - but
the 12 year old coder mentioned the other week knocking up a quick WebSocket
app probably doesn't want to think about multiplexing stuff on the server
side.

There are probably reasonably trivial ways to make it optional though.

Another problem could be reconnection strategies, this needs some thought.
The client needs some involvement in this in some cases, so we'd still need
callbacks of some kind. If i remember correctly there is a 'last message id'
in the protocol (or was that something else i was looking at?) - but what if
you reconnect to a different server in a load balanced cluster? the client
might want the ability to do some resubscriptions etc.

Personally, any client or server multiplexing would be handled by libraries
so I don't have any desire for it to be built in - but I would be interested
to see a proposal for it if someone could make it suitably generic and cover
all bases.

Regards
Martin

On Wed, May 6, 2009 at 4:05 AM, Greg Wilkins <gregw@webtide.com> wrote:

> Frank Salim wrote:
> >> You seem to have some fairly strong opinions about the direction we
> >> should be taking here, but as yet I don't have a clear and concise
> >> understanding of your perspective.  Perhaps you could provide a
> >> concrete proposal for the list to evaluate (in a separate thread) ?
> >
> > Greg,
> >
> > What connection strategy do you propose to use in the transport layer?
>
>
> Without the context of a specific messaging system, I'm not exactly sure
> I can define a connection strategy.
>
> Firstly we should look to the connection strategies of other
> messaging based protocols and see what works and what does not
> work for bidirectional communication.  HTTP and BEEP are probably
> good places to start.
>
>
> But broadly speaking,  I believe that connection management should be
> transport issue.  Applications that send/receive messages should not
> care what connection(s) were used or if those connections are shared
> or not (as it is for XHR/HTTP today).
>
> With the exception that the existence of a connection can
> often be used to indicate the ability (or lack of ability)
> to send/receive messages
>
> So at an application level, perhaps there can be an abstract
> conduit/channel/pipe  whose existence and state can be manipulated
> and tracked by the application.  Failure of a conduit can be used
> to trigger application events.
>
> However, I do not believe that there should be a 1:1 mapping between
> such a conduit and a TCP/IP connection.   That should be the job of
> the transport and hidden from the application/API.
>
> [ Note that while websocket appears to expose connections
> to the application - if that was renamed conduit and decoupled
> from a direct relationship to the wire protocol, then I think
> the API is not far from what I'm advocating. ]
>
>
> For addressing and security, I agree with John that the URI and
> Origin approach look appropriate.  But we need to consider what
> URI and origin mean for bidirectional non request/response communication.
> One possible definition is that:
>
>  client to server:    URI is the destination of the message.
>                      Origin is of the source client code, but can't be
> trusted.
>
>  server to client:    URI is the source of the message
>                      Origin is the source of the message
>                      Accepted-origins constrains the allowed handlers in
> client
>
>
> This is somewhat asymmetric, but probably has to be so given
> that clients are mostly not addressable (else we would have this
> problem) and are not trusted.
>
>
> Regardless of their exact definitions, I think that address and
> origin are attributes of a message (or perhaps of an abstract conduit),
> but not attributes of specific connection.
>
> Connections need to be defined so that they can be used
> for mixed addressing and origins (eg in the examples I
> gave of an SSL aggregation or of mashed up widget connecting
> to the same server.   But it would also be good to allow
> for less complex (unshared) connections that make the optimization
> for a connection carrying once conduit to assume URI and origin
> (as websocket currently does).
>
> The key thing is that the application should be unaware which
> type of connection is being used.
>
>
>
> cheers
>
>
>
>
>
>
>
>
>
>
>
> _______________________________________________
> hybi mailing list
> hybi@ietf.org
> https://www.ietf.org/mailman/listinfo/hybi
>

--00163630f3670ab20604693a089d
Content-Type: text/html; charset=ISO-8859-1
Content-Transfer-Encoding: quoted-printable

I can see the benefit of using a single connection for, in your
example, multiple widgets to the same server - but I can also see it
complicating what seems to be a desirable level of simplicity. <br>
<br>
It would make server side implementations more complex, which isn&#39;t
that difficult for people like you or me Greg, implementing comet
servers - but the 12 year old coder mentioned the other week knocking
up a quick WebSocket app probably doesn&#39;t want to think about
multiplexing stuff on the server side.<br>
<br>
There are probably reasonably trivial ways to make it optional though.<br>
<br>
Another problem could be reconnection strategies, this needs some
thought. The client needs some involvement in this in some cases, so
we&#39;d still need callbacks of some kind. If i remember correctly there
is a &#39;last message id&#39; in the protocol (or was that something else =
i
was looking at?) - but what if you reconnect to a different server in a
load balanced cluster? the client might want the ability to do some
resubscriptions etc.<br>
<br>
Personally, any client or server multiplexing would be handled by
libraries so I don&#39;t have any desire for it to be built in - but I
would be interested to see a proposal for it if someone could make it
suitably generic and cover all bases.<br>
<br>
Regards<br>
Martin<br><br><div class=3D"gmail_quote">On Wed, May 6, 2009 at 4:05 AM, Gr=
eg Wilkins <span dir=3D"ltr">&lt;<a href=3D"mailto:gregw@webtide.com" targe=
t=3D"_blank">gregw@webtide.com</a>&gt;</span> wrote:<br>
<blockquote class=3D"gmail_quote" style=3D"border-left: 1px solid rgb(204, =
204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;"><div>Frank Salim =
wrote:<br>
&gt;&gt; You seem to have some fairly strong opinions about the direction w=
e<br>
&gt;&gt; should be taking here, but as yet I don&#39;t have a clear and con=
cise<br>
&gt;&gt; understanding of your perspective. =A0Perhaps you could provide a<=
br>
&gt;&gt; concrete proposal for the list to evaluate (in a separate thread) =
?<br>
&gt;<br>
&gt; Greg,<br>
&gt;<br>
&gt; What connection strategy do you propose to use in the transport layer?=
<br>
<br>
<br>
</div>Without the context of a specific messaging system, I&#39;m not exact=
ly sure<br>
I can define a connection strategy.<br>
<br>
Firstly we should look to the connection strategies of other<br>
messaging based protocols and see what works and what does not<br>
work for bidirectional communication. =A0HTTP and BEEP are probably<br>
good places to start.<br>
<br>
<br>
But broadly speaking, =A0I believe that connection management should be<br>
transport issue. =A0Applications that send/receive messages should not<br>
care what connection(s) were used or if those connections are shared<br>
or not (as it is for XHR/HTTP today).<br>
<br>
With the exception that the existence of a connection can<br>
often be used to indicate the ability (or lack of ability)<br>
to send/receive messages<br>
<br>
So at an application level, perhaps there can be an abstract<br>
conduit/channel/pipe =A0whose existence and state can be manipulated<br>
and tracked by the application. =A0Failure of a conduit can be used<br>
to trigger application events.<br>
<br>
However, I do not believe that there should be a 1:1 mapping between<br>
such a conduit and a TCP/IP connection. =A0 That should be the job of<br>
the transport and hidden from the application/API.<br>
<br>
[ Note that while websocket appears to expose connections<br>
to the application - if that was renamed conduit and decoupled<br>
from a direct relationship to the wire protocol, then I think<br>
the API is not far from what I&#39;m advocating. ]<br>
<br>
<br>
For addressing and security, I agree with John that the URI and<br>
Origin approach look appropriate. =A0But we need to consider what<br>
URI and origin mean for bidirectional non request/response communication.<b=
r>
One possible definition is that:<br>
<br>
=A0client to server: =A0 =A0URI is the destination of the message.<br>
 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0Origin is of the source client =
code, but can&#39;t be trusted.<br>
<br>
=A0server to client: =A0 =A0URI is the source of the message<br>
 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0Origin is the source of the mes=
sage<br>
 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0Accepted-origins constrains the=
 allowed handlers in client<br>
<br>
<br>
This is somewhat asymmetric, but probably has to be so given<br>
that clients are mostly not addressable (else we would have this<br>
problem) and are not trusted.<br>
<br>
<br>
Regardless of their exact definitions, I think that address and<br>
origin are attributes of a message (or perhaps of an abstract conduit),<br>
but not attributes of specific connection.<br>
<br>
Connections need to be defined so that they can be used<br>
for mixed addressing and origins (eg in the examples I<br>
gave of an SSL aggregation or of mashed up widget connecting<br>
to the same server. =A0 But it would also be good to allow<br>
for less complex (unshared) connections that make the optimization<br>
for a connection carrying once conduit to assume URI and origin<br>
(as websocket currently does).<br>
<br>
The key thing is that the application should be unaware which<br>
type of connection is being used.<br>
<br>
<br>
<br>
cheers<br>
<div><div></div><div><br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
_______________________________________________<br>
hybi mailing list<br>
<a href=3D"mailto:hybi@ietf.org" target=3D"_blank">hybi@ietf.org</a><br>
<a href=3D"https://www.ietf.org/mailman/listinfo/hybi" target=3D"_blank">ht=
tps://www.ietf.org/mailman/listinfo/hybi</a><br>
</div></div></blockquote></div><br>

--00163630f3670ab20604693a089d--

From john.fallows@kaazing.com  Wed May  6 12:03:26 2009
Return-Path: <john.fallows@kaazing.com>
X-Original-To: hybi@core3.amsl.com
Delivered-To: hybi@core3.amsl.com
Received: from localhost (localhost [127.0.0.1]) by core3.amsl.com (Postfix) with ESMTP id 5B5EE3A6D61 for <hybi@core3.amsl.com>; Wed,  6 May 2009 12:03:26 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -0.546
X-Spam-Level: 
X-Spam-Status: No, score=-0.546 tagged_above=-999 required=5 tests=[AWL=-0.428, BAYES_20=-0.74, FM_FORGED_GMAIL=0.622]
Received: from mail.ietf.org ([64.170.98.32]) by localhost (core3.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id T+Qe99M6wChf for <hybi@core3.amsl.com>; Wed,  6 May 2009 12:03:25 -0700 (PDT)
Received: from mail-qy0-f127.google.com (mail-qy0-f127.google.com [209.85.221.127]) by core3.amsl.com (Postfix) with ESMTP id CE93328C30F for <hybi@ietf.org>; Wed,  6 May 2009 11:53:58 -0700 (PDT)
Received: by qyk33 with SMTP id 33so505961qyk.29 for <hybi@ietf.org>; Wed, 06 May 2009 11:55:24 -0700 (PDT)
MIME-Version: 1.0
Received: by 10.143.37.20 with SMTP id p20mr761599wfj.207.1241636123834; Wed,  06 May 2009 11:55:23 -0700 (PDT)
In-Reply-To: <4A00F710.6050607@webtide.com>
References: <c5b3a7130905051854k45daefb6v46acb29d4365bfe3@mail.gmail.com> <4A00F710.6050607@webtide.com>
Date: Wed, 6 May 2009 11:55:23 -0700
Message-ID: <c5b3a7130905061155t38f126f4j46036e03ae319205@mail.gmail.com>
From: John Fallows <john.fallows@kaazing.com>
To: Greg Wilkins <gregw@webtide.com>
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: quoted-printable
Cc: hybi@ietf.org
Subject: Re: [hybi] Message Strategy. Was: Connection Strategy
X-BeenThere: hybi@ietf.org
X-Mailman-Version: 2.1.9
Precedence: list
List-Id: Server-Initiated HTTP <hybi.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/listinfo/hybi>, <mailto:hybi-request@ietf.org?subject=unsubscribe>
List-Archive: <http://www.ietf.org/mail-archive/web/hybi>
List-Post: <mailto:hybi@ietf.org>
List-Help: <mailto:hybi-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/hybi>, <mailto:hybi-request@ietf.org?subject=subscribe>
X-List-Received-Date: Wed, 06 May 2009 19:03:26 -0000

Greg,

On Tue, May 5, 2009 at 7:33 PM, Greg Wilkins <gregw@webtide.com> wrote:
> John Fallows wrote:
[snip]
>> You seem to have some fairly strong opinions about the direction we
>> should be taking here, but as yet I don't have a clear and concise
>> understanding of your perspective. =A0Perhaps you could provide a
>> concrete proposal for the list to evaluate (in a separate thread) ?
>
> I definitely have some strong opinions about what problems that
> I want solved (eg browser management of connections), but I'm actually
> undecided about what is the best technically and practical
> solution.

Please define the problem you expect "browser management of
connections" to solve.  For example, what do you anticipate would
break without "browser management of connections"?

> Thus what I'm asking for in this thread is for people to
> discuss the message vs streaming issues, as I see that as
> fundamental to all further discussions.
>
>
> For my own part, I can see benefits of both approaches:
>
> For example, we could advocate a standard HTTP upgrade mechanism
> that would require proxies/firewalls to support a class of streaming
> protocols (kind of like CONNECT now does for SSL or TLS etc.).
> Arbitrary protocols such as Websocket, BEEP, XMPP, etc, etc could all
> share that upgrade mechanism and much of our work regarding
> tunneling proxies/firewalls would be done.

Yes, this is an important idea, especially because it can be achieved
by clarifying existing language in the HTTP/1.1 specification only.
I'm planning to discuss this in more detail as part of the upcoming
"Proxy Traversal Strategy" thread.

> However, I think a pure streaming solution would leave many important
> issues unresolved (eg security and connection sharing).

Even the most advanced messaging protocol with connection sharing
still needs to be able to connect before it can share.  HTTP Upgrade
does a good job of prepending HTTP-based security mechanisms in-band
with existing or future TCP-based messaging protocols that are
designed to share the connection.

> I think that something based around messaging semantics is going to
> be much better placed at resolving these issues - even if it does not
> open a playing field for arbitrary protocols to compete.
>
> I also think that a message based solution is much better placed
> to build apon the experience of other standards (eg mime encapsulation,
> HTTP origin security models, etc).

This sounds like you are advocating we design a new general-purpose
messaging protocol with wire syntax inspired by HTTP, which implies
either HTTP/1.2 or a brand new non-HTTP protocol.  In either case, we
would still need to define a connection strategy that navigates HTTP
proxies, just like we do for the streaming scenario that enables
re-use of existing messaging protocols.

> Thus my own current preference is a messaging based solution that aspires
> to solve more of the problems that I face with my cometd work.

What problems do you face with your cometd work today that could not
be addressed in a future HTML5 browser by using SharedWorker [1] and
HTTP Upgrade with an existing messaging protocol like XMPP, AMQP or
STOMP?

Kind Regards,
John Fallows

[1] http://www.w3.org/TR/workers/#sharedworker
--=20
>|< Kaazing Corporation >|<
John Fallows | CTO | +1.650.960.8148
888 Villa St, Ste 410 | Mountain View, CA 94041, USA

From gregw@webtide.com  Thu May  7 06:36:47 2009
Return-Path: <gregw@webtide.com>
X-Original-To: hybi@core3.amsl.com
Delivered-To: hybi@core3.amsl.com
Received: from localhost (localhost [127.0.0.1]) by core3.amsl.com (Postfix) with ESMTP id 40E8D3A6E6B for <hybi@core3.amsl.com>; Thu,  7 May 2009 06:36:47 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -1.623
X-Spam-Level: 
X-Spam-Status: No, score=-1.623 tagged_above=-999 required=5 tests=[AWL=-0.883, BAYES_20=-0.74]
Received: from mail.ietf.org ([64.170.98.32]) by localhost (core3.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 0m2bMZlXh5zp for <hybi@core3.amsl.com>; Thu,  7 May 2009 06:36:46 -0700 (PDT)
Received: from an-out-0708.google.com (an-out-0708.google.com [209.85.132.249]) by core3.amsl.com (Postfix) with ESMTP id 535DF3A6FD5 for <hybi@ietf.org>; Thu,  7 May 2009 06:36:15 -0700 (PDT)
Received: by an-out-0708.google.com with SMTP id c3so565575ana.4 for <hybi@ietf.org>; Thu, 07 May 2009 06:37:39 -0700 (PDT)
Received: by 10.100.248.16 with SMTP id v16mr5631726anh.60.1241703458949; Thu, 07 May 2009 06:37:38 -0700 (PDT)
Received: from ?10.10.1.13? (60-242-119-126.tpgi.com.au [60.242.119.126]) by mx.google.com with ESMTPS id 1sm203415agb.8.2009.05.07.06.37.36 (version=TLSv1/SSLv3 cipher=RC4-MD5); Thu, 07 May 2009 06:37:38 -0700 (PDT)
Message-ID: <4A02E41C.5060509@webtide.com>
Date: Thu, 07 May 2009 23:37:32 +1000
From: Greg Wilkins <gregw@webtide.com>
User-Agent: Thunderbird 2.0.0.21 (X11/20090409)
MIME-Version: 1.0
To: hybi@ietf.org
References: <c5b3a7130905051854k45daefb6v46acb29d4365bfe3@mail.gmail.com>	 <4A00F710.6050607@webtide.com> <c5b3a7130905061155t38f126f4j46036e03ae319205@mail.gmail.com>
In-Reply-To: <c5b3a7130905061155t38f126f4j46036e03ae319205@mail.gmail.com>
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: 7bit
Subject: Re: [hybi] Message Strategy. Was: Connection Strategy
X-BeenThere: hybi@ietf.org
X-Mailman-Version: 2.1.9
Precedence: list
List-Id: Server-Initiated HTTP <hybi.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/listinfo/hybi>, <mailto:hybi-request@ietf.org?subject=unsubscribe>
List-Archive: <http://www.ietf.org/mail-archive/web/hybi>
List-Post: <mailto:hybi@ietf.org>
List-Help: <mailto:hybi-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/hybi>, <mailto:hybi-request@ietf.org?subject=subscribe>
X-List-Received-Date: Thu, 07 May 2009 13:36:47 -0000

John Fallows wrote:
> Greg,
> 
> On Tue, May 5, 2009 at 7:33 PM, Greg Wilkins <gregw@webtide.com> wrote:
>> John Fallows wrote:
> [snip]
>>> You seem to have some fairly strong opinions about the direction we
>>> should be taking here, but as yet I don't have a clear and concise
>>> understanding of your perspective.  Perhaps you could provide a
>>> concrete proposal for the list to evaluate (in a separate thread) ?
>> I definitely have some strong opinions about what problems that
>> I want solved (eg browser management of connections), but I'm actually
>> undecided about what is the best technically and practical
>> solution.
> 
> Please define the problem you expect "browser management of
> connections" to solve.  For example, what do you anticipate would
> break without "browser management of connections"?


I believe that a browser can do a better job of managing the
secure sharing of connections between widgets, frames, tabs
and windows.

For example, to share a connection to a domain between
widgets that were loaded from several different domains
will need the browser to enforce whatever security model
is adopted.

If this connection sharing was attempted to be implemented
by a SharedWorker, then the security policy is significantly
more complex because the sharing will be performed by
downloaded code rather than trusted browser code.



>> However, I think a pure streaming solution would leave many important
>> issues unresolved (eg security and connection sharing).
> 
> Even the most advanced messaging protocol with connection sharing
> still needs to be able to connect before it can share.  HTTP Upgrade
> does a good job of prepending HTTP-based security mechanisms in-band
> with existing or future TCP-based messaging protocols that are
> designed to share the connection.

I'm not arguing against HTTP upgrade.  I completely agree that
it is a good basis for anything that comes out of these discussions.


The question I'm asking in this thread is do we want to talk
about a message bases, stream based (or connection based)
end to end solution.

If we decide to do messaging end to end, then it opens up the
potential for us to specify and upgrade mechanism that would
allow intermediaries to understand and manipulate those messages
(eg doing aggregation, encryption, multiplexing....)


If we decide to have streams end to end, that what
intermediaries will be able to do without knowing specifics
about a stream.



>> I think that something based around messaging semantics is going to
>> be much better placed at resolving these issues - even if it does not
>> open a playing field for arbitrary protocols to compete.
>>
>> I also think that a message based solution is much better placed
>> to build apon the experience of other standards (eg mime encapsulation,
>> HTTP origin security models, etc).
> 
> This sounds like you are advocating we design a new general-purpose
> messaging protocol with wire syntax inspired by HTTP, which implies
> either HTTP/1.2 or a brand new non-HTTP protocol.  In either case, we
> would still need to define a connection strategy that navigates HTTP
> proxies, just like we do for the streaming scenario that enables
> re-use of existing messaging protocols.

Actually I'm advocating that we define an end to end messaging semantic
that includes message addressing, security and content type.

If that messaging semantic is done well, applications will be able to
be developed against it and will not care what wire protocol or
how many TCP/IP connections are used.

Possible transport solutions would include Websocket style (assumed
content type, address and origin associated with unshared connection),
HTTP long polling, HTTP/1.2, something BEEP like etc.




>> Thus my own current preference is a messaging based solution that aspires
>> to solve more of the problems that I face with my cometd work.
> 
> What problems do you face with your cometd work today that could not
> be addressed in a future HTML5 browser by using SharedWorker [1] and
> HTTP Upgrade with an existing messaging protocol like XMPP, AMQP or
> STOMP?

Secure sharing of limited resources (connections).  I don't
see how a sharedworkers can be a secure broker of messages
from differing origins.

Browsers do an excellent job of secure sharing, pooling, idling,
recycling, retrying, caching, pipeling and proxying HTTP
connections for most normal HTTP usage.  HTTP Long polling
is now stressing this model, but I don't think the solution
should be to make the application responsible for connection
management.


To invert the question to you.  What are the drivers
that you see for the connection state to be exposed to
the application?



regards
















From john.fallows@kaazing.com  Thu May  7 18:22:07 2009
Return-Path: <john.fallows@kaazing.com>
X-Original-To: hybi@core3.amsl.com
Delivered-To: hybi@core3.amsl.com
Received: from localhost (localhost [127.0.0.1]) by core3.amsl.com (Postfix) with ESMTP id 11E7B3A696F for <hybi@core3.amsl.com>; Thu,  7 May 2009 18:22:07 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -1.404
X-Spam-Level: 
X-Spam-Status: No, score=-1.404 tagged_above=-999 required=5 tests=[AWL=0.573,  BAYES_00=-2.599, FM_FORGED_GMAIL=0.622]
Received: from mail.ietf.org ([64.170.98.32]) by localhost (core3.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id lhuCVv41d2uK for <hybi@core3.amsl.com>; Thu,  7 May 2009 18:22:05 -0700 (PDT)
Received: from wf-out-1314.google.com (wf-out-1314.google.com [209.85.200.173]) by core3.amsl.com (Postfix) with ESMTP id 6B8EB3A67E4 for <hybi@ietf.org>; Thu,  7 May 2009 18:22:05 -0700 (PDT)
Received: by wf-out-1314.google.com with SMTP id 29so1045348wff.31 for <hybi@ietf.org>; Thu, 07 May 2009 18:23:31 -0700 (PDT)
MIME-Version: 1.0
Received: by 10.142.230.9 with SMTP id c9mr1414444wfh.101.1241745811547; Thu,  07 May 2009 18:23:31 -0700 (PDT)
In-Reply-To: <4A02E41C.5060509@webtide.com>
References: <c5b3a7130905051854k45daefb6v46acb29d4365bfe3@mail.gmail.com> <4A00F710.6050607@webtide.com> <c5b3a7130905061155t38f126f4j46036e03ae319205@mail.gmail.com> <4A02E41C.5060509@webtide.com>
Date: Thu, 7 May 2009 18:23:31 -0700
Message-ID: <c5b3a7130905071823n3202574bu507df463a66ce070@mail.gmail.com>
From: John Fallows <john.fallows@kaazing.com>
To: Greg Wilkins <gregw@webtide.com>
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: quoted-printable
Cc: hybi@ietf.org
Subject: Re: [hybi] Message Strategy. Was: Connection Strategy
X-BeenThere: hybi@ietf.org
X-Mailman-Version: 2.1.9
Precedence: list
List-Id: Server-Initiated HTTP <hybi.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/listinfo/hybi>, <mailto:hybi-request@ietf.org?subject=unsubscribe>
List-Archive: <http://www.ietf.org/mail-archive/web/hybi>
List-Post: <mailto:hybi@ietf.org>
List-Help: <mailto:hybi-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/hybi>, <mailto:hybi-request@ietf.org?subject=subscribe>
X-List-Received-Date: Fri, 08 May 2009 01:22:07 -0000

On Thu, May 7, 2009 at 6:37 AM, Greg Wilkins <gregw@webtide.com> wrote:
> John Fallows wrote:
>> Greg,
>>
>> On Tue, May 5, 2009 at 7:33 PM, Greg Wilkins <gregw@webtide.com> wrote:
>>> John Fallows wrote:
>> [snip]
>>>> You seem to have some fairly strong opinions about the direction we
>>>> should be taking here, but as yet I don't have a clear and concise
>>>> understanding of your perspective. =A0Perhaps you could provide a
>>>> concrete proposal for the list to evaluate (in a separate thread) ?
>>> I definitely have some strong opinions about what problems that
>>> I want solved (eg browser management of connections), but I'm actually
>>> undecided about what is the best technically and practical
>>> solution.
>>
>> Please define the problem you expect "browser management of
>> connections" to solve. =A0For example, what do you anticipate would
>> break without "browser management of connections"?
>
>
> I believe that a browser can do a better job of managing the
> secure sharing of connections between widgets, frames, tabs
> and windows.
>
> For example, to share a connection to a domain between
> widgets that were loaded from several different domains
> will need the browser to enforce whatever security model
> is adopted.
>
> If this connection sharing was attempted to be implemented
> by a SharedWorker, then the security policy is significantly
> more complex because the sharing will be performed by
> downloaded code rather than trusted browser code.

There are lots of deployed applications, including desktop, mobile and
browser plug-in based that do not have a recommended limit on the
number of raw TCP connections.

There are IETF-recommended connection limitations for HTTP over TCP
that were created for reasons that may not be as relevant in today's
world of streaming HD video over the Internet, as Roy put it.

IMHO, the projection of the HTTP over TCP connection limitation
requirement onto Web-friendly real-time bidirectional connectivity
falls into one of 2 categories:
  a) having many TCP connections is not a problem in practice (yet), or
  b) having many TCP connections is a problem with TCP not HTTP.

If the answer is a) then a stream abstraction that maps to HTTP
Upgrade provides flexibility of protocol choice at both client and
server, and intermediaries can opt-in when they have a first-class
understanding of the Upgrade protocol.  This ability to opt-in is
predicated on the intermediaries understanding of the protocol name in
the Upgrade header.  IANA would likely be a suitable standards
organization to define such a registry.

If the answer is b) then the most straightforward solution would be to
define "multiplexed streams" over TCP because that avoids having to
remap higher layers that already understand how to build on top of a
TCP stream abstraction.

One major problem with "multiplexed streams" over TCP is "head-of-line
blocking" which prevents delivery of chunks within independent
streams.

To clarify, if the TCP stream sent by the server looks effectively like thi=
s:

TCP/IP Packet #1 [Logical Stream A Packet #1]
TCP/IP Packet #2 [Logical Stream B Packet #1]
TCP/IP Packet #3 [Logical Stream A Packet #2]
TCP/IP Packet #4 [Logical Stream A Packet #3]
TCP/IP Packet #5 [Logical Stream B Packet #2]

Then loss and retransmission of Logical Stream B Packet #1 (which is
at head-of-line) blocks delivery of Logical Stream A Packets #2 and #3
even though these packets may have already arrived, awaiting
reassembly in the receiving TCP buffer.

Multiplexing streams over a different protocol peer of TCP and UDP,
such as SST [1], DCCP [2] or SCTP [3] has the potential to maintain
the congestion control benefits of TCP while eliminating the
head-of-line blocking issue without invalidating how existing
protocols are defined to map to a byte stream.

In practice, defining such a stream multiplexing protocol over UDP
instead has a much reduced impact on globally deployed IP
infrastructure.  Perhaps there is an opportunity here for progressive
enhancement over time.

Note: The Flash 10 runtime includes RTMFP [4], which is a proprietary
UDP-based protocol for peer-to-peer connectivity that relies on UDP
hole-punching [5] through firewalls coordinated by a server, similar
to Skype.

>>> However, I think a pure streaming solution would leave many important
>>> issues unresolved (eg security and connection sharing).
>>
>> Even the most advanced messaging protocol with connection sharing
>> still needs to be able to connect before it can share. =A0HTTP Upgrade
>> does a good job of prepending HTTP-based security mechanisms in-band
>> with existing or future TCP-based messaging protocols that are
>> designed to share the connection.
>
> I'm not arguing against HTTP upgrade. =A0I completely agree that
> it is a good basis for anything that comes out of these discussions.

Good.

Revising the HTTP/1.1 specification to provide clarification of proxy
behavior for HTTP Upgrade has definite value.

> The question I'm asking in this thread is do we want to talk
> about a message bases, stream based (or connection based)
> end to end solution.
>
> If we decide to do messaging end to end, then it opens up the
> potential for us to specify and upgrade mechanism that would
> allow intermediaries to understand and manipulate those messages
> (eg doing aggregation, encryption, multiplexing....)
>
>
> If we decide to have streams end to end, that what
> intermediaries will be able to do without knowing specifics
> about a stream.

All of the goals you cite above for a message based solution over TCP
can be addressed more generally and with fewer implementation
constraints by multiplexed byte streams and standard HTTP Upgrade
protocol names.

>>> I think that something based around messaging semantics is going to
>>> be much better placed at resolving these issues - even if it does not
>>> open a playing field for arbitrary protocols to compete.
>>>
>>> I also think that a message based solution is much better placed
>>> to build apon the experience of other standards (eg mime encapsulation,
>>> HTTP origin security models, etc).
>>
>> This sounds like you are advocating we design a new general-purpose
>> messaging protocol with wire syntax inspired by HTTP, which implies
>> either HTTP/1.2 or a brand new non-HTTP protocol. =A0In either case, we
>> would still need to define a connection strategy that navigates HTTP
>> proxies, just like we do for the streaming scenario that enables
>> re-use of existing messaging protocols.
>
> Actually I'm advocating that we define an end to end messaging semantic
> that includes message addressing, security and content type.
>
> If that messaging semantic is done well, applications will be able to
> be developed against it and will not care what wire protocol or
> how many TCP/IP connections are used.
>
> Possible transport solutions would include Websocket style (assumed
> content type, address and origin associated with unshared connection),
> HTTP long polling, HTTP/1.2, something BEEP like etc.

It sounds like you are suggesting we standardize a high-level
messaging API like Java Messaging System (JMS) with a pluggable
transport system, similar to what you have done with Bayeux.

As I understand it, the IETF standardizes protocols, including the
wire syntax and operational semantics of those protocols, but not APIs
or abstract, protocol-independent semantics.

Btw, a subtle but important point - the WebSocket specification
defines how it maps to a stream of bytes, which may be a multiplexed
stream of bytes over a shared TCP connection, or it may map directly
to a physical TCP connection.

>>> Thus my own current preference is a messaging based solution that aspir=
es
>>> to solve more of the problems that I face with my cometd work.
>>
>> What problems do you face with your cometd work today that could not
>> be addressed in a future HTML5 browser by using SharedWorker [1] and
>> HTTP Upgrade with an existing messaging protocol like XMPP, AMQP or
>> STOMP?
>
> Secure sharing of limited resources (connections). =A0I don't
> see how a sharedworkers can be a secure broker of messages
> from differing origins.
>
> Browsers do an excellent job of secure sharing, pooling, idling,
> recycling, retrying, caching, pipeling and proxying HTTP
> connections for most normal HTTP usage. =A0HTTP Long polling
> is now stressing this model, but I don't think the solution
> should be to make the application responsible for connection
> management.

Understood. However making the leap to a message based solution might
be considered unnecessary.

> To invert the question to you. =A0What are the drivers
> that you see for the connection state to be exposed to
> the application?

Our customer base is extremely enthusiastic about extending the reach
and full feature set of their server-side TCP-based protocols to the
browser.  In many cases, they have invented custom protocols used
either by intranet-deployed plug-in technology clients or desktop
clients.

Deploying these or similar applications to the Web always hits a road
block of how to map efficiently to HTTP, as well as the undesirable
implementation effort involved at the Web server to hand-code, debug
and support that mapping, typically resulting in the browser
application being a poor second cousin to the desktop application.

They are looking for the same freedom at the browser client that they
currently enjoy for desktops and servers - namely that the lowest
common denominator is a Socket, which is why they are encouraged by
the arrival of an equivalent concept for Web browsers that can
successfully navigate the HTTP infrastructure of the Web.

Kind Regards,
John Fallows

[1] http://pdos.csail.mit.edu/uia/sst/
[2] http://en.wikipedia.org/wiki/Datagram_Congestion_Control_Protocol
[3] http://en.wikipedia.org/wiki/Stream_Control_Transmission_Protocol
[4] http://en.wikipedia.org/wiki/Real_Time_Media_Flow_Protocol
[5] http://en.wikipedia.org/wiki/UDP_hole_punching

--=20
>|< Kaazing Corporation >|<
John Fallows | CTO | +1.650.960.8148
888 Villa St, Ste 410 | Mountain View, CA 94041, USA

From gregw@webtide.com  Thu May  7 19:49:24 2009
Return-Path: <gregw@webtide.com>
X-Original-To: hybi@core3.amsl.com
Delivered-To: hybi@core3.amsl.com
Received: from localhost (localhost [127.0.0.1]) by core3.amsl.com (Postfix) with ESMTP id 9F8DA3A6C02 for <hybi@core3.amsl.com>; Thu,  7 May 2009 19:49:24 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -2.535
X-Spam-Level: 
X-Spam-Status: No, score=-2.535 tagged_above=-999 required=5 tests=[AWL=0.064,  BAYES_00=-2.599]
Received: from mail.ietf.org ([64.170.98.32]) by localhost (core3.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id S69x1Q1qriNS for <hybi@core3.amsl.com>; Thu,  7 May 2009 19:49:23 -0700 (PDT)
Received: from mail-gx0-f166.google.com (mail-gx0-f166.google.com [209.85.217.166]) by core3.amsl.com (Postfix) with ESMTP id 539FD3A6819 for <hybi@ietf.org>; Thu,  7 May 2009 19:49:23 -0700 (PDT)
Received: by gxk10 with SMTP id 10so2210165gxk.13 for <hybi@ietf.org>; Thu, 07 May 2009 19:50:48 -0700 (PDT)
Received: by 10.90.33.15 with SMTP id g15mr2432882agg.5.1241751047971; Thu, 07 May 2009 19:50:47 -0700 (PDT)
Received: from ?10.10.1.13? (60-242-119-126.tpgi.com.au [60.242.119.126]) by mx.google.com with ESMTPS id 1sm647046agb.8.2009.05.07.19.50.45 (version=TLSv1/SSLv3 cipher=RC4-MD5); Thu, 07 May 2009 19:50:47 -0700 (PDT)
Message-ID: <4A039E02.10901@webtide.com>
Date: Fri, 08 May 2009 12:50:42 +1000
From: Greg Wilkins <gregw@webtide.com>
User-Agent: Thunderbird 2.0.0.21 (X11/20090409)
MIME-Version: 1.0
To: John Fallows <john.fallows@kaazing.com>
References: <c5b3a7130905051854k45daefb6v46acb29d4365bfe3@mail.gmail.com>	 <4A00F710.6050607@webtide.com>	 <c5b3a7130905061155t38f126f4j46036e03ae319205@mail.gmail.com>	 <4A02E41C.5060509@webtide.com> <c5b3a7130905071823n3202574bu507df463a66ce070@mail.gmail.com>
In-Reply-To: <c5b3a7130905071823n3202574bu507df463a66ce070@mail.gmail.com>
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: 7bit
Cc: hybi@ietf.org
Subject: Re: [hybi] Message Strategy. Was: Connection Strategy
X-BeenThere: hybi@ietf.org
X-Mailman-Version: 2.1.9
Precedence: list
List-Id: Server-Initiated HTTP <hybi.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/listinfo/hybi>, <mailto:hybi-request@ietf.org?subject=unsubscribe>
List-Archive: <http://www.ietf.org/mail-archive/web/hybi>
List-Post: <mailto:hybi@ietf.org>
List-Help: <mailto:hybi-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/hybi>, <mailto:hybi-request@ietf.org?subject=subscribe>
X-List-Received-Date: Fri, 08 May 2009 02:49:24 -0000

John Fallows wrote:
> There are lots of deployed applications, including desktop, mobile and
> browser plug-in based that do not have a recommended limit on the
> number of raw TCP connections.
> 
> There are IETF-recommended connection limitations for HTTP over TCP
> that were created for reasons that may not be as relevant in today's
> world of streaming HD video over the Internet, as Roy put it.

As the implementer of a HTTP server, I can definitely say that
limiting HTTP connections is still a significant concern.

With mashups, portlets and widgets, it is easily conceivable
for a web page to have 10's if not 100's of logical connections
to the server.   If we come up with a solution that insist
that each of these is given a dedicated TCP/IP connection,
then there are significant scaling issues at the server side.

We typically would like a server to be able to support
10's of thousands of simultaneous users. If each user needs
10's or hundreds of TCP/IP connections, then we are looking
at approaching a million connections per server!  It only
get's worse for a load balancer!



> One major problem with "multiplexed streams" over TCP is "head-of-line
> blocking" which prevents delivery of chunks within independent
> streams.

Indeed.  There are many difficulties and complexities with multi-plexing

I do not think multi-plexing should be mandatory in any solution and
that simple 1 TCP/IP for 1 use solutions should be available and perhaps
even the norm.

But what I'm saying, is let's not design out the possibility
of multi-plexing by promising a TCP/IP connection in the
application API/contract.


>> Possible transport solutions would include Websocket style (assumed
>> content type, address and origin associated with unshared connection),
>> HTTP long polling, HTTP/1.2, something BEEP like etc.
> 
> It sounds like you are suggesting we standardize a high-level
> messaging API like Java Messaging System (JMS) with a pluggable
> transport system, similar to what you have done with Bayeux.

Not at all.

Currently I would call the current WebSocket API a mix of
message based (onmessage, postMessage) and of connection
based (onopen, onclose, disconnect).

I think these are just about right, but that they are
concerns need to be separated and disassociated from
a specific transport.

Applications will mostly be concerned with postMessage
and onmessage.     Currently websocket associates a URI
and origin with the instance of the Websocket.    I think
that is OK - so long as the websocket represents a logical
connection (I call them conduits) that may be multiplexed.
Currently it represents a real TCP/IP connection with a
definite wire protocol that cannot be multiplexed.

The onopen, onclose connection semantics are also important,
as they can be used to trigger business logic about the
ability or lack of ability to send/receive messages.
But again, this should be abstracted from the association
with a TCP/IP connection.

Initial implementations of such a decoupled API could
be a simple 1:1 mapping to TCP/IP sockets.   But importantly,
by not making the promise that a websocket == TCP/IPsocket, this
allows browsers (or ideally even javascript frameworks)
to implement the conduits with multiplexed connections
if they so wished.


For example, it would be great if a framework could
implement their own sharedworker that could intercept
all conduit creations and manage the multiplexing and
sharing of real connections.

This could also be done by the browser (for cross
domain solutions).


> As I understand it, the IETF standardizes protocols, including the
> wire syntax and operational semantics of those protocols, but not APIs
> or abstract, protocol-independent semantics.

Well while I've discussed it from an API point of view above,
I'm really concerned only about the semantics and not the API
(and would be happy if there was a pure messaging API with a URI
and meta data for every send).

Conversely - I find it strange that the websocket API is
attempting to specify how IETF standards should specify
connection management of protocols.

> Btw, a subtle but important point - the WebSocket specification
> defines how it maps to a stream of bytes, which may be a multiplexed
> stream of bytes over a shared TCP connection, or it may map directly
> to a physical TCP connection.


hmmmm now that would be framing (websocket) over framing(multiplexed
stream) over framing (TCP/IP packets).

That seams a little over complex.


I've already posted a suggestion for the websocket wire protocol
that would define a frame type for mime encoded messages.
Such a frame type could easily be used to support a large
number of different multiplexing schemes and other
useful things (eg gzip compression of datagrams).


>> Browsers do an excellent job of secure sharing, pooling, idling,
>> recycling, retrying, caching, pipeling and proxying HTTP
>> connections for most normal HTTP usage.  HTTP Long polling
>> is now stressing this model, but I don't think the solution
>> should be to make the application responsible for connection
>> management.
> 
> Understood. However making the leap to a message based solution might
> be considered unnecessary.

But websocket is already message based?



>> To invert the question to you.  What are the drivers
>> that you see for the connection state to be exposed to
>> the application?
> 
> Our customer base is extremely enthusiastic about extending the reach
> and full feature set of their server-side TCP-based protocols to the
> browser.  In many cases, they have invented custom protocols used
> either by intranet-deployed plug-in technology clients or desktop
> clients.
> 
> Deploying these or similar applications to the Web always hits a road
> block of how to map efficiently to HTTP, as well as the undesirable
> implementation effort involved at the Web server to hand-code, debug
> and support that mapping, typically resulting in the browser
> application being a poor second cousin to the desktop application.
> 
> They are looking for the same freedom at the browser client that they
> currently enjoy for desktops and servers - namely that the lowest
> common denominator is a Socket, which is why they are encouraged by
> the arrival of an equivalent concept for Web browsers that can
> successfully navigate the HTTP infrastructure of the Web.

But if these needs can be met by the current datagrams
of websocket, why can they not be met by similar datagrams
that are associated with an abstract conduit rather than
a definite TCP/IP socket?

I really don't think we are advocating positions that far
apart.    You are proposing multi-plexed streams to carry
multiple websocket connections.     I'm proposing that perhaps
the websocket framing can be mildly extended so that it
can handle both a non-multiplexed connection or a multiplexed
one.



regards














From john.fallows@kaazing.com  Fri May  8 02:02:13 2009
Return-Path: <john.fallows@kaazing.com>
X-Original-To: hybi@core3.amsl.com
Delivered-To: hybi@core3.amsl.com
Received: from localhost (localhost [127.0.0.1]) by core3.amsl.com (Postfix) with ESMTP id 706DC28C228 for <hybi@core3.amsl.com>; Fri,  8 May 2009 02:02:13 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -1.486
X-Spam-Level: 
X-Spam-Status: No, score=-1.486 tagged_above=-999 required=5 tests=[AWL=0.491,  BAYES_00=-2.599, FM_FORGED_GMAIL=0.622]
Received: from mail.ietf.org ([64.170.98.32]) by localhost (core3.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id NaVTWNRNlSzV for <hybi@core3.amsl.com>; Fri,  8 May 2009 02:02:12 -0700 (PDT)
Received: from wf-out-1314.google.com (wf-out-1314.google.com [209.85.200.175]) by core3.amsl.com (Postfix) with ESMTP id EBD3128C1FE for <hybi@ietf.org>; Fri,  8 May 2009 02:02:11 -0700 (PDT)
Received: by wf-out-1314.google.com with SMTP id 29so1225150wff.31 for <hybi@ietf.org>; Fri, 08 May 2009 02:03:37 -0700 (PDT)
MIME-Version: 1.0
Received: by 10.142.126.6 with SMTP id y6mr1498132wfc.204.1241773417803; Fri,  08 May 2009 02:03:37 -0700 (PDT)
In-Reply-To: <4A039E02.10901@webtide.com>
References: <c5b3a7130905051854k45daefb6v46acb29d4365bfe3@mail.gmail.com> <4A00F710.6050607@webtide.com> <c5b3a7130905061155t38f126f4j46036e03ae319205@mail.gmail.com> <4A02E41C.5060509@webtide.com> <c5b3a7130905071823n3202574bu507df463a66ce070@mail.gmail.com> <4A039E02.10901@webtide.com>
Date: Fri, 8 May 2009 02:03:37 -0700
Message-ID: <c5b3a7130905080203x5ee0a2c1s1f4789dbd8841fb8@mail.gmail.com>
From: John Fallows <john.fallows@kaazing.com>
To: Greg Wilkins <gregw@webtide.com>
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: quoted-printable
Cc: hybi@ietf.org
Subject: Re: [hybi] Message Strategy. Was: Connection Strategy
X-BeenThere: hybi@ietf.org
X-Mailman-Version: 2.1.9
Precedence: list
List-Id: Server-Initiated HTTP <hybi.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/listinfo/hybi>, <mailto:hybi-request@ietf.org?subject=unsubscribe>
List-Archive: <http://www.ietf.org/mail-archive/web/hybi>
List-Post: <mailto:hybi@ietf.org>
List-Help: <mailto:hybi-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/hybi>, <mailto:hybi-request@ietf.org?subject=subscribe>
X-List-Received-Date: Fri, 08 May 2009 09:02:13 -0000

On Thu, May 7, 2009 at 7:50 PM, Greg Wilkins <gregw@webtide.com> wrote:
> John Fallows wrote:
>> There are lots of deployed applications, including desktop, mobile and
>> browser plug-in based that do not have a recommended limit on the
>> number of raw TCP connections.
>>
>> There are IETF-recommended connection limitations for HTTP over TCP
>> that were created for reasons that may not be as relevant in today's
>> world of streaming HD video over the Internet, as Roy put it.
>
> As the implementer of a HTTP server, I can definitely say that
> limiting HTTP connections is still a significant concern.

I'm assuming you meant that _unlimited_ HTTP connections is still a
significant concern - please let me know if I misinterpreted.

Given that HTTP is layered over TCP, which in turn is layered over IP,
there's really no such thing as an HTTP connection, only HTTP traffic
over TCP connections.

If you trace the IP layer wire traffic to compare 10 pipelined HTTP
requests over a single TCP connection versus the same 10 HTTP requests
over 10 TCP connections, then the difference in IP traffic is entirely
caused by the differences at the TCP layer.

Therefore, if there is an issue with having many TCP connections at
the transport layer underneath HTTP, then that problem can be
addressed at the transport layer by providing alternative transport
strategies that maintain the reliable bidirectional byte stream
required by HTTP.

For example, HTTP can operate without any wire syntax changes over a
bidirectional stream in an SCTP association because it maintains the
Socket abstraction providing a reliable bidirectional byte stream.

> With mashups, portlets and widgets, it is easily conceivable
> for a web page to have 10's if not 100's of logical connections
> to the server. =A0 If we come up with a solution that insist
> that each of these is given a dedicated TCP/IP connection,
> then there are significant scaling issues at the server side.

The mashups, portlets and widgets are at such a high level of
abstraction compared to the transport layer (such as TCP/IP) that
there is plenty of opportunity to coordinate in between.

For example, simple stream multiplexing would probably be sufficient
to address TCP connection reuse, but one could also leverage a more
advanced messaging protocol, like AMQP, to act as a message bus shared
by mashups, portlets and widgets displaying data from the same origin.

The display widgets would likely have a pluggable data model, making
AMQP just one example of providing bidirectional data access and
update notification.

> We typically would like a server to be able to support
> 10's of thousands of simultaneous users. If each user needs
> 10's or hundreds of TCP/IP connections, then we are looking
> at approaching a million connections per server! =A0It only
> get's worse for a load balancer!

Developing a Web application that requires 10's or hundreds of
distinct physical TCP/IP connections demonstrates a poor use of
abstraction.  As I said above, there are plenty of opportunities in
the Web application design to solve this more effectively.

The ability of the application to work properly directly affects its
popularity, so even the undesirable scenario of having a
500-connection Web application is entirely self-healing.

>> One major problem with "multiplexed streams" over TCP is "head-of-line
>> blocking" which prevents delivery of chunks within independent
>> streams.
>
> Indeed. =A0There are many difficulties and complexities with multi-plexin=
g

What other difficulties and complexities are you referring to?

> I do not think multi-plexing should be mandatory in any solution and
> that simple 1 TCP/IP for 1 use solutions should be available and perhaps
> even the norm.
>
> But what I'm saying, is let's not design out the possibility
> of multi-plexing by promising a TCP/IP connection in the
> application API/contract.

A reliable bidirectional byte stream contract is sufficient to provide
different transport possibilities, and assuming TCP/IP to begin with
is appropriate.

For example, your favorite TCP-based protocols, like HTTP, FTP, IRC,
AMQP, XMPP, all still work when multiplexed over a single TCP-based
VPN, even though none of those protocols were designed with the VPN
multiplexing protocol in mind.

>>> Possible transport solutions would include Websocket style (assumed
>>> content type, address and origin associated with unshared connection),
>>> HTTP long polling, HTTP/1.2, something BEEP like etc.
>>
>> It sounds like you are suggesting we standardize a high-level
>> messaging API like Java Messaging System (JMS) with a pluggable
>> transport system, similar to what you have done with Bayeux.
>
> Not at all.
>
> Currently I would call the current WebSocket API a mix of
> message based (onmessage, postMessage) and of connection
> based (onopen, onclose, disconnect).
>
> I think these are just about right, but that they are
> concerns need to be separated and disassociated from
> a specific transport.
>
> Applications will mostly be concerned with postMessage
> and onmessage. =A0 =A0 Currently websocket associates a URI
> and origin with the instance of the Websocket. =A0 =A0I think
> that is OK - so long as the websocket represents a logical
> connection (I call them conduits) that may be multiplexed.
> Currently it represents a real TCP/IP connection with a
> definite wire protocol that cannot be multiplexed.

This is incorrect.  WebSocket wire protocol represents a reliable
bidirectional stream of frames (binary or text content) that _can_
easily be multiplexed.

For example, WebSocket wire protocol can operate with unmodified wire
syntax over one of many bidirectional streams in a shared SCTP
association.

> The onopen, onclose connection semantics are also important,
> as they can be used to trigger business logic about the
> ability or lack of ability to send/receive messages.
> But again, this should be abstracted from the association
> with a TCP/IP connection.

The bidirectional stream of (text) frames exposed by the (JavaScript)
WebSocket API is opened and closed, not necessarily the TCP/IP
connection.

> Initial implementations of such a decoupled API could
> be a simple 1:1 mapping to TCP/IP sockets. =A0 But importantly,
> by not making the promise that a websocket =3D=3D TCP/IPsocket, this
> allows browsers (or ideally even javascript frameworks)
> to implement the conduits with multiplexed connections
> if they so wished.

That's right.

> For example, it would be great if a framework could
> implement their own sharedworker that could intercept
> all conduit creations and manage the multiplexing and
> sharing of real connections.

Yes, there is plenty of opportunity for innovation here.

> This could also be done by the browser (for cross
> domain solutions).

Yes, although in practice the intersection of server DNS names and IP
addresses is potentially quite small, so the dominant cross-domain
use-case is more likely to be for intercepting proxies.

>> As I understand it, the IETF standardizes protocols, including the
>> wire syntax and operational semantics of those protocols, but not APIs
>> or abstract, protocol-independent semantics.
>
> Well while I've discussed it from an API point of view above,
> I'm really concerned only about the semantics and not the API
> (and would be happy if there was a pure messaging API with a URI
> and meta data for every send).

Unfortunately, starting with the API semantics adds confusion because
it focuses us on a discussion about which layer of the client
networking stack should be exposed to JavaScript rather than how the
browser as a whole interacts with the network.  As I understand it,
the IETF is much more concerned with the latter, while the W3C is
responsible for selecting an appropriate JavaScript API for developers
to use.

> Conversely - I find it strange that the websocket API is
> attempting to specify how IETF standards should specify
> connection management of protocols.

I think you might have misunderstood the subtle but important point
explained below.

>> Btw, a subtle but important point - the WebSocket specification
>> defines how it maps to a stream of bytes, which may be a multiplexed
>> stream of bytes over a shared TCP connection, or it may map directly
>> to a physical TCP connection.
>
>
> hmmmm now that would be framing (websocket) over framing(multiplexed
> stream) over framing (TCP/IP packets).
>
> That seams a little over complex.

This is just the networking 101 concept of layering, where each layer
depends on the layer below.  The primary benefit is to provide an
abstraction where lower layers can be entirely replaced, impacting
only the single layer directly above, while all other layers above
that remain unchanged.

Bear in mind that we haven't had the "Wire Protocol" discussion thread
yet which might impact the WebSocket protocol text vs. binary framing
syntax.

> I've already posted a suggestion for the websocket wire protocol
> that would define a frame type for mime encoded messages.
> Such a frame type could easily be used to support a large
> number of different multiplexing schemes and other
> useful things (eg gzip compression of datagrams).
>
>
>>> Browsers do an excellent job of secure sharing, pooling, idling,
>>> recycling, retrying, caching, pipeling and proxying HTTP
>>> connections for most normal HTTP usage. =A0HTTP Long polling
>>> is now stressing this model, but I don't think the solution
>>> should be to make the application responsible for connection
>>> management.
>>
>> Understood. However making the leap to a message based solution might
>> be considered unnecessary.
>
> But websocket is already message based?
>

As mentioned above, WebSocket wire protocol is a stream of frames
(text or binary), whereas the WebSocket API is defined to send and
receive only text frames using WebSocket.postMessage() and
WebSocket.onmessage.

Solving the (TCP) multiplexing problem by mixing in aspects of the
(HTTP) protocol running over TCP might be considered a leap that
unnecessarily violates the abstractions provided by the networking
layers.

>>> To invert the question to you. =A0What are the drivers
>>> that you see for the connection state to be exposed to
>>> the application?
>>
>> Our customer base is extremely enthusiastic about extending the reach
>> and full feature set of their server-side TCP-based protocols to the
>> browser. =A0In many cases, they have invented custom protocols used
>> either by intranet-deployed plug-in technology clients or desktop
>> clients.
>>
>> Deploying these or similar applications to the Web always hits a road
>> block of how to map efficiently to HTTP, as well as the undesirable
>> implementation effort involved at the Web server to hand-code, debug
>> and support that mapping, typically resulting in the browser
>> application being a poor second cousin to the desktop application.
>>
>> They are looking for the same freedom at the browser client that they
>> currently enjoy for desktops and servers - namely that the lowest
>> common denominator is a Socket, which is why they are encouraged by
>> the arrival of an equivalent concept for Web browsers that can
>> successfully navigate the HTTP infrastructure of the Web.
>
> But if these needs can be met by the current datagrams
> of websocket, why can they not be met by similar datagrams
> that are associated with an abstract conduit rather than
> a definite TCP/IP socket?

These needs can be met by the currently defined stream of text or
binary frames provided by WebSocket without implying the underlying
network transport in use, although TCP/IP is a reasonable default.

> I really don't think we are advocating positions that far
> apart. =A0 =A0You are proposing multi-plexed streams to carry
> multiple websocket connections. =A0 =A0 I'm proposing that perhaps
> the websocket framing can be mildly extended so that it
> can handle both a non-multiplexed connection or a multiplexed
> one.

Yes, I believe we are starting to think about the problem in a more
similar way.  Now we just need to determine the most appropriate
networking layer to apply some of the remaining design constraints.

Kind Regards,
John Fallows
--=20
>|< Kaazing Corporation >|<
John Fallows | CTO | +1.650.960.8148
888 Villa St, Ste 410 | Mountain View, CA 94041, USA

From gregw@webtide.com  Fri May  8 20:25:34 2009
Return-Path: <gregw@webtide.com>
X-Original-To: hybi@core3.amsl.com
Delivered-To: hybi@core3.amsl.com
Received: from localhost (localhost [127.0.0.1]) by core3.amsl.com (Postfix) with ESMTP id 67F9A28C139 for <hybi@core3.amsl.com>; Fri,  8 May 2009 20:25:34 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -2.536
X-Spam-Level: 
X-Spam-Status: No, score=-2.536 tagged_above=-999 required=5 tests=[AWL=0.063,  BAYES_00=-2.599]
Received: from mail.ietf.org ([64.170.98.32]) by localhost (core3.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id vHD3hojKBD5a for <hybi@core3.amsl.com>; Fri,  8 May 2009 20:25:33 -0700 (PDT)
Received: from mail-gx0-f214.google.com (mail-gx0-f214.google.com [209.85.217.214]) by core3.amsl.com (Postfix) with ESMTP id 4CFD828C116 for <hybi@ietf.org>; Fri,  8 May 2009 20:25:33 -0700 (PDT)
Received: by gxk10 with SMTP id 10so623299gxk.13 for <hybi@ietf.org>; Fri, 08 May 2009 20:27:00 -0700 (PDT)
Received: by 10.90.104.15 with SMTP id b15mr3695791agc.101.1241839620114; Fri, 08 May 2009 20:27:00 -0700 (PDT)
Received: from ?10.10.1.13? (60-242-119-126.tpgi.com.au [60.242.119.126]) by mx.google.com with ESMTPS id 6sm2646453agb.68.2009.05.08.20.26.58 (version=TLSv1/SSLv3 cipher=RC4-MD5); Fri, 08 May 2009 20:26:59 -0700 (PDT)
Message-ID: <4A04F7FB.5050801@webtide.com>
Date: Sat, 09 May 2009 13:26:51 +1000
From: Greg Wilkins <gregw@webtide.com>
User-Agent: Thunderbird 2.0.0.21 (X11/20090409)
MIME-Version: 1.0
To: hybi@ietf.org
References: <c5b3a7130905051854k45daefb6v46acb29d4365bfe3@mail.gmail.com>	 <4A00F710.6050607@webtide.com>	 <c5b3a7130905061155t38f126f4j46036e03ae319205@mail.gmail.com>	 <4A02E41C.5060509@webtide.com>	 <c5b3a7130905071823n3202574bu507df463a66ce070@mail.gmail.com>	 <4A039E02.10901@webtide.com> <c5b3a7130905080203x5ee0a2c1s1f4789dbd8841fb8@mail.gmail.com>
In-Reply-To: <c5b3a7130905080203x5ee0a2c1s1f4789dbd8841fb8@mail.gmail.com>
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: 7bit
Subject: Re: [hybi] Message Strategy. Was: Connection Strategy
X-BeenThere: hybi@ietf.org
X-Mailman-Version: 2.1.9
Precedence: list
List-Id: Server-Initiated HTTP <hybi.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/listinfo/hybi>, <mailto:hybi-request@ietf.org?subject=unsubscribe>
List-Archive: <http://www.ietf.org/mail-archive/web/hybi>
List-Post: <mailto:hybi@ietf.org>
List-Help: <mailto:hybi-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/hybi>, <mailto:hybi-request@ietf.org?subject=subscribe>
X-List-Received-Date: Sat, 09 May 2009 03:25:34 -0000

John Fallows wrote:
> If you trace the IP layer wire traffic to compare 10 pipelined HTTP
> requests over a single TCP connection versus the same 10 HTTP requests
> over 10 TCP connections, then the difference in IP traffic is entirely
> caused by the differences at the TCP layer.

John,

I'm not making up a hypothetical problem.

The number of TCP/IP connections that servers must
terminate *is* already an issue for many using normal
 HTTP long polling


While there is indeed little difference in what is sent
over the wire, there is a differences in the resources
allocated at the server side.  There are kernel data
structures and buffers allocated per connection.

Modern operating systems do a great job of
handling large numbers of TCP/IP connections, but
I do not see that as a reason to unnecessarily
create a situation where an order of magnitude
increase in requirements is possible.


The multiplexing we are talking about is to route
messages to/from various applications components within
the browser process from/to various application components
within the server process.     TCP/IP provides the process to
process addressing and delivery, but to use it to
perform the fine grained routing within each process
strikes to me as mis-appropriation of kernel resources.


You say that websocket wire protocol is easily
multiplexed - but only with SCTP style sockets (more
kernel resources) or with cooperative applications.





> The mashups, portlets and widgets are at such a high level of
> abstraction compared to the transport layer (such as TCP/IP) that
> there is plenty of opportunity to coordinate in between.

Only if we provide the right abstraction that they can
code against.    The current websocket API certainly
does not allow for an SPI or any interception that can
be done by frameworks and/or sharedworkers.

Many web applications are not centrally designed, but are
integrations of the work of many developers.   Portal sites
such as iGoogle allow users to plugin gadgets from 3rd
parties.    In such an environment, it is very hard to
impose a top level design unless there are some good
common abstractions that they are all build on.

Thus it is very important that we establish these
abstractions before progressing the discussion.

To this end rather than pointing out what else
I disagree with in your response, let me highlight
the common ground



> WebSocket wire protocol represents a reliable
> bidirectional stream of frames (binary or text content) 
> ....
> The bidirectional stream of (text) frames exposed by the (JavaScript)
> WebSocket API is opened and closed, not necessarily the TCP/IP
> connection.

Excellent!

However, I think the spec needs to more clearly state this
separation of concerns, but hopefully that will come out of
this process.

[ I also think websocket would benefit from perhaps
defining an SPI so that frameworks and browsers could
implement behaviour below the API level... this could be
used to map the API to a HTTP long poll transport while
waiting for wire protocol support! but that's
not off-topic for here ]


So I think that we agree that the solution we want
will be based on a frame abstraction (what I called
messages), that are abstracted away from any transport.

Do others agree with this as a basis?


Now I think you go further and are advocating
(correct me if I'm wrong) that these frames
be organized into streams and that meta-data (eg
URI and origin) are associated with the stream
rather than the frame.

I agree that this is a good model for many
webapps and allows for both simple application
development and some trivial wire protocol
implementations.


However, I don't agree that this is the only
abstraction that should be supported.

I would like to see optional meta data associated
with each frame. Per frame meta data will allow
the transport of alternative content types (building
on existing mime experience) and will well support
a variety multiplexing solutions.

Thus the abstraction I'd like to see, is one where
meta data can optionally be set on each frame. If
there is no meta data set on an individual frame, then
the meta data for the stream will apply.

This approach would appear to well support both
our points of view.


regards



























From sh@defuze.org  Sat May  9 01:08:23 2009
Return-Path: <sh@defuze.org>
X-Original-To: hybi@core3.amsl.com
Delivered-To: hybi@core3.amsl.com
Received: from localhost (localhost [127.0.0.1]) by core3.amsl.com (Postfix) with ESMTP id 3F07C3A6951 for <hybi@core3.amsl.com>; Sat,  9 May 2009 01:08:23 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -1.928
X-Spam-Level: 
X-Spam-Status: No, score=-1.928 tagged_above=-999 required=5 tests=[AWL=-0.262, BAYES_00=-2.599, IP_NOT_FRIENDLY=0.334, J_CHICKENPOX_24=0.6]
Received: from mail.ietf.org ([64.170.98.32]) by localhost (core3.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id DVNvY-nKdr+0 for <hybi@core3.amsl.com>; Sat,  9 May 2009 01:08:22 -0700 (PDT)
Received: from mail1.webfaction.com (mail1.webfaction.com [67.15.2.85]) by core3.amsl.com (Postfix) with ESMTP id 6B4AA3A6CED for <hybi@ietf.org>; Sat,  9 May 2009 01:08:22 -0700 (PDT)
Received: from [192.168.0.10] (localhost.localdomain [127.0.0.1]) (authenticated bits=0) by mail1.webfaction.com (8.12.11.20060308/8.13.3) with ESMTP id n4989hNQ001524; Sat, 9 May 2009 03:09:50 -0500
Message-ID: <4A053A47.8010001@defuze.org>
Date: Sat, 09 May 2009 10:09:43 +0200
From: Sylvain Hellegouarch <sh@defuze.org>
User-Agent: Thunderbird 2.0.0.21 (X11/20090409)
MIME-Version: 1.0
To: Greg Wilkins <gregw@webtide.com>
References: <c5b3a7130905051854k45daefb6v46acb29d4365bfe3@mail.gmail.com>		<4A00F710.6050607@webtide.com>		<c5b3a7130905061155t38f126f4j46036e03ae319205@mail.gmail.com>		<4A02E41C.5060509@webtide.com>		<c5b3a7130905071823n3202574bu507df463a66ce070@mail.gmail.com>		<4A039E02.10901@webtide.com>	<c5b3a7130905080203x5ee0a2c1s1f4789dbd8841fb8@mail.gmail.com> <4A04F7FB.5050801@webtide.com>
In-Reply-To: <4A04F7FB.5050801@webtide.com>
Content-Type: text/plain; charset=ISO-8859-1; format=flowed
Content-Transfer-Encoding: 8bit
Cc: hybi@ietf.org
Subject: Re: [hybi] Message Strategy. Was: Connection Strategy
X-BeenThere: hybi@ietf.org
X-Mailman-Version: 2.1.9
Precedence: list
List-Id: Server-Initiated HTTP <hybi.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/listinfo/hybi>, <mailto:hybi-request@ietf.org?subject=unsubscribe>
List-Archive: <http://www.ietf.org/mail-archive/web/hybi>
List-Post: <mailto:hybi@ietf.org>
List-Help: <mailto:hybi-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/hybi>, <mailto:hybi-request@ietf.org?subject=subscribe>
X-List-Received-Date: Sat, 09 May 2009 08:08:23 -0000

Greg Wilkins a écrit :
> John Fallows wrote:
>   
>> If you trace the IP layer wire traffic to compare 10 pipelined HTTP
>> requests over a single TCP connection versus the same 10 HTTP requests
>> over 10 TCP connections, then the difference in IP traffic is entirely
>> caused by the differences at the TCP layer.
>>     
>
> John,
>
> I'm not making up a hypothetical problem.
>
> The number of TCP/IP connections that servers must
> terminate *is* already an issue for many using normal
>  HTTP long polling
>
>
> While there is indeed little difference in what is sent
> over the wire, there is a differences in the resources
> allocated at the server side.  There are kernel data
> structures and buffers allocated per connection.
>
> Modern operating systems do a great job of
> handling large numbers of TCP/IP connections, but
> I do not see that as a reason to unnecessarily
> create a situation where an order of magnitude
> increase in requirements is possible.
>   

What happens when the socket is terminated because one component is not 
behaving fairly? Every other components would suffer from it?

>
> The multiplexing we are talking about is to route
> messages to/from various applications components within
> the browser process from/to various application components
> within the server process.     TCP/IP provides the process to
> process addressing and delivery, but to use it to
> perform the fine grained routing within each process
> strikes to me as mis-appropriation of kernel resources.
>
>   

I don't quite see how. Isn't IP+port the right way of doing routing? 
Clients will talk to an application server with a well known protocol 
(XMPP for instance) on a given port. Whether that client lives in a 
browser makes little difference to the routing mechanism, doesn't it?

I wouldn't be surprised if due to complexity in multiplexing we end up 
with reverse proxy on the server side (ala mod_proxy, e.g. mod_ws_proxy) 
that would forward any incoming data to the appropriate application 
server, thus not reducing the amount of resources required.

- Sylvain

From martin.tyler@boo.org  Sat May  9 01:58:01 2009
Return-Path: <martin.tyler@boo.org>
X-Original-To: hybi@core3.amsl.com
Delivered-To: hybi@core3.amsl.com
Received: from localhost (localhost [127.0.0.1]) by core3.amsl.com (Postfix) with ESMTP id 9B2823A6DB2 for <hybi@core3.amsl.com>; Sat,  9 May 2009 01:58:01 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -1.046
X-Spam-Level: 
X-Spam-Status: No, score=-1.046 tagged_above=-999 required=5 tests=[AWL=-0.929, BAYES_20=-0.74, FM_FORGED_GMAIL=0.622, HTML_MESSAGE=0.001]
Received: from mail.ietf.org ([64.170.98.32]) by localhost (core3.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 00enzMx3bCPs for <hybi@core3.amsl.com>; Sat,  9 May 2009 01:58:00 -0700 (PDT)
Received: from mail-gx0-f166.google.com (mail-gx0-f166.google.com [209.85.217.166]) by core3.amsl.com (Postfix) with ESMTP id B87F03A6B71 for <hybi@ietf.org>; Sat,  9 May 2009 01:58:00 -0700 (PDT)
Received: by gxk10 with SMTP id 10so786053gxk.13 for <hybi@ietf.org>; Sat, 09 May 2009 01:59:27 -0700 (PDT)
MIME-Version: 1.0
Received: by 10.90.69.7 with SMTP id r7mr3950051aga.47.1241859567746; Sat, 09  May 2009 01:59:27 -0700 (PDT)
In-Reply-To: <4A053A47.8010001@defuze.org>
References: <c5b3a7130905051854k45daefb6v46acb29d4365bfe3@mail.gmail.com> <4A00F710.6050607@webtide.com> <c5b3a7130905061155t38f126f4j46036e03ae319205@mail.gmail.com> <4A02E41C.5060509@webtide.com> <c5b3a7130905071823n3202574bu507df463a66ce070@mail.gmail.com> <4A039E02.10901@webtide.com> <c5b3a7130905080203x5ee0a2c1s1f4789dbd8841fb8@mail.gmail.com> <4A04F7FB.5050801@webtide.com> <4A053A47.8010001@defuze.org>
Date: Sat, 9 May 2009 09:59:27 +0100
Message-ID: <44abafb90905090159u1f47c88dh8802c9dc5d1c3594@mail.gmail.com>
From: Martin Tyler <martin.tyler@boo.org>
To: hybi@ietf.org
Content-Type: multipart/alternative; boundary=0016363b9222658077046976f6a2
Subject: Re: [hybi] Message Strategy. Was: Connection Strategy
X-BeenThere: hybi@ietf.org
X-Mailman-Version: 2.1.9
Precedence: list
List-Id: Server-Initiated HTTP <hybi.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/listinfo/hybi>, <mailto:hybi-request@ietf.org?subject=unsubscribe>
List-Archive: <http://www.ietf.org/mail-archive/web/hybi>
List-Post: <mailto:hybi@ietf.org>
List-Help: <mailto:hybi-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/hybi>, <mailto:hybi-request@ietf.org?subject=subscribe>
X-List-Received-Date: Sat, 09 May 2009 08:58:01 -0000

--0016363b9222658077046976f6a2
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: 7bit

Sorry for not quoting, it's getting a bit out of order :)

The multiplexing stuff.. I made a comment a few days ago which I don't think
was responded to...

Carrying multiple 'channels' over one socket to maybe allow multiple client
widgets talking to the same server to use the same socket means more
complexity on the server side. Without some kind of common server API for
people to write to this would be prohibitive to people writing simple
WebSocket servers as described a few weeks ago (12 year olds)

The use case mentioned, a number of widgets on a single page... if they are
talking to the same server I would think it is likely that they can use a
client side api to manage the multiplexing. If the widgets are truly totally
separate pieces of software written by different people how likely is it
that they will be talking to the same server?

Maybe we should go into more detail on the use case for
channels/multiplexing being built in? At the moment I cannot see the
scenario where a library on top of websocket couldnt do the job better


Regards
Martin

--0016363b9222658077046976f6a2
Content-Type: text/html; charset=ISO-8859-1
Content-Transfer-Encoding: quoted-printable

Sorry for not quoting, it&#39;s getting a bit out of order :)<br><br>The mu=
ltiplexing stuff.. I made a comment a few days ago which I don&#39;t think =
was responded to...<br><br>Carrying multiple &#39;channels&#39; over one so=
cket to maybe allow multiple client widgets talking to the same server to u=
se the same socket means more complexity on the server side. Without some k=
ind of common server API for people to write to this would be prohibitive t=
o people writing simple WebSocket servers as described a few weeks ago (12 =
year olds)<br>
<br>The use case mentioned, a number of widgets on a single page... if they=
 are talking to the same server I would think it is likely that they can us=
e a client side api to manage the multiplexing. If the widgets are truly to=
tally separate pieces of software written by different people how likely is=
 it that they will be talking to the same server?<br>
<br>Maybe we should go into more detail on the use case for channels/multip=
lexing being built in? At the moment I cannot see the scenario where a libr=
ary on top of websocket couldnt do the job better<br><br><br>Regards<br>
Martin <br>

--0016363b9222658077046976f6a2--

From gregw@webtide.com  Sun May 10 16:11:54 2009
Return-Path: <gregw@webtide.com>
X-Original-To: hybi@core3.amsl.com
Delivered-To: hybi@core3.amsl.com
Received: from localhost (localhost [127.0.0.1]) by core3.amsl.com (Postfix) with ESMTP id 7D6093A68A7 for <hybi@core3.amsl.com>; Sun, 10 May 2009 16:11:54 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -1.237
X-Spam-Level: 
X-Spam-Status: No, score=-1.237 tagged_above=-999 required=5 tests=[AWL=-1.238, BAYES_50=0.001]
Received: from mail.ietf.org ([64.170.98.32]) by localhost (core3.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id aT-1Z0NsfSbF for <hybi@core3.amsl.com>; Sun, 10 May 2009 16:11:53 -0700 (PDT)
Received: from yw-out-2324.google.com (yw-out-2324.google.com [74.125.46.28]) by core3.amsl.com (Postfix) with ESMTP id A6F9C3A687F for <hybi@ietf.org>; Sun, 10 May 2009 16:11:53 -0700 (PDT)
Received: by yw-out-2324.google.com with SMTP id 3so3048451ywj.49 for <hybi@ietf.org>; Sun, 10 May 2009 16:13:22 -0700 (PDT)
Received: by 10.90.69.15 with SMTP id r15mr5560985aga.56.1241997202027; Sun, 10 May 2009 16:13:22 -0700 (PDT)
Received: from ?10.10.1.12? (60-242-119-126.tpgi.com.au [60.242.119.126]) by mx.google.com with ESMTPS id 32sm5935406aga.4.2009.05.10.16.13.19 (version=TLSv1/SSLv3 cipher=RC4-MD5); Sun, 10 May 2009 16:13:21 -0700 (PDT)
Message-ID: <4A075F89.5050806@webtide.com>
Date: Mon, 11 May 2009 09:13:13 +1000
From: Greg Wilkins <gregw@webtide.com>
User-Agent: Thunderbird 2.0.0.21 (X11/20090409)
MIME-Version: 1.0
To: Martin Tyler <martin.tyler@boo.org>
References: <c5b3a7130905051854k45daefb6v46acb29d4365bfe3@mail.gmail.com>	<4A00F710.6050607@webtide.com>	<c5b3a7130905061155t38f126f4j46036e03ae319205@mail.gmail.com>	<4A02E41C.5060509@webtide.com>	<c5b3a7130905071823n3202574bu507df463a66ce070@mail.gmail.com>	<4A039E02.10901@webtide.com>	<c5b3a7130905080203x5ee0a2c1s1f4789dbd8841fb8@mail.gmail.com>	<4A04F7FB.5050801@webtide.com> <4A053A47.8010001@defuze.org> <44abafb90905090159u1f47c88dh8802c9dc5d1c3594@mail.gmail.com>
In-Reply-To: <44abafb90905090159u1f47c88dh8802c9dc5d1c3594@mail.gmail.com>
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: 7bit
Cc: hybi@ietf.org
Subject: Re: [hybi] Message Strategy. Was: Connection Strategy
X-BeenThere: hybi@ietf.org
X-Mailman-Version: 2.1.9
Precedence: list
List-Id: Server-Initiated HTTP <hybi.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/listinfo/hybi>, <mailto:hybi-request@ietf.org?subject=unsubscribe>
List-Archive: <http://www.ietf.org/mail-archive/web/hybi>
List-Post: <mailto:hybi@ietf.org>
List-Help: <mailto:hybi-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/hybi>, <mailto:hybi-request@ietf.org?subject=subscribe>
X-List-Received-Date: Sun, 10 May 2009 23:11:54 -0000

Martin Tyler wrote:

> The use case mentioned, a number of widgets on a single page... if they
> are talking to the same server I would think it is likely that they can
> use a client side api to manage the multiplexing. If the widgets are
> truly totally separate pieces of software written by different people
> how likely is it that they will be talking to the same server?


Consider google and who have the igoogle portal page which allows
third party gadgets to be plugged into the page. They also have a
WS API that those gadgets can currently make ajax requests to, when
they do this, the gadgets share the connection pool from the
browser to the google servers.

If google started providing a comet API on their servers, then all
of a sudden, these 3rd party gadgets would each be having their
own connection and doing their own connection management.


Note also, I don't think we can use the non-existence of a style
of webapp today as evidence that it will not be done in the
future.  Perhaps they do not exist today because it is
simply too hard to do - and that the existence of a better
communications abstraction will make all sorts of new web applications
possible.

> Maybe we should go into more detail on the use case for
> channels/multiplexing being built in? At the moment I cannot see the
> scenario where a library on top of websocket couldnt do the job better

How could a library on top of websocket enforce orgin based security?

How could a library on top of websocket implement a connection sharing
policy for a 3rd pary component written directly to the websocket API?


regards


From ian@hixie.ch  Sun May 10 16:15:14 2009
Return-Path: <ian@hixie.ch>
X-Original-To: hybi@core3.amsl.com
Delivered-To: hybi@core3.amsl.com
Received: from localhost (localhost [127.0.0.1]) by core3.amsl.com (Postfix) with ESMTP id 7D6563A6C1A for <hybi@core3.amsl.com>; Sun, 10 May 2009 16:15:14 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -3.131
X-Spam-Level: 
X-Spam-Status: No, score=-3.131 tagged_above=-999 required=5 tests=[AWL=-0.532, BAYES_00=-2.599]
Received: from mail.ietf.org ([64.170.98.32]) by localhost (core3.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id ihK47iMp0bqK for <hybi@core3.amsl.com>; Sun, 10 May 2009 16:15:13 -0700 (PDT)
Received: from looneymail-a2.g.dreamhost.com (caibbdcaaaaf.dreamhost.com [208.113.200.5]) by core3.amsl.com (Postfix) with ESMTP id 858373A6B65 for <hybi@ietf.org>; Sun, 10 May 2009 16:15:13 -0700 (PDT)
Received: from hixie.dreamhostps.com (hixie.dreamhost.com [208.113.210.27]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by looneymail-a2.g.dreamhost.com (Postfix) with ESMTP id 819E416D320; Sun, 10 May 2009 16:16:32 -0700 (PDT)
Date: Sun, 10 May 2009 23:17:46 +0000 (UTC)
From: Ian Hickson <ian@hixie.ch>
To: Greg Wilkins <gregw@webtide.com>
In-Reply-To: <4A075F89.5050806@webtide.com>
Message-ID: <Pine.LNX.4.62.0905102315041.7824@hixie.dreamhostps.com>
References: <c5b3a7130905051854k45daefb6v46acb29d4365bfe3@mail.gmail.com> <4A00F710.6050607@webtide.com> <c5b3a7130905061155t38f126f4j46036e03ae319205@mail.gmail.com> <4A02E41C.5060509@webtide.com> <c5b3a7130905071823n3202574bu507df463a66ce070@mail.gmail.com> <4A039E02.10901@webtide.com> <c5b3a7130905080203x5ee0a2c1s1f4789dbd8841fb8@mail.gmail.com> <4A04F7FB.5050801@webtide.com> <4A053A47.8010001@defuze.org> <44abafb90905090159u1f47c88dh8802c9dc5d1c3594@mail.gmail.com> <4A075F89.5050806@webtide.com>
Content-Language: en-GB-hixie
Content-Style-Type: text/css
MIME-Version: 1.0
Content-Type: TEXT/PLAIN; charset=US-ASCII
Cc: hybi@ietf.org
Subject: Re: [hybi] Message Strategy. Was: Connection Strategy
X-BeenThere: hybi@ietf.org
X-Mailman-Version: 2.1.9
Precedence: list
List-Id: Server-Initiated HTTP <hybi.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/listinfo/hybi>, <mailto:hybi-request@ietf.org?subject=unsubscribe>
List-Archive: <http://www.ietf.org/mail-archive/web/hybi>
List-Post: <mailto:hybi@ietf.org>
List-Help: <mailto:hybi-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/hybi>, <mailto:hybi-request@ietf.org?subject=subscribe>
X-List-Received-Date: Sun, 10 May 2009 23:15:14 -0000

On Mon, 11 May 2009, Greg Wilkins wrote:
> 
> Consider google and who have the igoogle portal page which allows third 
> party gadgets to be plugged into the page. They also have a WS API that 
> those gadgets can currently make ajax requests to, when they do this, 
> the gadgets share the connection pool from the browser to the google 
> servers.
> 
> If google started providing a comet API on their servers, then all of a 
> sudden, these 3rd party gadgets would each be having their own 
> connection and doing their own connection management.

If we (Google) were to provide an API like this, we would provide an API 
that coallesced the messages into one stream. We wouldn't have each gadget 
opening up their own connection.

-- 
Ian Hickson               U+1047E                )\._.,--....,'``.    fL
http://ln.hixie.ch/       U+263A                /,   _.. \   _\  ;`._ ,.
Things that are impossible just take longer.   `._.-(,_..'--(,_..'`-.;.'

From gregw@webtide.com  Sun May 10 17:24:24 2009
Return-Path: <gregw@webtide.com>
X-Original-To: hybi@core3.amsl.com
Delivered-To: hybi@core3.amsl.com
Received: from localhost (localhost [127.0.0.1]) by core3.amsl.com (Postfix) with ESMTP id 23A3A3A6911 for <hybi@core3.amsl.com>; Sun, 10 May 2009 17:24:24 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -2.215
X-Spam-Level: 
X-Spam-Status: No, score=-2.215 tagged_above=-999 required=5 tests=[AWL=-0.216, BAYES_00=-2.599, J_CHICKENPOX_24=0.6]
Received: from mail.ietf.org ([64.170.98.32]) by localhost (core3.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id UdzHAyo4VWZw for <hybi@core3.amsl.com>; Sun, 10 May 2009 17:24:23 -0700 (PDT)
Received: from mail-gx0-f166.google.com (mail-gx0-f166.google.com [209.85.217.166]) by core3.amsl.com (Postfix) with ESMTP id 2B6B83A68F1 for <hybi@ietf.org>; Sun, 10 May 2009 17:24:23 -0700 (PDT)
Received: by gxk10 with SMTP id 10so2039973gxk.13 for <hybi@ietf.org>; Sun, 10 May 2009 17:25:51 -0700 (PDT)
Received: by 10.90.118.8 with SMTP id q8mr5626407agc.40.1242001550652; Sun, 10 May 2009 17:25:50 -0700 (PDT)
Received: from ?10.10.1.12? (60-242-119-126.tpgi.com.au [60.242.119.126]) by mx.google.com with ESMTPS id 10sm5968278agd.73.2009.05.10.17.25.48 (version=TLSv1/SSLv3 cipher=RC4-MD5); Sun, 10 May 2009 17:25:49 -0700 (PDT)
Message-ID: <4A077085.9020009@webtide.com>
Date: Mon, 11 May 2009 10:25:41 +1000
From: Greg Wilkins <gregw@webtide.com>
User-Agent: Thunderbird 2.0.0.21 (X11/20090409)
MIME-Version: 1.0
To: Sylvain Hellegouarch <sh@defuze.org>, hybi@ietf.org
References: <c5b3a7130905051854k45daefb6v46acb29d4365bfe3@mail.gmail.com>		<4A00F710.6050607@webtide.com>		<c5b3a7130905061155t38f126f4j46036e03ae319205@mail.gmail.com>		<4A02E41C.5060509@webtide.com>		<c5b3a7130905071823n3202574bu507df463a66ce070@mail.gmail.com>		<4A039E02.10901@webtide.com>	<c5b3a7130905080203x5ee0a2c1s1f4789dbd8841fb8@mail.gmail.com> <4A04F7FB.5050801@webtide.com> <4A053A47.8010001@defuze.org>
In-Reply-To: <4A053A47.8010001@defuze.org>
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: 7bit
Subject: Re: [hybi] Message Strategy. Was: Connection Strategy
X-BeenThere: hybi@ietf.org
X-Mailman-Version: 2.1.9
Precedence: list
List-Id: Server-Initiated HTTP <hybi.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/listinfo/hybi>, <mailto:hybi-request@ietf.org?subject=unsubscribe>
List-Archive: <http://www.ietf.org/mail-archive/web/hybi>
List-Post: <mailto:hybi@ietf.org>
List-Help: <mailto:hybi-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/hybi>, <mailto:hybi-request@ietf.org?subject=subscribe>
X-List-Received-Date: Mon, 11 May 2009 00:24:24 -0000

Sylvain Hellegouarch wrote:
> I don't quite see how. Isn't IP+port the right way of doing routing?


HTTP and whatever protocol we are discussing here are
application layer protocols.  IP+port are a transport
address:

 * IP address is a network layer address and identifies a host

 * port is a transport layer concept and identifies a
   service/process == application

 * application layer protocols (eg HTTP) uses
   addition information (eg URI) to identify resources
   within a given service/process/application.

Thus in good layered networking  a socket is
identified by src IP + src port + dest IP + dest port
and represents a connection between applications.

Applications layers should not use a transport
address to identify application resources.  If
they were to do that, then:

 + HTTP would use connection per resource (ok HTTP/0.9 did that!)
 + POP/IMAP would use connection per email
 + X-windows would use a connection per window
 + XMPP would use a connection per conversation
 + BEEP would use a connection per channel
 + Telnet would open a new connection for every command run
 + FTP would use a connection per file (DOH! it does do this, but
   historically it has been a PITA that it does so.  It is
   the exception that proves the rule!)


HTTP/0.9 was indeed a lot simpler to implement than HTTP/1.1
none of those content-length, chunking and pipelining concerns.

If we wanted the efficiency of multiple resources from a
server - the IETF could have said that applications should
use higher level constructs to put multiple resources into
a single connection (eg use multi-part mime).   But that
never happened, because transport sharing is an
application layer concern - not an application concern.

Instead HTTP/1.0 keep-alive and then HTTP/1.1 were developed
to include features that allow a single transport connection
to serve multiple resources.

To argue against supporting multiple resources in bidirectional
communications is paramount to saying that we should go back to
HTTP/0.9 and allow applications develop higher level protocols
(eg multi-part mime) to send back a web page and all it's
resources over a single connection.

Transport sharing should be done in the application layer
protocol and not in the application!




> What happens when the socket is terminated because one component is not
> behaving fairly? Every other components would suffer from it?

I don't see how/why one component would be allowed to terminate a
shared connection - no matter how badly it behaves.

But even if it does, then the connection management software
can re-establish a connection and other state with it.

HTTP clients already do this! They have a pool of connections
to the server - any of which may close at any time for several
good/bad reasons.  The HTTP clients know how to recreate connections
and what requests can be resent and which cannot.

This is a good example of how the application layer protocol
can handle complexities of transient transport failures with
minimal intervention of the application itself.

regards












From gregw@webtide.com  Sun May 10 17:56:25 2009
Return-Path: <gregw@webtide.com>
X-Original-To: hybi@core3.amsl.com
Delivered-To: hybi@core3.amsl.com
Received: from localhost (localhost [127.0.0.1]) by core3.amsl.com (Postfix) with ESMTP id 885FB3A6A2B for <hybi@core3.amsl.com>; Sun, 10 May 2009 17:56:25 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -1.304
X-Spam-Level: 
X-Spam-Status: No, score=-1.304 tagged_above=-999 required=5 tests=[AWL=-1.119, BAYES_40=-0.185]
Received: from mail.ietf.org ([64.170.98.32]) by localhost (core3.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id Q6ZNjCIjcRVG for <hybi@core3.amsl.com>; Sun, 10 May 2009 17:56:24 -0700 (PDT)
Received: from mail-gx0-f166.google.com (mail-gx0-f166.google.com [209.85.217.166]) by core3.amsl.com (Postfix) with ESMTP id 4D1823A6774 for <hybi@ietf.org>; Sun, 10 May 2009 17:56:23 -0700 (PDT)
Received: by gxk10 with SMTP id 10so2061931gxk.13 for <hybi@ietf.org>; Sun, 10 May 2009 17:57:52 -0700 (PDT)
Received: by 10.90.93.17 with SMTP id q17mr5639805agb.78.1242003472260; Sun, 10 May 2009 17:57:52 -0700 (PDT)
Received: from ?10.10.1.12? (60-242-119-126.tpgi.com.au [60.242.119.126]) by mx.google.com with ESMTPS id 6sm6031881agd.72.2009.05.10.17.57.50 (version=TLSv1/SSLv3 cipher=RC4-MD5); Sun, 10 May 2009 17:57:51 -0700 (PDT)
Message-ID: <4A077808.4030406@webtide.com>
Date: Mon, 11 May 2009 10:57:44 +1000
From: Greg Wilkins <gregw@webtide.com>
User-Agent: Thunderbird 2.0.0.21 (X11/20090409)
MIME-Version: 1.0
To: hybi@ietf.org
References: <c5b3a7130905051854k45daefb6v46acb29d4365bfe3@mail.gmail.com> <4A00F710.6050607@webtide.com> <c5b3a7130905061155t38f126f4j46036e03ae319205@mail.gmail.com> <4A02E41C.5060509@webtide.com> <c5b3a7130905071823n3202574bu507df463a66ce070@mail.gmail.com> <4A039E02.10901@webtide.com> <c5b3a7130905080203x5ee0a2c1s1f4789dbd8841fb8@mail.gmail.com> <4A04F7FB.5050801@webtide.com> <4A053A47.8010001@defuze.org> <44abafb90905090159u1f47c88dh8802c9dc5d1c3594@mail.gmail.com> <4A075F89.5050806@webtide.com> <Pine.LNX.4.62.0905102315041.7824@hixie.dreamhostps.com>
In-Reply-To: <Pine.LNX.4.62.0905102315041.7824@hixie.dreamhostps.com>
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: 7bit
Subject: Re: [hybi] Message Strategy. Was: Connection Strategy
X-BeenThere: hybi@ietf.org
X-Mailman-Version: 2.1.9
Precedence: list
List-Id: Server-Initiated HTTP <hybi.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/listinfo/hybi>, <mailto:hybi-request@ietf.org?subject=unsubscribe>
List-Archive: <http://www.ietf.org/mail-archive/web/hybi>
List-Post: <mailto:hybi@ietf.org>
List-Help: <mailto:hybi-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/hybi>, <mailto:hybi-request@ietf.org?subject=subscribe>
X-List-Received-Date: Mon, 11 May 2009 00:56:25 -0000

Ian Hickson wrote:
> If we (Google) were to provide an API like this, we would provide an API 
> that coallesced the messages into one stream. We wouldn't have each gadget 
> opening up their own connection.
> 

Ian

If this was a perfect world and all of us were perfect developers - maybe !
But that is just not how WS software get's developed, deployed and
evolved.

It is the *ENTIRE POINT* of open standard based web service that you
don't have to provide code to the client so that they can access
your services.  You just want to define a restful, SOAP and/or XML-RPC
interface to your service and let the 3rd parties decide if they
want to use jquery, dojo, prototype, java, C#, whatever to talk to it.


I'm acme.com,  I write a cool service for my own web site, using googles
WS apis.  I write my javascript to call those WS apis - but without using
any google JS - i use dojo or jquery to wrap XHR to talk directly to google.

I now decide that I want to wrap up that cool service as a google gadget
for the igoogle page.     I don't want to rewrite the WS code - because it
works fine.  So I put the WS code into the gadget and it talks directly
to the google WS's      Currently because it is based on XHR, the browser
deals with it and shares the HTTP connections with other gadgets for me.

Even if google did provide a javascript library on top of XHR for
some special connection sharing - they have no means to enforce that my
gadget uses it.  Plus they might have licensing restrictions that prevent
me using it on my own website - so I can't use it for both deployments
of my cool service.

But let's say I  did decide to use googles connection sharing library
for my acme.com gadget.   But then my competitor badass.com develops a
gadget that deliberately bypasses the library on the belief that using
their own dedicated connection would give their gadget some performance
gain.  This might even work for a time, at least until I update the
acme.com gadget to do the same thing. Then everybody would have the same
performance,  but the server would have more sockets to deal with and
the network would have less flow/congestion control.   A great lose lose
situation for no gain.

Voluntary sharing of resources is all fine and well, until one
self interested party puts self interest above the collective
good.    I don't know what world you live in, but mine is full
of self interested developers!


regards






























From martin.tyler@boo.org  Mon May 11 01:19:33 2009
Return-Path: <martin.tyler@boo.org>
X-Original-To: hybi@core3.amsl.com
Delivered-To: hybi@core3.amsl.com
Received: from localhost (localhost [127.0.0.1]) by core3.amsl.com (Postfix) with ESMTP id 72D003A67F0 for <hybi@core3.amsl.com>; Mon, 11 May 2009 01:19:33 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -1.33
X-Spam-Level: 
X-Spam-Status: No, score=-1.33 tagged_above=-999 required=5 tests=[AWL=0.646,  BAYES_00=-2.599, FM_FORGED_GMAIL=0.622, HTML_MESSAGE=0.001]
Received: from mail.ietf.org ([64.170.98.32]) by localhost (core3.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id wq7dIZs6ziJ8 for <hybi@core3.amsl.com>; Mon, 11 May 2009 01:19:32 -0700 (PDT)
Received: from yw-out-2324.google.com (yw-out-2324.google.com [74.125.46.30]) by core3.amsl.com (Postfix) with ESMTP id 8259B3A6B79 for <hybi@ietf.org>; Mon, 11 May 2009 01:19:32 -0700 (PDT)
Received: by yw-out-2324.google.com with SMTP id 3so3282646ywj.49 for <hybi@ietf.org>; Mon, 11 May 2009 01:21:00 -0700 (PDT)
MIME-Version: 1.0
Received: by 10.90.101.17 with SMTP id y17mr2552540agb.102.1242030060138; Mon,  11 May 2009 01:21:00 -0700 (PDT)
In-Reply-To: <4A077808.4030406@webtide.com>
References: <c5b3a7130905051854k45daefb6v46acb29d4365bfe3@mail.gmail.com> <c5b3a7130905071823n3202574bu507df463a66ce070@mail.gmail.com> <4A039E02.10901@webtide.com> <c5b3a7130905080203x5ee0a2c1s1f4789dbd8841fb8@mail.gmail.com> <4A04F7FB.5050801@webtide.com> <4A053A47.8010001@defuze.org> <44abafb90905090159u1f47c88dh8802c9dc5d1c3594@mail.gmail.com> <4A075F89.5050806@webtide.com> <Pine.LNX.4.62.0905102315041.7824@hixie.dreamhostps.com> <4A077808.4030406@webtide.com>
Date: Mon, 11 May 2009 09:21:00 +0100
Message-ID: <44abafb90905110121jcd50f43kdd0b1eb92174356e@mail.gmail.com>
From: Martin Tyler <martin.tyler@boo.org>
To: Greg Wilkins <gregw@webtide.com>
Content-Type: multipart/alternative; boundary=001636163d1988f20304699ea8c6
Cc: hybi@ietf.org
Subject: Re: [hybi] Message Strategy. Was: Connection Strategy
X-BeenThere: hybi@ietf.org
X-Mailman-Version: 2.1.9
Precedence: list
List-Id: Server-Initiated HTTP <hybi.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/listinfo/hybi>, <mailto:hybi-request@ietf.org?subject=unsubscribe>
List-Archive: <http://www.ietf.org/mail-archive/web/hybi>
List-Post: <mailto:hybi@ietf.org>
List-Help: <mailto:hybi-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/hybi>, <mailto:hybi-request@ietf.org?subject=subscribe>
X-List-Received-Date: Mon, 11 May 2009 08:19:33 -0000

--001636163d1988f20304699ea8c6
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: 7bit

On Mon, May 11, 2009 at 1:57 AM, Greg Wilkins <gregw@webtide.com> wrote:

>
> It is the *ENTIRE POINT* of open standard based web service that you
> don't have to provide code to the client so that they can access
> your services.  You just want to define a restful, SOAP and/or XML-RPC
> interface to your service and let the 3rd parties decide if they
> want to use jquery, dojo, prototype, java, C#, whatever to talk to it.
>

But if we are multiplexing 'channels' you cant just define a resful/whatever
service, as the server has to multiplex the difference services - which is,
as i touched on before, ok if you use a well developed server which does
that multiplexing for you (exposing a possibly non-standard new interface on
the server?)

i'm not totally against the channels idea, but the server side needs some
thought here too. I've been out of touch for a while, has there been any
work at all in the server side of this in general rather than channels
stuff, eg servlet api or anything else?

--001636163d1988f20304699ea8c6
Content-Type: text/html; charset=ISO-8859-1
Content-Transfer-Encoding: quoted-printable

<br><br><div class=3D"gmail_quote">On Mon, May 11, 2009 at 1:57 AM, Greg Wi=
lkins <span dir=3D"ltr">&lt;<a href=3D"mailto:gregw@webtide.com">gregw@webt=
ide.com</a>&gt;</span> wrote:<br><blockquote class=3D"gmail_quote" style=3D=
"border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padd=
ing-left: 1ex;">
<br>
It is the *ENTIRE POINT* of open standard based web service that you<br>
don&#39;t have to provide code to the client so that they can access<br>
your services. =A0You just want to define a restful, SOAP and/or XML-RPC<br=
>
interface to your service and let the 3rd parties decide if they<br>
want to use jquery, dojo, prototype, java, C#, whatever to talk to it.<br>
</blockquote></div><br>But if we are multiplexing &#39;channels&#39; you ca=
nt just define a resful/whatever service, as the server has to multiplex th=
e difference services - which is, as i touched on before, ok if you use a w=
ell developed server which does that multiplexing for you (exposing a possi=
bly non-standard new interface on the server?)<br>
<br>i&#39;m not totally against the channels idea, but the server side need=
s some thought here too. I&#39;ve been out of touch for a while, has there =
been any work at all in the server side of this in general rather than chan=
nels stuff, eg servlet api or anything else?<br>

--001636163d1988f20304699ea8c6--

From gregw@webtide.com  Mon May 11 03:36:49 2009
Return-Path: <gregw@webtide.com>
X-Original-To: hybi@core3.amsl.com
Delivered-To: hybi@core3.amsl.com
Received: from localhost (localhost [127.0.0.1]) by core3.amsl.com (Postfix) with ESMTP id D79783A69FB for <hybi@core3.amsl.com>; Mon, 11 May 2009 03:36:49 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -2.491
X-Spam-Level: 
X-Spam-Status: No, score=-2.491 tagged_above=-999 required=5 tests=[AWL=0.108,  BAYES_00=-2.599]
Received: from mail.ietf.org ([64.170.98.32]) by localhost (core3.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id ovEBQqBa-35N for <hybi@core3.amsl.com>; Mon, 11 May 2009 03:36:49 -0700 (PDT)
Received: from mail-bw0-f174.google.com (mail-bw0-f174.google.com [209.85.218.174]) by core3.amsl.com (Postfix) with ESMTP id BC2B13A67DD for <hybi@ietf.org>; Mon, 11 May 2009 03:36:48 -0700 (PDT)
Received: by bwz22 with SMTP id 22so2516539bwz.37 for <hybi@ietf.org>; Mon, 11 May 2009 03:38:16 -0700 (PDT)
Received: by 10.204.55.1 with SMTP id s1mr5315924bkg.132.1242038296137; Mon, 11 May 2009 03:38:16 -0700 (PDT)
Received: from ?10.10.1.12? (60-242-119-126.tpgi.com.au [60.242.119.126]) by mx.google.com with ESMTPS id 9sm3818050bwz.51.2009.05.11.03.38.13 (version=TLSv1/SSLv3 cipher=RC4-MD5); Mon, 11 May 2009 03:38:15 -0700 (PDT)
Message-ID: <4A08000C.6060803@webtide.com>
Date: Mon, 11 May 2009 20:38:04 +1000
From: Greg Wilkins <gregw@webtide.com>
User-Agent: Thunderbird 2.0.0.21 (X11/20090409)
MIME-Version: 1.0
To: hybi@ietf.org
References: <c5b3a7130905051854k45daefb6v46acb29d4365bfe3@mail.gmail.com>	 <c5b3a7130905071823n3202574bu507df463a66ce070@mail.gmail.com>	 <4A039E02.10901@webtide.com>	 <c5b3a7130905080203x5ee0a2c1s1f4789dbd8841fb8@mail.gmail.com>	 <4A04F7FB.5050801@webtide.com> <4A053A47.8010001@defuze.org>	 <44abafb90905090159u1f47c88dh8802c9dc5d1c3594@mail.gmail.com>	 <4A075F89.5050806@webtide.com>	 <Pine.LNX.4.62.0905102315041.7824@hixie.dreamhostps.com>	 <4A077808.4030406@webtide.com> <44abafb90905110121jcd50f43kdd0b1eb92174356e@mail.gmail.com>
In-Reply-To: <44abafb90905110121jcd50f43kdd0b1eb92174356e@mail.gmail.com>
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: 7bit
Subject: Re: [hybi] Message Strategy. Was: Connection Strategy
X-BeenThere: hybi@ietf.org
X-Mailman-Version: 2.1.9
Precedence: list
List-Id: Server-Initiated HTTP <hybi.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/listinfo/hybi>, <mailto:hybi-request@ietf.org?subject=unsubscribe>
List-Archive: <http://www.ietf.org/mail-archive/web/hybi>
List-Post: <mailto:hybi@ietf.org>
List-Help: <mailto:hybi-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/hybi>, <mailto:hybi-request@ietf.org?subject=subscribe>
X-List-Received-Date: Mon, 11 May 2009 10:36:49 -0000

Martin Tyler wrote:
> 
> 
> On Mon, May 11, 2009 at 1:57 AM, Greg Wilkins <gregw@webtide.com
> <mailto:gregw@webtide.com>> wrote:
> 
> 
>     It is the *ENTIRE POINT* of open standard based web service that you
>     don't have to provide code to the client so that they can access
>     your services.  You just want to define a restful, SOAP and/or XML-RPC
>     interface to your service and let the 3rd parties decide if they
>     want to use jquery, dojo, prototype, java, C#, whatever to talk to it.
> 
> 
> But if we are multiplexing 'channels' you cant just define a
> resful/whatever service, as the server has to multiplex the difference
> services.

Martin,

I don't understand your point.  Can you explain some more?


To expand on my thoughts on this matter, consider if the google
server provides several cometd services at the following URIs

  /gcomet/newsAlerts
  /gcomet/stockPrices
  /gcomet/twitters


A simple client could open a HTTP connection to any of those
URIs and upgrade to to the bidirectional protocol.  Each connection
would then be associated with a single URI and datagrams
sent/received would be to/from that URI and they could be
framed without any meta data. 3 connections would
be used to connect to all 3 feeds.

But a more sophisticated client could connect to /gcomet
and upgrade to the bidirectional protocol.  It could then
send some control datagrams (using meta data associated
with the datagrams to indicate they are control messages)
which registered interest in the 3 URIs.   Datagrams
could be sent/received over that connection, but each would
need to have associated meta-data to indicate which of
the URIs the message was to/from.



regards












From martin.tyler@boo.org  Mon May 11 03:56:38 2009
Return-Path: <martin.tyler@boo.org>
X-Original-To: hybi@core3.amsl.com
Delivered-To: hybi@core3.amsl.com
Received: from localhost (localhost [127.0.0.1]) by core3.amsl.com (Postfix) with ESMTP id 6F7D63A6B3F for <hybi@core3.amsl.com>; Mon, 11 May 2009 03:56:38 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -1.666
X-Spam-Level: 
X-Spam-Status: No, score=-1.666 tagged_above=-999 required=5 tests=[AWL=0.310,  BAYES_00=-2.599, FM_FORGED_GMAIL=0.622, HTML_MESSAGE=0.001]
Received: from mail.ietf.org ([64.170.98.32]) by localhost (core3.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id TGD7UfG5SlgD for <hybi@core3.amsl.com>; Mon, 11 May 2009 03:56:37 -0700 (PDT)
Received: from mail-gx0-f166.google.com (mail-gx0-f166.google.com [209.85.217.166]) by core3.amsl.com (Postfix) with ESMTP id 295463A69FB for <hybi@ietf.org>; Mon, 11 May 2009 03:56:36 -0700 (PDT)
Received: by gxk10 with SMTP id 10so2424899gxk.13 for <hybi@ietf.org>; Mon, 11 May 2009 03:58:05 -0700 (PDT)
MIME-Version: 1.0
Received: by 10.90.118.19 with SMTP id q19mr2222717agc.89.1242039485187; Mon,  11 May 2009 03:58:05 -0700 (PDT)
In-Reply-To: <4A08000C.6060803@webtide.com>
References: <c5b3a7130905051854k45daefb6v46acb29d4365bfe3@mail.gmail.com> <c5b3a7130905080203x5ee0a2c1s1f4789dbd8841fb8@mail.gmail.com> <4A04F7FB.5050801@webtide.com> <4A053A47.8010001@defuze.org> <44abafb90905090159u1f47c88dh8802c9dc5d1c3594@mail.gmail.com> <4A075F89.5050806@webtide.com> <Pine.LNX.4.62.0905102315041.7824@hixie.dreamhostps.com> <4A077808.4030406@webtide.com> <44abafb90905110121jcd50f43kdd0b1eb92174356e@mail.gmail.com> <4A08000C.6060803@webtide.com>
Date: Mon, 11 May 2009 11:58:05 +0100
Message-ID: <44abafb90905110358v244560a5iffe1103ac930b027@mail.gmail.com>
From: Martin Tyler <martin.tyler@boo.org>
To: hybi@ietf.org
Content-Type: multipart/alternative; boundary=0016361e88c64fca290469a0daa7
Subject: Re: [hybi] Message Strategy. Was: Connection Strategy
X-BeenThere: hybi@ietf.org
X-Mailman-Version: 2.1.9
Precedence: list
List-Id: Server-Initiated HTTP <hybi.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/listinfo/hybi>, <mailto:hybi-request@ietf.org?subject=unsubscribe>
List-Archive: <http://www.ietf.org/mail-archive/web/hybi>
List-Post: <mailto:hybi@ietf.org>
List-Help: <mailto:hybi-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/hybi>, <mailto:hybi-request@ietf.org?subject=subscribe>
X-List-Received-Date: Mon, 11 May 2009 10:56:38 -0000

--0016361e88c64fca290469a0daa7
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: 7bit

On Mon, May 11, 2009 at 11:38 AM, Greg Wilkins <gregw@webtide.com> wrote:

> Martin Tyler wrote:
> >
> >
> > On Mon, May 11, 2009 at 1:57 AM, Greg Wilkins <gregw@webtide.com
> > <mailto:gregw@webtide.com>> wrote:
> >
> >
> >     It is the *ENTIRE POINT* of open standard based web service that you
> >     don't have to provide code to the client so that they can access
> >     your services.  You just want to define a restful, SOAP and/or
> XML-RPC
> >     interface to your service and let the 3rd parties decide if they
> >     want to use jquery, dojo, prototype, java, C#, whatever to talk to
> it.
> >
> >
> > But if we are multiplexing 'channels' you cant just define a
> > resful/whatever service, as the server has to multiplex the difference
> > services.
>
> Martin,
>
> I don't understand your point.  Can you explain some more?
>
>
> To expand on my thoughts on this matter, consider if the google
> server provides several cometd services at the following URIs
>
>  /gcomet/newsAlerts
>  /gcomet/stockPrices
>  /gcomet/twitters
>
>
> A simple client could open a HTTP connection to any of those
> URIs and upgrade to to the bidirectional protocol.  Each connection
> would then be associated with a single URI and datagrams
> sent/received would be to/from that URI and they could be
> framed without any meta data. 3 connections would
> be used to connect to all 3 feeds.
>
> But a more sophisticated client could connect to /gcomet
> and upgrade to the bidirectional protocol.  It could then
> send some control datagrams (using meta data associated
> with the datagrams to indicate they are control messages)
> which registered interest in the 3 URIs.   Datagrams
> could be sent/received over that connection, but each would
> need to have associated meta-data to indicate which of
> the URIs the message was to/from.
>
>
I am thinking of the server side implementations of these services. If they
are, for example, developed by different developers/teams it would be hard
to do that in isolation from each other without something on the server
handling these meta data messages and routing the data to the write server
side component. This dispatching of messages to the right service would need
an API or server side development is not going to be very modular.

You are suggesting the browser does the equivalent on the client side, which
fits well and as you point out means widget developers don't have to worry
too much about it or make sure they use the correct wrapper libraries etc.
However, on the server side there is a lot more software around, a lot more
custom implementations - some of which have APIs for existing things of
course, CGI, servlets etc, and they would need to handle this multiplexing.

So in your example, someone needs to be able to implement the
/gcomet/stockPrices server service without knowing that there is a
/gcomet/twitters service and that a client might be accessing
/gcomet/stockPrices via a common /gcomet connection

--0016361e88c64fca290469a0daa7
Content-Type: text/html; charset=ISO-8859-1
Content-Transfer-Encoding: quoted-printable

<br><br><div class=3D"gmail_quote">On Mon, May 11, 2009 at 11:38 AM, Greg W=
ilkins <span dir=3D"ltr">&lt;<a href=3D"mailto:gregw@webtide.com">gregw@web=
tide.com</a>&gt;</span> wrote:<br><blockquote class=3D"gmail_quote" style=
=3D"border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; p=
adding-left: 1ex;">
<div class=3D"im">Martin Tyler wrote:<br>
&gt;<br>
&gt;<br>
&gt; On Mon, May 11, 2009 at 1:57 AM, Greg Wilkins &lt;<a href=3D"mailto:gr=
egw@webtide.com">gregw@webtide.com</a><br>
</div><div class=3D"im">&gt; &lt;mailto:<a href=3D"mailto:gregw@webtide.com=
">gregw@webtide.com</a>&gt;&gt; wrote:<br>
&gt;<br>
&gt;<br>
&gt; =A0 =A0 It is the *ENTIRE POINT* of open standard based web service th=
at you<br>
&gt; =A0 =A0 don&#39;t have to provide code to the client so that they can =
access<br>
&gt; =A0 =A0 your services. =A0You just want to define a restful, SOAP and/=
or XML-RPC<br>
&gt; =A0 =A0 interface to your service and let the 3rd parties decide if th=
ey<br>
&gt; =A0 =A0 want to use jquery, dojo, prototype, java, C#, whatever to tal=
k to it.<br>
&gt;<br>
&gt;<br>
&gt; But if we are multiplexing &#39;channels&#39; you cant just define a<b=
r>
&gt; resful/whatever service, as the server has to multiplex the difference=
<br>
</div>&gt; services.<br>
<br>
Martin,<br>
<br>
I don&#39;t understand your point. =A0Can you explain some more?<br>
<br>
<br>
To expand on my thoughts on this matter, consider if the google<br>
server provides several cometd services at the following URIs<br>
<br>
 =A0/gcomet/newsAlerts<br>
 =A0/gcomet/stockPrices<br>
 =A0/gcomet/twitters<br>
<br>
<br>
A simple client could open a HTTP connection to any of those<br>
URIs and upgrade to to the bidirectional protocol. =A0Each connection<br>
would then be associated with a single URI and datagrams<br>
sent/received would be to/from that URI and they could be<br>
framed without any meta data. 3 connections would<br>
be used to connect to all 3 feeds.<br>
<br>
But a more sophisticated client could connect to /gcomet<br>
and upgrade to the bidirectional protocol. =A0It could then<br>
send some control datagrams (using meta data associated<br>
with the datagrams to indicate they are control messages)<br>
which registered interest in the 3 URIs. =A0 Datagrams<br>
could be sent/received over that connection, but each would<br>
need to have associated meta-data to indicate which of<br>
the URIs the message was to/from.<br>
<div><div></div><div class=3D"h5"><br>
</div></div></blockquote></div><br>I am thinking of the server side impleme=
ntations of these services. If they are, for example, developed by differen=
t developers/teams it would be hard to do that in isolation from each other=
 without something on the server handling these meta data messages and rout=
ing the data to the write server side component. This dispatching of messag=
es to the right service would need an API or server side development is not=
 going to be very modular.<br>
<br>You are suggesting the browser does the equivalent on the client side, =
which fits well and as you point out means widget developers don&#39;t have=
 to worry too much about it or make sure they use the correct wrapper libra=
ries etc. However, on the server side there is a lot more software around, =
a lot more custom implementations - some of which have APIs for existing th=
ings of course, CGI, servlets etc, and they would need to handle this multi=
plexing.<br>
<br>So in your example, someone needs to be able to implement the /gcomet/s=
tockPrices server service without knowing that there is a /gcomet/twitters =
service and that a client might be accessing /gcomet/stockPrices via a comm=
on /gcomet connection<br>

--0016361e88c64fca290469a0daa7--

From sh@defuze.org  Mon May 11 04:58:42 2009
Return-Path: <sh@defuze.org>
X-Original-To: hybi@core3.amsl.com
Delivered-To: hybi@core3.amsl.com
Received: from localhost (localhost [127.0.0.1]) by core3.amsl.com (Postfix) with ESMTP id 437E53A69A9 for <hybi@core3.amsl.com>; Mon, 11 May 2009 04:58:42 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -1.912
X-Spam-Level: 
X-Spam-Status: No, score=-1.912 tagged_above=-999 required=5 tests=[AWL=-0.247, BAYES_00=-2.599, IP_NOT_FRIENDLY=0.334, J_CHICKENPOX_24=0.6]
Received: from mail.ietf.org ([64.170.98.32]) by localhost (core3.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id DmO945pTiyHA for <hybi@core3.amsl.com>; Mon, 11 May 2009 04:58:41 -0700 (PDT)
Received: from mail1.webfaction.com (mail1.webfaction.com [67.15.2.85]) by core3.amsl.com (Postfix) with ESMTP id 2DA1E3A681E for <hybi@ietf.org>; Mon, 11 May 2009 04:58:41 -0700 (PDT)
Received: from mail1.webfaction.com (localhost.localdomain [127.0.0.1]) by mail1.webfaction.com (8.12.11.20060308/8.13.3) with ESMTP id n4BC0B39000327; Mon, 11 May 2009 07:00:11 -0500
Received: (from apache@localhost) by mail1.webfaction.com (8.12.11.20060308/8.12.11/Submit) id n4BC0B33000325; Mon, 11 May 2009 14:00:11 +0200
X-Authentication-Warning: mail1.webfaction.com: apache set sender to sh@defuze.org using -f
Received: from 193.253.216.132 (SquirrelMail authenticated user platom_sylvain) by mail1.webfaction.com with HTTP; Mon, 11 May 2009 14:00:11 +0200 (CEST)
Message-ID: <62866.193.253.216.132.1242043211.squirrel@mail1.webfaction.com>
In-Reply-To: <4A077085.9020009@webtide.com>
References: <c5b3a7130905051854k45daefb6v46acb29d4365bfe3@mail.gmail.com> <4A00F710.6050607@webtide.com> <c5b3a7130905061155t38f126f4j46036e03ae319205@mail.gmail.com> <4A02E41C.5060509@webtide.com> <c5b3a7130905071823n3202574bu507df463a66ce070@mail.gmail.com> <4A039E02.10901@webtide.com> <c5b3a7130905080203x5ee0a2c1s1f4789dbd8841fb8@mail.gmail.com> <4A04F7FB.5050801@webtide.com> <4A053A47.8010001@defuze.org> <4A077085.9020009@webtide.com>
Date: Mon, 11 May 2009 14:00:11 +0200 (CEST)
From: "Sylvain Hellegouarch" <sh@defuze.org>
To: "Greg Wilkins" <gregw@webtide.com>
User-Agent: SquirrelMail/1.4.8-6.el3
MIME-Version: 1.0
Content-Type: text/plain;charset=iso-8859-1
Content-Transfer-Encoding: 8bit
X-Priority: 3 (Normal)
Importance: Normal
Cc: hybi@ietf.org
Subject: Re: [hybi] Message Strategy. Was: Connection Strategy
X-BeenThere: hybi@ietf.org
X-Mailman-Version: 2.1.9
Precedence: list
Reply-To: sh@defuze.org
List-Id: Server-Initiated HTTP <hybi.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/listinfo/hybi>, <mailto:hybi-request@ietf.org?subject=unsubscribe>
List-Archive: <http://www.ietf.org/mail-archive/web/hybi>
List-Post: <mailto:hybi@ietf.org>
List-Help: <mailto:hybi-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/hybi>, <mailto:hybi-request@ietf.org?subject=subscribe>
X-List-Received-Date: Mon, 11 May 2009 11:58:42 -0000

> Sylvain Hellegouarch wrote:
>> I don't quite see how. Isn't IP+port the right way of doing routing?
>
>
> HTTP and whatever protocol we are discussing here are
> application layer protocols.  IP+port are a transport
> address:
>
>  * IP address is a network layer address and identifies a host
>
>  * port is a transport layer concept and identifies a
>    service/process == application
>
>  * application layer protocols (eg HTTP) uses
>    addition information (eg URI) to identify resources
>    within a given service/process/application.
>
> Thus in good layered networking  a socket is
> identified by src IP + src port + dest IP + dest port
> and represents a connection between applications.
>
> Applications layers should not use a transport
> address to identify application resources.  If
> they were to do that, then:
>
>  + HTTP would use connection per resource (ok HTTP/0.9 did that!)
>  + POP/IMAP would use connection per email
>  + X-windows would use a connection per window
>  + XMPP would use a connection per conversation
>  + BEEP would use a connection per channel
>  + Telnet would open a new connection for every command run
>  + FTP would use a connection per file (DOH! it does do this, but
>    historically it has been a PITA that it does so.  It is
>    the exception that proves the rule!)
>
>
> HTTP/0.9 was indeed a lot simpler to implement than HTTP/1.1
> none of those content-length, chunking and pipelining concerns.
>
> If we wanted the efficiency of multiple resources from a
> server - the IETF could have said that applications should
> use higher level constructs to put multiple resources into
> a single connection (eg use multi-part mime).   But that
> never happened, because transport sharing is an
> application layer concern - not an application concern.
>
> Instead HTTP/1.0 keep-alive and then HTTP/1.1 were developed
> to include features that allow a single transport connection
> to serve multiple resources.
>
> To argue against supporting multiple resources in bidirectional
> communications is paramount to saying that we should go back to
> HTTP/0.9 and allow applications develop higher level protocols
> (eg multi-part mime) to send back a web page and all it's
> resources over a single connection.
>
> Transport sharing should be done in the application layer
> protocol and not in the application!

I think we misunderstood each other in regards to what I mean by routing.
I'm not convinced sharing one single connection for several distinct
services (XMPP, HTTP, BEEP, etc.) is the right idea because it adds, I
think, complexity to what already exist with TCP: IP+Port.

Now for one given service, I can understand why you would share the
connection to access, as you call it, distinct resources.


>> What happens when the socket is terminated because one component is not
>> behaving fairly? Every other components would suffer from it?
>
> I don't see how/why one component would be allowed to terminate a
> shared connection - no matter how badly it behaves.
>
> But even if it does, then the connection management software
> can re-establish a connection and other state with it.

Well I'd expect so for sure. My problem is not about what to do upon
disconnection, it's with the fact that one component may break the flow of
others. That's rather expensive to me from a user experience perspective.

Cheers,
- Sylvain
-- 
Sylvain Hellegouarch
http://www.defuze.org

From gregw@webtide.com  Mon May 11 07:42:32 2009
Return-Path: <gregw@webtide.com>
X-Original-To: hybi@core3.amsl.com
Delivered-To: hybi@core3.amsl.com
Received: from localhost (localhost [127.0.0.1]) by core3.amsl.com (Postfix) with ESMTP id 7981828C11C for <hybi@core3.amsl.com>; Mon, 11 May 2009 07:42:32 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -2.193
X-Spam-Level: 
X-Spam-Status: No, score=-2.193 tagged_above=-999 required=5 tests=[AWL=-0.194, BAYES_00=-2.599, J_CHICKENPOX_24=0.6]
Received: from mail.ietf.org ([64.170.98.32]) by localhost (core3.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 5CETGJmGijfr for <hybi@core3.amsl.com>; Mon, 11 May 2009 07:42:31 -0700 (PDT)
Received: from mail-ew0-f176.google.com (mail-ew0-f176.google.com [209.85.219.176]) by core3.amsl.com (Postfix) with ESMTP id 9366C28C0FC for <hybi@ietf.org>; Mon, 11 May 2009 07:42:31 -0700 (PDT)
Received: by ewy24 with SMTP id 24so3471682ewy.37 for <hybi@ietf.org>; Mon, 11 May 2009 07:43:44 -0700 (PDT)
Received: by 10.210.67.10 with SMTP id p10mr2416767eba.58.1242053023008; Mon, 11 May 2009 07:43:43 -0700 (PDT)
Received: from ?10.10.1.12? (60-242-119-126.tpgi.com.au [60.242.119.126]) by mx.google.com with ESMTPS id 22sm6500930ewy.40.2009.05.11.07.43.39 (version=TLSv1/SSLv3 cipher=RC4-MD5); Mon, 11 May 2009 07:43:41 -0700 (PDT)
Message-ID: <4A083992.8050309@webtide.com>
Date: Tue, 12 May 2009 00:43:30 +1000
From: Greg Wilkins <gregw@webtide.com>
User-Agent: Thunderbird 2.0.0.21 (X11/20090409)
MIME-Version: 1.0
To: hybi@ietf.org
References: <c5b3a7130905051854k45daefb6v46acb29d4365bfe3@mail.gmail.com> <4A00F710.6050607@webtide.com> <c5b3a7130905061155t38f126f4j46036e03ae319205@mail.gmail.com> <4A02E41C.5060509@webtide.com> <c5b3a7130905071823n3202574bu507df463a66ce070@mail.gmail.com> <4A039E02.10901@webtide.com> <c5b3a7130905080203x5ee0a2c1s1f4789dbd8841fb8@mail.gmail.com> <4A04F7FB.5050801@webtide.com> <4A053A47.8010001@defuze.org> <4A077085.9020009@webtide.com> <62866.193.253.216.132.1242043211.squirrel@mail1.webfaction.com>
In-Reply-To: <62866.193.253.216.132.1242043211.squirrel@mail1.webfaction.com>
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: 7bit
Subject: Re: [hybi] Message Strategy. Was: Connection Strategy
X-BeenThere: hybi@ietf.org
X-Mailman-Version: 2.1.9
Precedence: list
List-Id: Server-Initiated HTTP <hybi.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/listinfo/hybi>, <mailto:hybi-request@ietf.org?subject=unsubscribe>
List-Archive: <http://www.ietf.org/mail-archive/web/hybi>
List-Post: <mailto:hybi@ietf.org>
List-Help: <mailto:hybi-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/hybi>, <mailto:hybi-request@ietf.org?subject=subscribe>
X-List-Received-Date: Mon, 11 May 2009 14:42:32 -0000

Sylvain Hellegouarch wrote:
> I think we misunderstood each other in regards to what I mean by routing.
> I'm not convinced sharing one single connection for several distinct
> services (XMPP, HTTP, BEEP, etc.) is the right idea because it adds, I
> think, complexity to what already exist with TCP: IP+Port.

Totally agree!

thanks for the clarification.

cheers


From gregw@webtide.com  Mon May 11 07:51:40 2009
Return-Path: <gregw@webtide.com>
X-Original-To: hybi@core3.amsl.com
Delivered-To: hybi@core3.amsl.com
Received: from localhost (localhost [127.0.0.1]) by core3.amsl.com (Postfix) with ESMTP id 7AF493A69D8 for <hybi@core3.amsl.com>; Mon, 11 May 2009 07:51:40 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -2.49
X-Spam-Level: 
X-Spam-Status: No, score=-2.49 tagged_above=-999 required=5 tests=[AWL=0.109,  BAYES_00=-2.599]
Received: from mail.ietf.org ([64.170.98.32]) by localhost (core3.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id M+CQYQBVOw8A for <hybi@core3.amsl.com>; Mon, 11 May 2009 07:51:39 -0700 (PDT)
Received: from mail-ew0-f176.google.com (mail-ew0-f176.google.com [209.85.219.176]) by core3.amsl.com (Postfix) with ESMTP id 684FF3A6452 for <hybi@ietf.org>; Mon, 11 May 2009 07:51:39 -0700 (PDT)
Received: by ewy24 with SMTP id 24so3478857ewy.37 for <hybi@ietf.org>; Mon, 11 May 2009 07:53:07 -0700 (PDT)
Received: by 10.210.30.1 with SMTP id d1mr2121316ebd.5.1242053587693; Mon, 11 May 2009 07:53:07 -0700 (PDT)
Received: from ?10.10.1.12? (60-242-119-126.tpgi.com.au [60.242.119.126]) by mx.google.com with ESMTPS id 1sm6884355ewy.77.2009.05.11.07.53.04 (version=TLSv1/SSLv3 cipher=RC4-MD5); Mon, 11 May 2009 07:53:06 -0700 (PDT)
Message-ID: <4A083BC8.8090605@webtide.com>
Date: Tue, 12 May 2009 00:52:56 +1000
From: Greg Wilkins <gregw@webtide.com>
User-Agent: Thunderbird 2.0.0.21 (X11/20090409)
MIME-Version: 1.0
To: hybi@ietf.org
References: <c5b3a7130905051854k45daefb6v46acb29d4365bfe3@mail.gmail.com>	<c5b3a7130905080203x5ee0a2c1s1f4789dbd8841fb8@mail.gmail.com>	<4A04F7FB.5050801@webtide.com> <4A053A47.8010001@defuze.org>	<44abafb90905090159u1f47c88dh8802c9dc5d1c3594@mail.gmail.com>	<4A075F89.5050806@webtide.com>	<Pine.LNX.4.62.0905102315041.7824@hixie.dreamhostps.com>	<4A077808.4030406@webtide.com>	<44abafb90905110121jcd50f43kdd0b1eb92174356e@mail.gmail.com>	<4A08000C.6060803@webtide.com> <44abafb90905110358v244560a5iffe1103ac930b027@mail.gmail.com>
In-Reply-To: <44abafb90905110358v244560a5iffe1103ac930b027@mail.gmail.com>
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: 7bit
Subject: Re: [hybi] Message Strategy. Was: Connection Strategy
X-BeenThere: hybi@ietf.org
X-Mailman-Version: 2.1.9
Precedence: list
List-Id: Server-Initiated HTTP <hybi.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/listinfo/hybi>, <mailto:hybi-request@ietf.org?subject=unsubscribe>
List-Archive: <http://www.ietf.org/mail-archive/web/hybi>
List-Post: <mailto:hybi@ietf.org>
List-Help: <mailto:hybi-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/hybi>, <mailto:hybi-request@ietf.org?subject=subscribe>
X-List-Received-Date: Mon, 11 May 2009 14:51:40 -0000

Martin Tyler wrote:

> I am thinking of the server side implementations of these services. If
> they are, for example, developed by different developers/teams it would
> be hard to do that in isolation from each other without something on the
> server handling these meta data messages and routing the data to the
> write server side component. This dispatching of messages to the right
> service would need an API or server side development is not going to be
> very modular.

Why can't it be modular?

Servers already map HTTP requests to resources (Servlets in the case
of Java) in a modular fashion.

> You are suggesting the browser does the equivalent on the client side,
> which fits well and as you point out means widget developers don't have
> to worry too much about it or make sure they use the correct wrapper
> libraries etc. However, on the server side there is a lot more software
> around, a lot more custom implementations - some of which have APIs for
> existing things of course, CGI, servlets etc, and they would need to
> handle this multiplexing.

Which is why I think the protocol we are working towards (let's call it HYBI
for HYpothetical BIdirectional protocol) needs to support multiplexing
in the standard.

The server implementors like myself would implement the HYBI
protocol so that I can send/receive datagrams to/from modular
application components.    Initially this would probably be
via proprietary API's, but in java at least, I would expect
a standard API to rapidly be developed as a JSR.

This would be no different to how I would proceed on the
server if WebSocket was ratified in it's current form.
The server would still need to terminate the websocket
connection and manage the routing of datagrams to/from
modular application logic.

The only real difference is that with websocket as it is,
the URI would be constant for a connection, while
with HYBI there could be a new URI for each datagram.


> So in your example, someone needs to be able to implement the
> /gcomet/stockPrices server service without knowing that there is a
> /gcomet/twitters service and that a client might be accessing
> /gcomet/stockPrices via a common /gcomet connection

I imagine that the API will be somewhat like servlets
and a modular application logic can be mapped to URIs.

cheers



From martin.tyler@boo.org  Mon May 11 08:07:09 2009
Return-Path: <martin.tyler@boo.org>
X-Original-To: hybi@core3.amsl.com
Delivered-To: hybi@core3.amsl.com
Received: from localhost (localhost [127.0.0.1]) by core3.amsl.com (Postfix) with ESMTP id E43313A6EA2 for <hybi@core3.amsl.com>; Mon, 11 May 2009 08:07:09 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -1.744
X-Spam-Level: 
X-Spam-Status: No, score=-1.744 tagged_above=-999 required=5 tests=[AWL=0.232,  BAYES_00=-2.599, FM_FORGED_GMAIL=0.622, HTML_MESSAGE=0.001]
Received: from mail.ietf.org ([64.170.98.32]) by localhost (core3.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id qNaUOf6SC6F7 for <hybi@core3.amsl.com>; Mon, 11 May 2009 08:07:08 -0700 (PDT)
Received: from mail-gx0-f166.google.com (mail-gx0-f166.google.com [209.85.217.166]) by core3.amsl.com (Postfix) with ESMTP id A91E23A6CE4 for <hybi@ietf.org>; Mon, 11 May 2009 08:07:08 -0700 (PDT)
Received: by gxk10 with SMTP id 10so2672114gxk.13 for <hybi@ietf.org>; Mon, 11 May 2009 08:08:37 -0700 (PDT)
MIME-Version: 1.0
Received: by 10.90.99.3 with SMTP id w3mr6010615agb.64.1242054516976; Mon, 11  May 2009 08:08:36 -0700 (PDT)
In-Reply-To: <4A083BC8.8090605@webtide.com>
References: <c5b3a7130905051854k45daefb6v46acb29d4365bfe3@mail.gmail.com> <4A053A47.8010001@defuze.org> <44abafb90905090159u1f47c88dh8802c9dc5d1c3594@mail.gmail.com> <4A075F89.5050806@webtide.com> <Pine.LNX.4.62.0905102315041.7824@hixie.dreamhostps.com> <4A077808.4030406@webtide.com> <44abafb90905110121jcd50f43kdd0b1eb92174356e@mail.gmail.com> <4A08000C.6060803@webtide.com> <44abafb90905110358v244560a5iffe1103ac930b027@mail.gmail.com> <4A083BC8.8090605@webtide.com>
Date: Mon, 11 May 2009 16:08:36 +0100
Message-ID: <44abafb90905110808n643768f5tbbcfb2f5ad634c42@mail.gmail.com>
From: Martin Tyler <martin.tyler@boo.org>
To: hybi@ietf.org
Content-Type: multipart/alternative; boundary=0016362836d646ae7e0469a45a53
Subject: Re: [hybi] Message Strategy. Was: Connection Strategy
X-BeenThere: hybi@ietf.org
X-Mailman-Version: 2.1.9
Precedence: list
List-Id: Server-Initiated HTTP <hybi.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/listinfo/hybi>, <mailto:hybi-request@ietf.org?subject=unsubscribe>
List-Archive: <http://www.ietf.org/mail-archive/web/hybi>
List-Post: <mailto:hybi@ietf.org>
List-Help: <mailto:hybi-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/hybi>, <mailto:hybi-request@ietf.org?subject=subscribe>
X-List-Received-Date: Mon, 11 May 2009 15:07:10 -0000

--0016362836d646ae7e0469a45a53
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: 7bit

On Mon, May 11, 2009 at 3:52 PM, Greg Wilkins <gregw@webtide.com> wrote:

> Martin Tyler wrote:
>
> > I am thinking of the server side implementations of these services. If
> > they are, for example, developed by different developers/teams it would
> > be hard to do that in isolation from each other without something on the
> > server handling these meta data messages and routing the data to the
> > write server side component. This dispatching of messages to the right
> > service would need an API or server side development is not going to be
> > very modular.
>
> Why can't it be modular?
>
> Servers already map HTTP requests to resources (Servlets in the case
> of Java) in a modular fashion.


exactly - you need the servlet API to do this for you, all I am saying is
WebSocket (or whatever) needs an API on the server if it is to support a
decent development model - especially if a channel paradigm is added to the
design.


>
>
> > You are suggesting the browser does the equivalent on the client side,
> > which fits well and as you point out means widget developers don't have
> > to worry too much about it or make sure they use the correct wrapper
> > libraries etc. However, on the server side there is a lot more software
> > around, a lot more custom implementations - some of which have APIs for
> > existing things of course, CGI, servlets etc, and they would need to
> > handle this multiplexing.
>
> Which is why I think the protocol we are working towards (let's call it
> HYBI
> for HYpothetical BIdirectional protocol) needs to support multiplexing
> in the standard.
>
> The server implementors like myself would implement the HYBI
> protocol so that I can send/receive datagrams to/from modular
> application components.    Initially this would probably be
> via proprietary API's, but in java at least, I would expect
> a standard API to rapidly be developed as a JSR.
>
> This would be no different to how I would proceed on the
> server if WebSocket was ratified in it's current form.
> The server would still need to terminate the websocket
> connection and manage the routing of datagrams to/from
> modular application logic.
>
> The only real difference is that with websocket as it is,
> the URI would be constant for a connection, while
> with HYBI there could be a new URI for each datagram.
>
>
> > So in your example, someone needs to be able to implement the
> > /gcomet/stockPrices server service without knowing that there is a
> > /gcomet/twitters service and that a client might be accessing
> > /gcomet/stockPrices via a common /gcomet connection
>
> I imagine that the API will be somewhat like servlets
> and a modular application logic can be mapped to URIs.
>
> cheers
>

Ok, looks like we agree really - you misunderstood my comments. I am (was)
saying that the current WebSocket design does not prescribe any kind of
server API at all - but if we baked in channels, you would need to have an
API or server components could not easily be developed in a modular fashion.

What I am getting at is that we should be discussing this server API - this
would be a good idea anyway, but the channels idea makes it even more
important imho.

--0016362836d646ae7e0469a45a53
Content-Type: text/html; charset=ISO-8859-1
Content-Transfer-Encoding: quoted-printable

<br><br><div class=3D"gmail_quote">On Mon, May 11, 2009 at 3:52 PM, Greg Wi=
lkins <span dir=3D"ltr">&lt;<a href=3D"mailto:gregw@webtide.com">gregw@webt=
ide.com</a>&gt;</span> wrote:<br><blockquote class=3D"gmail_quote" style=3D=
"border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padd=
ing-left: 1ex;">
<div class=3D"im">Martin Tyler wrote:<br>
<br>
&gt; I am thinking of the server side implementations of these services. If=
<br>
&gt; they are, for example, developed by different developers/teams it woul=
d<br>
&gt; be hard to do that in isolation from each other without something on t=
he<br>
&gt; server handling these meta data messages and routing the data to the<b=
r>
&gt; write server side component. This dispatching of messages to the right=
<br>
&gt; service would need an API or server side development is not going to b=
e<br>
&gt; very modular.<br>
<br>
</div>Why can&#39;t it be modular?<br>
<br>
Servers already map HTTP requests to resources (Servlets in the case<br>
of Java) in a modular fashion.</blockquote><div><br>exactly - you need the =
servlet API to do this for you, all I am saying is WebSocket (or whatever) =
needs an API on the server if it is to support a decent development model -=
 especially if a channel paradigm is added to the design.<br>
=A0<br></div><blockquote class=3D"gmail_quote" style=3D"border-left: 1px so=
lid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;"><br>
<div class=3D"im"><br>
&gt; You are suggesting the browser does the equivalent on the client side,=
<br>
&gt; which fits well and as you point out means widget developers don&#39;t=
 have<br>
&gt; to worry too much about it or make sure they use the correct wrapper<b=
r>
&gt; libraries etc. However, on the server side there is a lot more softwar=
e<br>
&gt; around, a lot more custom implementations - some of which have APIs fo=
r<br>
&gt; existing things of course, CGI, servlets etc, and they would need to<b=
r>
&gt; handle this multiplexing.<br>
<br>
</div>Which is why I think the protocol we are working towards (let&#39;s c=
all it HYBI<br>
for HYpothetical BIdirectional protocol) needs to support multiplexing<br>
in the standard.<br>
<br>
The server implementors like myself would implement the HYBI<br>
protocol so that I can send/receive datagrams to/from modular<br>
application components. =A0 =A0Initially this would probably be<br>
via proprietary API&#39;s, but in java at least, I would expect<br>
a standard API to rapidly be developed as a JSR.<br>
<br>
This would be no different to how I would proceed on the<br>
server if WebSocket was ratified in it&#39;s current form.<br>
The server would still need to terminate the websocket<br>
connection and manage the routing of datagrams to/from<br>
modular application logic.<br>
<br>
The only real difference is that with websocket as it is,<br>
the URI would be constant for a connection, while<br>
with HYBI there could be a new URI for each datagram.<br>
<div class=3D"im"><br>
<br>
&gt; So in your example, someone needs to be able to implement the<br>
&gt; /gcomet/stockPrices server service without knowing that there is a<br>
&gt; /gcomet/twitters service and that a client might be accessing<br>
&gt; /gcomet/stockPrices via a common /gcomet connection<br>
<br>
</div>I imagine that the API will be somewhat like servlets<br>
and a modular application logic can be mapped to URIs.<br>
<br>
cheers<br>
</blockquote></div><br>Ok, looks like we agree really - you misunderstood m=
y comments. I am (was) saying that the current WebSocket design does not pr=
escribe any kind of server API at all - but if we baked in channels, you wo=
uld need to have an API or server components could not easily be developed =
in a modular fashion.<br>
<br>What I am getting at is that we should be discussing this server API - =
this would be a good idea anyway, but the channels idea makes it even more =
important imho. <br>

--0016362836d646ae7e0469a45a53--

From gregw@webtide.com  Mon May 11 08:24:43 2009
Return-Path: <gregw@webtide.com>
X-Original-To: hybi@core3.amsl.com
Delivered-To: hybi@core3.amsl.com
Received: from localhost (localhost [127.0.0.1]) by core3.amsl.com (Postfix) with ESMTP id 033793A696E for <hybi@core3.amsl.com>; Mon, 11 May 2009 08:24:43 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -2.492
X-Spam-Level: 
X-Spam-Status: No, score=-2.492 tagged_above=-999 required=5 tests=[AWL=0.107,  BAYES_00=-2.599]
Received: from mail.ietf.org ([64.170.98.32]) by localhost (core3.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id cuysA6uk7j9I for <hybi@core3.amsl.com>; Mon, 11 May 2009 08:24:42 -0700 (PDT)
Received: from mail-ew0-f224.google.com (mail-ew0-f224.google.com [209.85.219.224]) by core3.amsl.com (Postfix) with ESMTP id DD89B28C157 for <hybi@ietf.org>; Mon, 11 May 2009 08:24:41 -0700 (PDT)
Received: by ewy24 with SMTP id 24so3504383ewy.37 for <hybi@ietf.org>; Mon, 11 May 2009 08:26:10 -0700 (PDT)
Received: by 10.210.81.10 with SMTP id e10mr3332130ebb.89.1242055569129; Mon, 11 May 2009 08:26:09 -0700 (PDT)
Received: from ?10.10.1.12? (60-242-119-126.tpgi.com.au [60.242.119.126]) by mx.google.com with ESMTPS id 23sm7039827ewy.116.2009.05.11.08.26.05 (version=TLSv1/SSLv3 cipher=RC4-MD5); Mon, 11 May 2009 08:26:08 -0700 (PDT)
Message-ID: <4A084385.4080408@webtide.com>
Date: Tue, 12 May 2009 01:25:57 +1000
From: Greg Wilkins <gregw@webtide.com>
User-Agent: Thunderbird 2.0.0.21 (X11/20090409)
MIME-Version: 1.0
To: Martin Tyler <martin.tyler@boo.org>
References: <c5b3a7130905051854k45daefb6v46acb29d4365bfe3@mail.gmail.com>	<4A053A47.8010001@defuze.org>	<44abafb90905090159u1f47c88dh8802c9dc5d1c3594@mail.gmail.com>	<4A075F89.5050806@webtide.com>	<Pine.LNX.4.62.0905102315041.7824@hixie.dreamhostps.com>	<4A077808.4030406@webtide.com>	<44abafb90905110121jcd50f43kdd0b1eb92174356e@mail.gmail.com>	<4A08000C.6060803@webtide.com>	<44abafb90905110358v244560a5iffe1103ac930b027@mail.gmail.com>	<4A083BC8.8090605@webtide.com> <44abafb90905110808n643768f5tbbcfb2f5ad634c42@mail.gmail.com>
In-Reply-To: <44abafb90905110808n643768f5tbbcfb2f5ad634c42@mail.gmail.com>
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: 7bit
Cc: hybi@ietf.org
Subject: Re: [hybi] Message Strategy. Was: Connection Strategy
X-BeenThere: hybi@ietf.org
X-Mailman-Version: 2.1.9
Precedence: list
List-Id: Server-Initiated HTTP <hybi.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/listinfo/hybi>, <mailto:hybi-request@ietf.org?subject=unsubscribe>
List-Archive: <http://www.ietf.org/mail-archive/web/hybi>
List-Post: <mailto:hybi@ietf.org>
List-Help: <mailto:hybi-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/hybi>, <mailto:hybi-request@ietf.org?subject=subscribe>
X-List-Received-Date: Mon, 11 May 2009 15:24:43 -0000

Martin Tyler wrote:
> Ok, looks like we agree really - you misunderstood my comments. 

Excellent - (not that we misunderstood each other, but that we got
to understanding in the end :)

> I am
> (was) saying that the current WebSocket design does not prescribe any
> kind of server API at all - but if we baked in channels, you would need
> to have an API or server components could not easily be developed in a
> modular fashion.

I kind of agree.  But I'd say it in terms of defining the
server side semantics rather that API.   API styles can
differ greatly due to language, environment and taste.


> What I am getting at is that we should be discussing this server API -
> this would be a good idea anyway, but the channels idea makes it even
> more important imho.

Indeed - and not just the addressing and handling of datagrams, but
the application of security, origins, allowed xd origins etc needs
to be considered.

cheers



From lisa.dusseault@gmail.com  Sun May 17 15:50:05 2009
Return-Path: <lisa.dusseault@gmail.com>
X-Original-To: hybi@core3.amsl.com
Delivered-To: hybi@core3.amsl.com
Received: from localhost (localhost [127.0.0.1]) by core3.amsl.com (Postfix) with ESMTP id C0F973A6F34 for <hybi@core3.amsl.com>; Sun, 17 May 2009 15:50:05 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -2.258
X-Spam-Level: 
X-Spam-Status: No, score=-2.258 tagged_above=-999 required=5 tests=[AWL=-0.259, BAYES_00=-2.599, J_CHICKENPOX_24=0.6]
Received: from mail.ietf.org ([64.170.98.32]) by localhost (core3.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id mAAHwo824dQW for <hybi@core3.amsl.com>; Sun, 17 May 2009 15:50:04 -0700 (PDT)
Received: from mail-qy0-f107.google.com (mail-qy0-f107.google.com [209.85.221.107]) by core3.amsl.com (Postfix) with ESMTP id 2859B3A6F30 for <hybi@ietf.org>; Sun, 17 May 2009 15:50:04 -0700 (PDT)
Received: by qyk5 with SMTP id 5so351593qyk.29 for <hybi@ietf.org>; Sun, 17 May 2009 15:51:37 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:in-reply-to:references :date:message-id:subject:from:to:cc:content-type :content-transfer-encoding; bh=Xw1Lyzv/oABpPrVAA8DB4ptGWDRntkpm0eawdnzZUfg=; b=gFDmWIuWvhLpGY38DMIUsFHwBCfQ8E8Usqx9symgfc2lZ9BYhSlk0DlPp1gCDgRAeO PvzI+wJNtR0ypoDn0F/G2ywOGDEMVXdEnriXFGDkAhh22Bk/z157qf4Mbxw7xbpwCRBD 5M/rcNIUYWf4kh/2b8Cz+KyU6C8JDYdCdHTpg=
DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type:content-transfer-encoding; b=J6hPAmL1PvNSZBIBHSxcWUV13hhC9jsd/g6WM/ESLKJ3Qux4ogk3QgBQ4sXP9GZH1g Ee09C11vhYk6wylvO9vgd6njuO08tWeqO8ou6HOfEGOGhlswukE4aL/VubxEvSHEst24 AFqiNRCGjdwrOrTPmHv343ihXHceHhiIXPL+I=
MIME-Version: 1.0
Received: by 10.220.97.75 with SMTP id k11mr6159457vcn.75.1242600697644; Sun,  17 May 2009 15:51:37 -0700 (PDT)
In-Reply-To: <4A077085.9020009@webtide.com>
References: <c5b3a7130905051854k45daefb6v46acb29d4365bfe3@mail.gmail.com> <4A00F710.6050607@webtide.com> <c5b3a7130905061155t38f126f4j46036e03ae319205@mail.gmail.com> <4A02E41C.5060509@webtide.com> <c5b3a7130905071823n3202574bu507df463a66ce070@mail.gmail.com> <4A039E02.10901@webtide.com> <c5b3a7130905080203x5ee0a2c1s1f4789dbd8841fb8@mail.gmail.com> <4A04F7FB.5050801@webtide.com> <4A053A47.8010001@defuze.org> <4A077085.9020009@webtide.com>
Date: Sun, 17 May 2009 15:51:37 -0700
Message-ID: <ca722a9e0905171551h40e6eb76s83045d943bb27aec@mail.gmail.com>
From: Lisa Dusseault <lisa.dusseault@gmail.com>
To: Greg Wilkins <gregw@webtide.com>
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: quoted-printable
Cc: hybi@ietf.org
Subject: Re: [hybi] Message Strategy. Was: Connection Strategy
X-BeenThere: hybi@ietf.org
X-Mailman-Version: 2.1.9
Precedence: list
List-Id: Server-Initiated HTTP <hybi.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/listinfo/hybi>, <mailto:hybi-request@ietf.org?subject=unsubscribe>
List-Archive: <http://www.ietf.org/mail-archive/web/hybi>
List-Post: <mailto:hybi@ietf.org>
List-Help: <mailto:hybi-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/hybi>, <mailto:hybi-request@ietf.org?subject=subscribe>
X-List-Received-Date: Sun, 17 May 2009 22:50:05 -0000

Since we're discussing characteristics at this high level, I hope this
group is roughly familiar with SCTP as a contrast:
http://tools.ietf.org/html/rfc4960

SCTP can replace TCP, providing transport  with better characteristics
for HTTP, including built-in multi-streaming and respect for message
boundaries.

Lisa

On Sun, May 10, 2009 at 5:25 PM, Greg Wilkins <gregw@webtide.com> wrote:
> Sylvain Hellegouarch wrote:
>> I don't quite see how. Isn't IP+port the right way of doing routing?
>
>
> HTTP and whatever protocol we are discussing here are
> application layer protocols. =A0IP+port are a transport
> address:
>
> =A0* IP address is a network layer address and identifies a host
>
> =A0* port is a transport layer concept and identifies a
> =A0 service/process =3D=3D application
>
> =A0* application layer protocols (eg HTTP) uses
> =A0 addition information (eg URI) to identify resources
> =A0 within a given service/process/application.
>
> Thus in good layered networking =A0a socket is
> identified by src IP + src port + dest IP + dest port
> and represents a connection between applications.
>
> Applications layers should not use a transport
> address to identify application resources. =A0If
> they were to do that, then:
>
> =A0+ HTTP would use connection per resource (ok HTTP/0.9 did that!)
> =A0+ POP/IMAP would use connection per email
> =A0+ X-windows would use a connection per window
> =A0+ XMPP would use a connection per conversation
> =A0+ BEEP would use a connection per channel
> =A0+ Telnet would open a new connection for every command run
> =A0+ FTP would use a connection per file (DOH! it does do this, but
> =A0 historically it has been a PITA that it does so. =A0It is
> =A0 the exception that proves the rule!)
>
>
> HTTP/0.9 was indeed a lot simpler to implement than HTTP/1.1
> none of those content-length, chunking and pipelining concerns.
>
> If we wanted the efficiency of multiple resources from a
> server - the IETF could have said that applications should
> use higher level constructs to put multiple resources into
> a single connection (eg use multi-part mime). =A0 But that
> never happened, because transport sharing is an
> application layer concern - not an application concern.
>
> Instead HTTP/1.0 keep-alive and then HTTP/1.1 were developed
> to include features that allow a single transport connection
> to serve multiple resources.
>
> To argue against supporting multiple resources in bidirectional
> communications is paramount to saying that we should go back to
> HTTP/0.9 and allow applications develop higher level protocols
> (eg multi-part mime) to send back a web page and all it's
> resources over a single connection.
>
> Transport sharing should be done in the application layer
> protocol and not in the application!
>
>
>
>
>> What happens when the socket is terminated because one component is not
>> behaving fairly? Every other components would suffer from it?
>
> I don't see how/why one component would be allowed to terminate a
> shared connection - no matter how badly it behaves.
>
> But even if it does, then the connection management software
> can re-establish a connection and other state with it.
>
> HTTP clients already do this! They have a pool of connections
> to the server - any of which may close at any time for several
> good/bad reasons. =A0The HTTP clients know how to recreate connections
> and what requests can be resent and which cannot.
>
> This is a good example of how the application layer protocol
> can handle complexities of transient transport failures with
> minimal intervention of the application itself.
>
> regards
>
>
>
>
>
>
>
>
>
>
>
> _______________________________________________
> hybi mailing list
> hybi@ietf.org
> https://www.ietf.org/mailman/listinfo/hybi
>

From gregw@webtide.com  Sun May 17 16:56:38 2009
Return-Path: <gregw@webtide.com>
X-Original-To: hybi@core3.amsl.com
Delivered-To: hybi@core3.amsl.com
Received: from localhost (localhost [127.0.0.1]) by core3.amsl.com (Postfix) with ESMTP id 42AE53A6A18 for <hybi@core3.amsl.com>; Sun, 17 May 2009 16:56:38 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -1.194
X-Spam-Level: 
X-Spam-Status: No, score=-1.194 tagged_above=-999 required=5 tests=[AWL=-1.195, BAYES_50=0.001]
Received: from mail.ietf.org ([64.170.98.32]) by localhost (core3.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id dEdhOtXQXWRw for <hybi@core3.amsl.com>; Sun, 17 May 2009 16:56:37 -0700 (PDT)
Received: from wa-out-1112.google.com (wa-out-1112.google.com [209.85.146.183]) by core3.amsl.com (Postfix) with ESMTP id 8A31F3A67EA for <hybi@ietf.org>; Sun, 17 May 2009 16:56:37 -0700 (PDT)
Received: by wa-out-1112.google.com with SMTP id l35so902631waf.5 for <hybi@ietf.org>; Sun, 17 May 2009 16:58:11 -0700 (PDT)
Received: by 10.115.19.16 with SMTP id w16mr10038434wai.51.1242604691165; Sun, 17 May 2009 16:58:11 -0700 (PDT)
Received: from ?10.10.1.12? (60-242-119-126.tpgi.com.au [60.242.119.126]) by mx.google.com with ESMTPS id y11sm12878387pod.18.2009.05.17.16.58.08 (version=TLSv1/SSLv3 cipher=RC4-MD5); Sun, 17 May 2009 16:58:09 -0700 (PDT)
Message-ID: <4A10A48C.7040103@webtide.com>
Date: Mon, 18 May 2009 09:58:04 +1000
From: Greg Wilkins <gregw@webtide.com>
User-Agent: Thunderbird 2.0.0.21 (X11/20090409)
MIME-Version: 1.0
To: hybi@ietf.org
References: <c5b3a7130905051854k45daefb6v46acb29d4365bfe3@mail.gmail.com>	 <4A00F710.6050607@webtide.com>	 <c5b3a7130905061155t38f126f4j46036e03ae319205@mail.gmail.com>	 <4A02E41C.5060509@webtide.com>	 <c5b3a7130905071823n3202574bu507df463a66ce070@mail.gmail.com>	 <4A039E02.10901@webtide.com>	 <c5b3a7130905080203x5ee0a2c1s1f4789dbd8841fb8@mail.gmail.com>	 <4A04F7FB.5050801@webtide.com> <4A053A47.8010001@defuze.org>	 <4A077085.9020009@webtide.com> <ca722a9e0905171551h40e6eb76s83045d943bb27aec@mail.gmail.com>
In-Reply-To: <ca722a9e0905171551h40e6eb76s83045d943bb27aec@mail.gmail.com>
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: 7bit
Subject: Re: [hybi] Message Strategy. Was: Connection Strategy
X-BeenThere: hybi@ietf.org
X-Mailman-Version: 2.1.9
Precedence: list
List-Id: Server-Initiated HTTP <hybi.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/listinfo/hybi>, <mailto:hybi-request@ietf.org?subject=unsubscribe>
List-Archive: <http://www.ietf.org/mail-archive/web/hybi>
List-Post: <mailto:hybi@ietf.org>
List-Help: <mailto:hybi-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/hybi>, <mailto:hybi-request@ietf.org?subject=subscribe>
X-List-Received-Date: Sun, 17 May 2009 23:56:38 -0000

Lisa Dusseault wrote:
> Since we're discussing characteristics at this high level, I hope this
> group is roughly familiar with SCTP as a contrast:
> http://tools.ietf.org/html/rfc4960
> 
> SCTP can replace TCP, providing transport  with better characteristics
> for HTTP, including built-in multi-streaming and respect for message
> boundaries.


Lisa,

I'm indeed roughly familiar with the concepts and features offered
by STCP and it would appear that it would have a lot to offer
bidirectional transports of the type we are after.

However, I'm unfamiliar with the advocacy, support, likely
penetration and timescale of STCP.    Is there anybody that can
offer a view on these subjects?   ie is STCP a prospect for
the near, mid or long term?

cheers




From pieterh@gmail.com  Mon May 18 01:25:43 2009
Return-Path: <pieterh@gmail.com>
X-Original-To: hybi@core3.amsl.com
Delivered-To: hybi@core3.amsl.com
Received: from localhost (localhost [127.0.0.1]) by core3.amsl.com (Postfix) with ESMTP id 17DDB3A6FBE for <hybi@core3.amsl.com>; Mon, 18 May 2009 01:25:43 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -0.488
X-Spam-Level: 
X-Spam-Status: No, score=-0.488 tagged_above=-999 required=5 tests=[BAYES_05=-1.11, FM_FORGED_GMAIL=0.622]
Received: from mail.ietf.org ([64.170.98.32]) by localhost (core3.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id ip3D0lr3BTBo for <hybi@core3.amsl.com>; Mon, 18 May 2009 01:25:42 -0700 (PDT)
Received: from mail-fx0-f158.google.com (mail-fx0-f158.google.com [209.85.220.158]) by core3.amsl.com (Postfix) with ESMTP id 720743A6C1D for <hybi@ietf.org>; Mon, 18 May 2009 01:25:37 -0700 (PDT)
Received: by fxm2 with SMTP id 2so3084459fxm.37 for <hybi@ietf.org>; Mon, 18 May 2009 01:27:10 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:sender:received:in-reply-to :references:from:date:x-google-sender-auth:message-id:subject:to:cc :content-type:content-transfer-encoding; bh=rZK+JDVCoTyb7WoStITUjPigbdSyyzwSnK5TpPI811A=; b=BJlLa9RzghkMA/WDyd2eZHGgRxIGe3TU8nsdiLS0cBC6M19nFTxvRcf05jZTjpfBGA 29xXX6oiA2lsvSS+hZ9uirrArgyMb1dtl+0WPSO3B85xAE7M06CYWyIwOyVqtCC/Mylx qbMR4v3x6lYzznMZYSyHP5CyqfYtW6BVixMHI=
DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:sender:in-reply-to:references:from:date :x-google-sender-auth:message-id:subject:to:cc:content-type :content-transfer-encoding; b=dcjXA2pMYtTfiU8kp6bvpje3OmUf0iA5w2CXqN/KQGy0Ou6By/XahNQ2xJLSWsu7iA bLnqlygFV6xsYjlHRSvOL/w6c/YsGamWoQ3LO5E9pckDiwHdT/IcSxZlrsec2m4bt9c9 8aF44+7Iy/mH/3H7CHhPk0fvnpKQH5DUS2X3w=
MIME-Version: 1.0
Sender: pieterh@gmail.com
Received: by 10.86.68.10 with SMTP id q10mr6419769fga.78.1242635230110; Mon,  18 May 2009 01:27:10 -0700 (PDT)
In-Reply-To: <4A10A48C.7040103@webtide.com>
References: <c5b3a7130905051854k45daefb6v46acb29d4365bfe3@mail.gmail.com>  <4A02E41C.5060509@webtide.com> <c5b3a7130905071823n3202574bu507df463a66ce070@mail.gmail.com>  <4A039E02.10901@webtide.com> <c5b3a7130905080203x5ee0a2c1s1f4789dbd8841fb8@mail.gmail.com>  <4A04F7FB.5050801@webtide.com> <4A053A47.8010001@defuze.org>  <4A077085.9020009@webtide.com> <ca722a9e0905171551h40e6eb76s83045d943bb27aec@mail.gmail.com>  <4A10A48C.7040103@webtide.com>
From: Pieter Hintjens <ph@imatix.com>
Date: Mon, 18 May 2009 10:26:50 +0200
X-Google-Sender-Auth: 7f133575293c46f9
Message-ID: <5821ea240905180126k7c545998y9bede53f9d0215b3@mail.gmail.com>
To: Greg Wilkins <gregw@webtide.com>
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: quoted-printable
Cc: hybi@ietf.org
Subject: Re: [hybi] Message Strategy. Was: Connection Strategy
X-BeenThere: hybi@ietf.org
X-Mailman-Version: 2.1.9
Precedence: list
List-Id: Server-Initiated HTTP <hybi.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/listinfo/hybi>, <mailto:hybi-request@ietf.org?subject=unsubscribe>
List-Archive: <http://www.ietf.org/mail-archive/web/hybi>
List-Post: <mailto:hybi@ietf.org>
List-Help: <mailto:hybi-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/hybi>, <mailto:hybi-request@ietf.org?subject=subscribe>
X-List-Received-Date: Mon, 18 May 2009 08:25:43 -0000

On Mon, May 18, 2009 at 1:58 AM, Greg Wilkins <gregw@webtide.com> wrote:

> I'm indeed roughly familiar with the concepts and features offered
> by STCP and it would appear that it would have a lot to offer
> bidirectional transports of the type we are after.
>
> However, I'm unfamiliar with the advocacy, support, likely
> penetration and timescale of STCP. =A0 =A0Is there anybody that can
> offer a view on these subjects? =A0 ie is STCP a prospect for
> the near, mid or long term?

It's SCTP (streaming control transmission protocol), not STCP.  Easy
mistake to make...

For what it's worth, my team studied the use of SCTP for AMQP[1], a
messaging protocol we work on.

To some extent SCTP solves many of the problems of the AMQP transport
layer such as automatically reconnecting channels, multiplexing, and
so on.  It is trivial to use SCTP in place of TCP through the socket
interface, and we have done this for our open source AMQP messaging
produce, OpenAMQ[2].

SCTP is not universally available and not widely known, but does look
like a compelling upgrade to TCP.  However that would be meaningful
only if SCTP was a plug-and-play replacement.  If higher-level
protocols need to change in order to use SCTP, it will never IMO be
used.

So you can consider SCTP as a kind of enterprise TCP.  This means you
can move certain features out of whatever protocol sits on top of TCP.
 For example, connection multiplexing, which we did in AMQP, is in
fact redundant because users that need it can use SCTP.

Hope this helps.

-Pieter Hintjens
iMatix

[1] http://www.amqp.org
[2] http://www.openamq.org
[3] http://www.restms.org

From jwalden@MIT.EDU  Fri May 29 19:16:53 2009
Return-Path: <jwalden@MIT.EDU>
X-Original-To: hybi@core3.amsl.com
Delivered-To: hybi@core3.amsl.com
Received: from localhost (localhost [127.0.0.1]) by core3.amsl.com (Postfix) with ESMTP id 8393B3A6839 for <hybi@core3.amsl.com>; Fri, 29 May 2009 19:16:53 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -6.599
X-Spam-Level: 
X-Spam-Status: No, score=-6.599 tagged_above=-999 required=5 tests=[BAYES_00=-2.599, RCVD_IN_DNSWL_MED=-4]
Received: from mail.ietf.org ([64.170.98.32]) by localhost (core3.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id LIS5D4i4LIEp for <hybi@core3.amsl.com>; Fri, 29 May 2009 19:16:53 -0700 (PDT)
Received: from biscayne-one-station.mit.edu (BISCAYNE-ONE-STATION.MIT.EDU [18.7.7.80]) by core3.amsl.com (Postfix) with ESMTP id 40E273A67A5 for <hybi@ietf.org>; Fri, 29 May 2009 19:16:53 -0700 (PDT)
Received: from outgoing.mit.edu (OUTGOING-AUTH.MIT.EDU [18.7.22.103]) by biscayne-one-station.mit.edu (8.13.6/8.9.2) with ESMTP id n4U2IZbh022202 for <hybi@ietf.org>; Fri, 29 May 2009 22:18:35 -0400 (EDT)
Received: from find-waldo-now.local (corp-241.mountainview.mozilla.com [63.245.220.241]) (authenticated bits=0) (User authenticated as jwalden@ATHENA.MIT.EDU) by outgoing.mit.edu (8.13.6/8.12.4) with ESMTP id n4U2IYS1021943 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NOT) for <hybi@ietf.org>; Fri, 29 May 2009 22:18:35 -0400 (EDT)
Message-ID: <4A20976F.30108@mit.edu>
Date: Fri, 29 May 2009 19:18:23 -0700
From: Jeff Walden <jwalden@MIT.EDU>
User-Agent: Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10.4; en-US; rv:1.9.1b3pre) Gecko/20090223 Thunderbird/3.0b2
MIME-Version: 1.0
To: hybi@ietf.org
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 7bit
X-Scanned-By: MIMEDefang 2.42
Subject: [hybi] Errors in HTTP proxy examples in Web Socket protocol, 3.1 step 3
X-BeenThere: hybi@ietf.org
X-Mailman-Version: 2.1.9
Precedence: list
List-Id: Server-Initiated HTTP <hybi.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/listinfo/hybi>, <mailto:hybi-request@ietf.org?subject=unsubscribe>
List-Archive: <http://www.ietf.org/mail-archive/web/hybi>
List-Post: <mailto:hybi@ietf.org>
List-Help: <mailto:hybi-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/hybi>, <mailto:hybi-request@ietf.org?subject=subscribe>
X-List-Received-Date: Sat, 30 May 2009 02:16:53 -0000

The examples don't (explicitly) include the (required) port number in the authority part of the Request-Line.  Also, they're missing HTTP/1.1's (required) Host header.  They instead should be:

   CONNECT example.com:80 HTTP/1.1
   Host: example.com

and

   CONNECT example.com:80 HTTP/1.1
   Host: example.com
   Proxy-authorization: Basic ZWRuYW1vZGU6bm9jYXBlcyE=


Jeff

From ian@hixie.ch  Fri May 29 19:31:26 2009
Return-Path: <ian@hixie.ch>
X-Original-To: hybi@core3.amsl.com
Delivered-To: hybi@core3.amsl.com
Received: from localhost (localhost [127.0.0.1]) by core3.amsl.com (Postfix) with ESMTP id 0E22E3A67ED for <hybi@core3.amsl.com>; Fri, 29 May 2009 19:31:26 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -3.124
X-Spam-Level: 
X-Spam-Status: No, score=-3.124 tagged_above=-999 required=5 tests=[AWL=-0.525, BAYES_00=-2.599]
Received: from mail.ietf.org ([64.170.98.32]) by localhost (core3.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id xGvzkHmmTHdC for <hybi@core3.amsl.com>; Fri, 29 May 2009 19:31:25 -0700 (PDT)
Received: from looneymail-a2.g.dreamhost.com (caibbdcaaaaf.dreamhost.com [208.113.200.5]) by core3.amsl.com (Postfix) with ESMTP id 2B7D83A67A5 for <hybi@ietf.org>; Fri, 29 May 2009 19:31:25 -0700 (PDT)
Received: from hixie.dreamhostps.com (hixie.dreamhost.com [208.113.210.27]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by looneymail-a2.g.dreamhost.com (Postfix) with ESMTP id 218F216D40D; Fri, 29 May 2009 19:33:09 -0700 (PDT)
Date: Sat, 30 May 2009 02:33:08 +0000 (UTC)
From: Ian Hickson <ian@hixie.ch>
To: Jeff Walden <jwalden@MIT.EDU>
In-Reply-To: <4A20976F.30108@mit.edu>
Message-ID: <Pine.LNX.4.62.0905300231000.19521@hixie.dreamhostps.com>
References: <4A20976F.30108@mit.edu>
Content-Language: en-GB-hixie
Content-Style-Type: text/css
MIME-Version: 1.0
Content-Type: TEXT/PLAIN; charset=US-ASCII
Cc: hybi@ietf.org
Subject: Re: [hybi] Errors in HTTP proxy examples in Web Socket protocol, 3.1 step 3
X-BeenThere: hybi@ietf.org
X-Mailman-Version: 2.1.9
Precedence: list
List-Id: Server-Initiated HTTP <hybi.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/listinfo/hybi>, <mailto:hybi-request@ietf.org?subject=unsubscribe>
List-Archive: <http://www.ietf.org/mail-archive/web/hybi>
List-Post: <mailto:hybi@ietf.org>
List-Help: <mailto:hybi-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/hybi>, <mailto:hybi-request@ietf.org?subject=subscribe>
X-List-Received-Date: Sat, 30 May 2009 02:31:26 -0000

On Fri, 29 May 2009, Jeff Walden wrote:
>
> The examples don't (explicitly) include the (required) port number in 
> the authority part of the Request-Line.  Also, they're missing 
> HTTP/1.1's (required) Host header.  They instead should be:
> 
>   CONNECT example.com:80 HTTP/1.1
>   Host: example.com
> 
> and
> 
>   CONNECT example.com:80 HTTP/1.1
>   Host: example.com
>   Proxy-authorization: Basic ZWRuYW1vZGU6bm9jYXBlcyE=

Fixed, thanks.

-- 
Ian Hickson               U+1047E                )\._.,--....,'``.    fL
http://ln.hixie.ch/       U+263A                /,   _.. \   _\  ;`._ ,.
Things that are impossible just take longer.   `._.-(,_..'--(,_..'`-.;.'
