Re: [hybi] frame length encoding

Pieter Hintjens <ph@imatix.com> Sat, 21 August 2010 20:03 UTC

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 7DD103A67B2 for <hybi@core3.amsl.com>; Sat, 21 Aug 2010 13:03:49 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -1.965
X-Spam-Level:
X-Spam-Status: No, score=-1.965 tagged_above=-999 required=5 tests=[AWL=0.012, 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 4s2hzCiat7UL for <hybi@core3.amsl.com>; Sat, 21 Aug 2010 13:03:48 -0700 (PDT)
Received: from mail-vw0-f44.google.com (mail-vw0-f44.google.com [209.85.212.44]) by core3.amsl.com (Postfix) with ESMTP id 33D9A3A67FE for <hybi@ietf.org>; Sat, 21 Aug 2010 13:03:48 -0700 (PDT)
Received: by vws10 with SMTP id 10so4486583vws.31 for <hybi@ietf.org>; Sat, 21 Aug 2010 13:04:22 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:mime-version:sender:received :in-reply-to:references:from:date:x-google-sender-auth:message-id :subject:to:cc:content-type; bh=EwE6IUlw8ikV/drH5mqZmAXHry4/1+AL6jdZWBzxoTQ=; b=x958+JiOYrIS2BOyR6sIVpLSc5DYS+KkRb42fiVY8jwAGLXXpaPwV+3EfC5mAabFpf 31/sKxiNymAz/cliSynBXPkDQR38uhofHxBBd2wNkfwQhGEbJcIVVywx5OzqsrGhEFLM 0YRk+mY4PxCBNvpW7DlM/QMnHse2LBwitagDQ=
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; b=oDMzxdnR8ME3fTGpLKCps9iElUPQXlBKmact2wfjushVRCZMc4VK12KVWiO4+u+uOx Frfuf1A3Glt2Ljz/+N7Cwp2WVSpuyZiSArYZqgKjMTWiHX28u7olky8Y16mcUxQEyZLH u7gk/MNCIenJhywwevKGorWCxLVZnZquGT25M=
Received: by 10.220.62.5 with SMTP id v5mr1904743vch.244.1282421062196; Sat, 21 Aug 2010 13:04:22 -0700 (PDT)
MIME-Version: 1.0
Sender: pieterh@gmail.com
Received: by 10.220.167.17 with HTTP; Sat, 21 Aug 2010 13:04:02 -0700 (PDT)
In-Reply-To: <20ef7ed5e135c57c1ee5a741658b9d98.squirrel@sm.webmail.pair.com>
References: <AANLkTimKbmcpgx8k0uXUWvCO=8w9pPrtV=3y4qh6363k@mail.gmail.com> <alpine.DEB.2.00.1008212037190.27211@tvnag.unkk.fr> <AANLkTinrsT+wV48nHvVW_1ChGYffkq7jisU2-PZnMyKg@mail.gmail.com> <alpine.DEB.2.00.1008212123460.27211@tvnag.unkk.fr> <20ef7ed5e135c57c1ee5a741658b9d98.squirrel@sm.webmail.pair.com>
From: Pieter Hintjens <ph@imatix.com>
Date: Sat, 21 Aug 2010 22:04:02 +0200
X-Google-Sender-Auth: wuRA8GtPxsd_B1tWsendvvnUtcQ
Message-ID: <AANLkTinR2bUmzWY+8wuXz3y2uEdmvKZDn4dxnSs7xDa5@mail.gmail.com>
To: shelby@coolpage.com
Content-Type: text/plain; charset="ISO-8859-1"
Cc: Hybi <hybi@ietf.org>
Subject: Re: [hybi] frame length encoding
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, 21 Aug 2010 20:03:50 -0000

On Sat, Aug 21, 2010 at 9:54 PM, Shelby Moore <shelby@coolpage.com> wrote:

> No because for any file on disk larger than 4GB, we will have to move the
> entire file through the CPU, when we wouldn't had to otherwise...

More pragmatically it means every single WebSocket implementation,
both readers and writers, have to either impose a 4GB limit on frames,
or else have extra functionality to detect large frames and fragment
and defragment them.  It creates significant additional cost and risk
and interoperability concerns, and the benefits are to win 4 bytes
with negligible benefit.

It's not just disk files, my box has 8GB and it's more than a year
old.  Loading, processing, and sending 8GB chunks of memory will be
banal in a few years' time.  That really should remain as simple as
sending a 8KB chunk of memory.

-- 
-
Pieter Hintjens
iMatix - www.imatix.com