Re: [hybi] hum #3: Message
Jack Moffitt <jack@collecta.com> Thu, 05 August 2010 22:17 UTC
Return-Path: <metajack@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 002F33A693F for <hybi@core3.amsl.com>; Thu, 5 Aug 2010 15:17:03 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -1.956
X-Spam-Level:
X-Spam-Status: No, score=-1.956 tagged_above=-999 required=5 tests=[AWL=0.021, 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 gjGCf1Dc75jF for <hybi@core3.amsl.com>; Thu, 5 Aug 2010 15:17:02 -0700 (PDT)
Received: from mail-qy0-f172.google.com (mail-qy0-f172.google.com [209.85.216.172]) by core3.amsl.com (Postfix) with ESMTP id 24E913A687F for <hybi@ietf.org>; Thu, 5 Aug 2010 15:17:02 -0700 (PDT)
Received: by qyk1 with SMTP id 1so3518148qyk.10 for <hybi@ietf.org>; Thu, 05 Aug 2010 15:17:32 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:sender:received :in-reply-to:references:date:x-google-sender-auth:message-id:subject :from:to:cc:content-type:content-transfer-encoding; bh=1IPjQAwVD5frIjLXwa4G9Fc3nnO31k0rcdTTZF/nUtU=; b=FqI1pxSnathg9kkg0BQ2JFT9xu6b7D/DvAJ5lFzO9uchb/TKPO26WE8F4CYPz74uRg BLrMEukT1KVP5+eqDdtY2vKGpagDvInpk91gGlZW2/Rerua0Q0poR1lBKNlJ4BIuXJmZ UeIq4r6VevuOurfSgztcKnCYIkXwz2NstCeIY=
DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:sender:in-reply-to:references:date :x-google-sender-auth:message-id:subject:from:to:cc:content-type :content-transfer-encoding; b=C4HKsQ/lN/fdycxB1P/DTqeWI0PS00mSGCeOGxgNGB4wl1kWG2HqMKexTfmrbg87g7 O1PR3Xp74RYGYm2LW/so2xJ8M/ECjsIPFRf8PV7Eg4cLb3kISetz8drxcyYXCNQpkMik +m2GlhMBD2X7H4ZfWjCNc3hKFb3K2F5MxViTE=
MIME-Version: 1.0
Received: by 10.224.5.199 with SMTP id 7mr5383214qaw.241.1281046652501; Thu, 05 Aug 2010 15:17:32 -0700 (PDT)
Sender: metajack@gmail.com
Received: by 10.229.18.147 with HTTP; Thu, 5 Aug 2010 15:17:32 -0700 (PDT)
In-Reply-To: <01098AD0-FBF4-4A61-B565-947C95722BAA@apple.com>
References: <4C5AE93D.4040803@ericsson.com> <Pine.LNX.4.64.1008051758290.5947@ps20323.dreamhostps.com> <AANLkTik0kbh14s2JZARY2MFh0iNGV7H+B4Px4yG+wX44@mail.gmail.com> <71BCE4BF-D3F6-4F94-BE76-306BDF6A2E67@apple.com> <Pine.LNX.4.64.1008051930160.5947@ps20323.dreamhostps.com> <4C5B1695.6070704@gmx.de> <F8E2F702-9F74-4316-B3B2-D5A731409ABF@apple.com> <4C5B2029.90403@gmx.de> <AANLkTim1WeCRfcPxXUNQcVhb4+t_TtDQDv2bXaxOQ=bk@mail.gmail.com> <01098AD0-FBF4-4A61-B565-947C95722BAA@apple.com>
Date: Thu, 05 Aug 2010 16:17:32 -0600
X-Google-Sender-Auth: XeXv-eAY6WbUXJESo-T6dkeHN9A
Message-ID: <AANLkTi=qQSND5BvUP5+P=wJ7E8SG6NncGZH8U8+VYwZ0@mail.gmail.com>
From: Jack Moffitt <jack@collecta.com>
To: Maciej Stachowiak <mjs@apple.com>
Content-Type: text/plain; charset="ISO-8859-1"
Content-Transfer-Encoding: quoted-printable
Cc: "hybi@ietf.org" <hybi@ietf.org>
Subject: Re: [hybi] hum #3: Message
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, 05 Aug 2010 22:17:03 -0000
>> The kernel's sendfile() is responsible for a lot of the HTTP server >> optimization for static resources, and for this case, I think it is >> true that doing any framing that shows up in the middle of the file >> would lead to a big inefficiency. > > I think there's definitely use cases for transferring large static resources over WebSocket. Consider syncing a media library where items may have been added on either end. Sync seems like a pretty likely target for WebSocket. You will want to do large static transfers in both directions, and it seems better to use the existing warmed-up WebSocket TCP connection than to make fresh HTTP connections. After doing some research, it appears that sendfile() and its ilk use ranges anyway, and that many implementations already chunk them (nginx seems to do so first to get to a sector boundary, and then at a size of 2G-1). Losing sendfile() completely would be bad, but even in the chunked case, you can still do sendfile() for each chunk. Of course, more calls to sendfile() are worse than fewer, but I imagine most of the efficiency is retained as all memory copies in userland are still eliminated. I don't have the data on the difference, but if it comes down to this particular issue being the deciding factor for consensus, such data can be obtained. With this in mind, I'm in favor of fixed length headers, which implies chunking and multiple frames per message in some cases. jack.
- Re: [hybi] hum #3: Message Jamie Lokier
- [hybi] hum #3: Message Salvatore Loreto
- Re: [hybi] hum #3: Message Ian Hickson
- Re: [hybi] hum #3: Message John Tamplin
- Re: [hybi] hum #3: Message Douglas Otis
- Re: [hybi] hum #3: Message Maciej Stachowiak
- Re: [hybi] hum #3: Message Dave Cridland
- Re: [hybi] hum #3: Message Ian Hickson
- Re: [hybi] hum #3: Message Julian Reschke
- Re: [hybi] hum #3: Message John Tamplin
- Re: [hybi] hum #3: Message Jack Moffitt
- Re: [hybi] hum #3: Message Bjoern Hoehrmann
- Re: [hybi] hum #3: Message Willy Tarreau
- Re: [hybi] hum #3: Message Bjoern Hoehrmann
- Re: [hybi] hum #3: Message Maciej Stachowiak
- Re: [hybi] hum #3: Message Julian Reschke
- Re: [hybi] hum #3: Message Roberto Peon
- Re: [hybi] hum #3: Message Maciej Stachowiak
- Re: [hybi] hum #3: Message Jack Moffitt
- Re: [hybi] hum #3: Message Willy Tarreau
- Re: [hybi] hum #3: Message Maciej Stachowiak
- Re: [hybi] hum #3: Message Maciej Stachowiak
- Re: [hybi] hum #3: Message Dave Cridland
- Re: [hybi] hum #3: Message Maciej Stachowiak
- Re: [hybi] hum #3: Message Dave Cridland
- Re: [hybi] hum #3: Message Greg Wilkins
- Re: [hybi] hum #3: Message Dave Cridland
- Re: [hybi] hum #3: Message Jack Moffitt
- Re: [hybi] hum #3: Message Ian Fette (イアンフェッティ)
- Re: [hybi] hum #3: Message Ian Fette (イアンフェッティ)
- [hybi] Background info: Properties of sendfile() Jamie Lokier
- Re: [hybi] hum #3: Message Jamie Lokier
- Re: [hybi] Background info: Properties of sendfil… Roy T. Fielding
- Re: [hybi] Background info: Properties of sendfil… Jamie Lokier
- Re: [hybi] Background info: Properties of sendfil… Greg Wilkins
- Re: [hybi] Background info: Properties of sendfil… Roberto Peon
- Re: [hybi] hum #3: Message Scott Ferguson
- Re: [hybi] Background info: Properties of sendfil… Jamie Lokier
- Re: [hybi] Background info: Properties of sendfil… Greg Wilkins
- Re: [hybi] Background info: Properties of sendfil… Willy Tarreau
- Re: [hybi] Background info: Properties of sendfil… Maciej Stachowiak
- Re: [hybi] Background info: Properties of sendfil… Willy Tarreau
- Re: [hybi] hum #3: Message Pieter Hintjens
- Re: [hybi] hum #3: Message Arman Djusupov
- Re: [hybi] hum #3: Message Pieter Hintjens
- Re: [hybi] hum #3: Message Julian Reschke
- Re: [hybi] hum #3: Message Arman Djusupov
- Re: [hybi] Background info: Properties of sendfil… Jack Moffitt
- Re: [hybi] hum #3: Message John Tamplin
- Re: [hybi] hum #3: Message Arman Djusupov
- Re: [hybi] hum #3: Message Scott Ferguson
- Re: [hybi] hum #3: Message Scott Ferguson
- Re: [hybi] hum #3: Message Patrick McManus
- Re: [hybi] hum #3: Message Scott Ferguson
- Re: [hybi] hum #3: Message Patrick McManus
- Re: [hybi] Background info: Properties of sendfil… Roberto Peon
- Re: [hybi] Background info: Properties of sendfil… Jamie Lokier
- Re: [hybi] hum #3: Message Dave Cridland
- Re: [hybi] hum #3: Message Dave Cridland
- Re: [hybi] hum #3: Message Douglas Otis
- [hybi] Impact of mandatory chunking (was Re: Back… Maciej Stachowiak
- Re: [hybi] Impact of mandatory chunking (was Re: … Jack Moffitt
- Re: [hybi] hum #3: Message Pieter Hintjens
- Re: [hybi] Impact of mandatory chunking (was Re: … Maciej Stachowiak
- Re: [hybi] hum #3: Message Scott Ferguson
- Re: [hybi] hum #3: Message Willy Tarreau
- Re: [hybi] hum #3: Message Scott Ferguson
- Re: [hybi] hum #3: Message Roberto Peon
- Re: [hybi] hum #3: Message Willy Tarreau
- Re: [hybi] hum #3: Message Scott Ferguson
- Re: [hybi] hum #3: Message Pieter Hintjens
- Re: [hybi] hum #3: Message Greg Wilkins
- Re: [hybi] hum #3: Message Pieter Hintjens
- Re: [hybi] hum #3: Message Martin Sustrik
- Re: [hybi] hum(s) followup Maciej Stachowiak
- [hybi] hum(s) followup Salvatore Loreto
- Re: [hybi] hum(s) followup Pieter Hintjens
- Re: [hybi] hum(s) followup Salvatore Loreto