Re: [hybi] Random Responses
Mridul Muralidharan <mridulm80@yahoo.com> Mon, 13 April 2009 19:47 UTC
Return-Path: <mridulm80@yahoo.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 BEA6D3A6A06 for <hybi@core3.amsl.com>; Mon, 13 Apr 2009 12:47:49 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -2.25
X-Spam-Level:
X-Spam-Status: No, score=-2.25 tagged_above=-999 required=5 tests=[AWL=0.349, 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 pOoJpA9mniz3 for <hybi@core3.amsl.com>; Mon, 13 Apr 2009 12:47:48 -0700 (PDT)
Received: from n5-vm1.bullet.mail.in.yahoo.com (n5-vm1.bullet.mail.in.yahoo.com [202.86.4.130]) by core3.amsl.com (Postfix) with SMTP id D96B73A67D8 for <hybi@ietf.org>; Mon, 13 Apr 2009 12:47:47 -0700 (PDT)
Received: from [202.86.4.171] by n5.bullet.mail.in.yahoo.com with NNFMP; 13 Apr 2009 19:48:57 -0000
Received: from [203.104.18.52] by t2.bullet.in.yahoo.com with NNFMP; 13 Apr 2009 19:48:57 -0000
Received: from [127.0.0.1] by omp113.mail.in2.yahoo.com with NNFMP; 13 Apr 2009 19:48:57 -0000
X-Yahoo-Newman-Property: ymail-3
X-Yahoo-Newman-Id: 352872.8940.bm@omp113.mail.in2.yahoo.com
Received: (qmail 1444 invoked by uid 60001); 13 Apr 2009 19:48:57 -0000
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoo.com; s=s1024; t=1239652137; bh=FA7VWcVOSOAelK152brB35sOuFzEzRxA48D0C9zdDQQ=; h=Message-ID:X-YMail-OSG:Received:X-Mailer:Date:From:Subject:To:Cc:MIME-Version:Content-Type:Content-Transfer-Encoding; b=ryyFDMql3u/TqNcn0lthJOrhqkhgH4Kp1FpPUvXhd9c634HWClMHdeSAHsKPFTwRuCpCmZa8W54zpT/2P5hMhm4juaX8tEKEvwKK7w1pliIaSxBMpw2Q/fXvqlamZyF5GRPyQrammlp4LS3EIowU63ZZHWT1LdRudjndbjoxF1I=
DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=s1024; d=yahoo.com; h=Message-ID:X-YMail-OSG:Received:X-Mailer:Date:From:Subject:To:Cc:MIME-Version:Content-Type:Content-Transfer-Encoding; b=OYLGlrXqruKwifsmw8dXrdhTVb20972een7tqlb6JC1PW5UnVQLHcI9pNem2o54XmqAb3Xj6N5ZLldpD6wEPrdOWxBPx1L0w5sAc/S5mTvEBsOh1mIs8igfX9yHXj5n5NEFm942BqVo2Cwaaz4qRAGp6KTuRAaC0+UVFAN2vPPA=;
Message-ID: <251941.1265.qm@web95411.mail.in2.yahoo.com>
X-YMail-OSG: v3SZB60VM1n1.ZEt8vqon0hztVEqRAfDZtTvzdnM69LmwHjunWzLL0V4BCzXYd1KJKaepQSkT2r0Nz4mNcFwTdKT9sRv051vB6cqNHSz_YV6ReUGSGs00MyDBZJCBqIHm.eD8SNMmrOg7ouvYEMfYPo.d0edtcrLwz14DgCixrdDxsPrRorBub0r51Gh4bkB07UJK0v7lTpnUA--
Received: from [122.167.176.126] by web95411.mail.in2.yahoo.com via HTTP; Tue, 14 Apr 2009 01:18:57 IST
X-Mailer: YahooMailClassic/5.2.15 YahooMailWebService/0.7.289.1
Date: Tue, 14 Apr 2009 01:18:57 +0530
From: Mridul Muralidharan <mridulm80@yahoo.com>
To: Greg Wilkins <gregw@webtide.com>, Jamie Lokier <jamie@shareable.org>
MIME-Version: 1.0
Content-Type: text/plain; charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable
Cc: hybi@ietf.org
Subject: Re: [hybi] Random Responses
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, 13 Apr 2009 19:47:49 -0000
--- On Mon, 13/4/09, Jamie Lokier <jamie@shareable.org> wrote: > From: Jamie Lokier <jamie@shareable.org> > Subject: Re: [hybi] Random Responses > To: "Greg Wilkins" <gregw@webtide.com> > Cc: hybi@ietf.org > Date: Monday, 13 April, 2009, 3:02 AM > Greg Wilkins wrote: > > Generally agreeing with all your points. Yet the > attributes you > > describe do sound pretty much like BEEP protocol - or > at least > > beep framing. > > > > BEEP is very much a HTTP style protocol with addition > of > > bidirectionality, multiple response requests and > multiple > > channels over a single connection. > > Yes, although BEEPs channels are unnecessarily expensive > (in latency) > to create on demand. Please see below. > > > If BEEP was extended with a few default assumptions > (eg > > UTF-8 text body if no content type specified), then it > would > > approach the byte efficiency of websocket, while > preserving > > the extensibility and flexibility of HTTP. > > > > If the security and authentication aspects of BEEP > were > > stripped, then a pretty simply protocol would remain. > > > > IF I was forced to pick a winner.... then I'd > certainly > > look very closely at BEEP or a BEEP derivative. > > I've looked closely at BEEP for this, and I agree, BEEP has > some very > good things which should be copied. > > Unfortunately its channel setup is expensive (latency, not > bandwidth), > and often you'd want a channel per message in flight. > That forces you > to either accept the channel setup latency, or queue > messages behind > each other in the same way that HTTP pipelining forces > messages to > block behind each other. Neither is ideal. > > There is a BEEP extension to create sub-channels on demand > without > having to request one, which is closer to ideal behaviour > when you > have a new message to send. But it unnecessarily > constrains the > ordering of messages. (I asked the author to relax > this, but he > didn't see any point for his applications and suggested > there are > other protocols to choose from if I need that. I > don't see the point > in the constraint.) > > What I think would be ideal, and it's been mentioned > already as > "asynchronous HTTP", is: > > HTTP or simplified-HTTP message headers and > body. > Bidirectional - either side can send requests > and responses. > Channel id attached to each message. > Chunked encoding, with channel id attached to > each chunk. > Per channel flow control exactly like BEEP > over TCP profile. > Request/response id attached to each > message. > Request/response id matches responses out of > order to requests. > Pure messages with no response allowed, using > "no-response" r/r id. > All the above features are optional. > > When you make those features optional, it degrades > gracefully to > HTTP pipelining, then to HTTP persistent connections. > > Also by making features optional, it is much easier to > implement just > the subset of features you need, or plug in a > feature-complete > implementation when you need all of them. > > That provides the message/event protocol some people are > asking for, > and also provides the request/response protocol some people > are asking > for, does both bidirectionally, and over a single socket, > and with > multiple applications sharing the same socket if they > want. > > It's efficient too, if you regard HTTP as efficient. > They're about > the same overhead. Latency is sometimes better than > HTTP, because it > doesn't have pipeline blocking like HTTP. Proxy > buffering > requirements are about the same as HTTP, in particular they > are > bounded similarly. What I seem to be missing here is the need to create a BEEP channel for each request/response. That would definitely be expensive (probably unusably so). What I am thinking of is, if the channel creation becomes more 'application' oriented - as in, one channel per widget/app/other granularity on top of the beep channel - then wont we not have a better usage ? Kind of like, various widgets on a page sharing the same underlying BEEP session each using its own channel to communicate to server (I think DOJO's comet protocol did have some notion of channels when I had glanced at it a couple of years back). Non-async request/response within a beep channel is similar to pipelining in http - unless previous request is processed and response sent, the next is not handled - or did I miss something here ? The sync behavior is per channel - it is async across channels. So I guess it depends on how the channel usage is modeled - as you and others mentioned, if each request/response is going to be a new channel, the costs of setup and the latency could be very high - but if we 'prescribe' some rules or suggestions of channel usage - then the cost becomes pretty low for long running channels. Note that I am not actively advocating BEEP (though it might look that way :-) ), it is just that BEEP seems to me to be designed for and already handles a bunch of the usecases mentioned here. A few things we might drop could be - tls, if already over http, SASL - if already authenticated http session, etc - the resulting profile could be pretty lightweight (and might address the latency issues). If the client requirement issue is a problem (need for xml, etc), it might be worthwhile to think about alternative framing rules. Regards, Mridul > > -- Jamie > _______________________________________________ > hybi mailing list > hybi@ietf.org > https://www.ietf.org/mailman/listinfo/hybi > Cricket on your mind? Visit the ultimate cricket website. Enter http://beta.cricket.yahoo.com
- [hybi] Random Responses Mark Lentczner
- Re: [hybi] Random Responses Ian Hickson
- Re: [hybi] Random Responses Peter Saint-Andre
- Re: [hybi] Random Responses Mark Lentczner
- Re: [hybi] Random Responses Mike Dierken
- Re: [hybi] Random Responses Paul Prescod
- Re: [hybi] Random Responses Paul Prescod
- Re: [hybi] Random Responses rektide
- Re: [hybi] Random Responses Greg Wilkins
- Re: [hybi] Random Responses Mridul Muralidharan
- Re: [hybi] Random Responses Jamie Lokier
- Re: [hybi] Random Responses Mridul Muralidharan
- Re: [hybi] Random Responses Jamie Lokier
- Re: [hybi] Random Responses Jamie Lokier
- Re: [hybi] Random Responses Jamie Lokier
- Re: [hybi] Random Responses Greg Wilkins
- Re: [hybi] Random Responses Mridul Muralidharan