Re: [hybi] method of allocation of reserved bits to extensions

Greg Wilkins <gregw@intalio.com> Wed, 25 May 2011 02:40 UTC

Return-Path: <gregw@intalio.com>
X-Original-To: hybi@ietfa.amsl.com
Delivered-To: hybi@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id 097A4E078C for <hybi@ietfa.amsl.com>; Tue, 24 May 2011 19:40:04 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -2.927
X-Spam-Level:
X-Spam-Status: No, score=-2.927 tagged_above=-999 required=5 tests=[AWL=0.050, BAYES_00=-2.599, FM_FORGED_GMAIL=0.622, RCVD_IN_DNSWL_LOW=-1]
Received: from mail.ietf.org ([64.170.98.30]) by localhost (ietfa.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id o4lu7Rum+nqH for <hybi@ietfa.amsl.com>; Tue, 24 May 2011 19:40:03 -0700 (PDT)
Received: from mail-vw0-f44.google.com (mail-vw0-f44.google.com [209.85.212.44]) by ietfa.amsl.com (Postfix) with ESMTP id 4F767E0751 for <hybi@ietf.org>; Tue, 24 May 2011 19:40:03 -0700 (PDT)
Received: by vws12 with SMTP id 12so6599072vws.31 for <hybi@ietf.org>; Tue, 24 May 2011 19:40:02 -0700 (PDT)
MIME-Version: 1.0
Received: by 10.52.31.37 with SMTP id x5mr6405727vdh.264.1306291202392; Tue, 24 May 2011 19:40:02 -0700 (PDT)
Received: by 10.52.187.71 with HTTP; Tue, 24 May 2011 19:40:02 -0700 (PDT)
In-Reply-To: <BANLkTi=57EYWnuOv3n=crHsgC5t3x=PPkA@mail.gmail.com>
References: <BANLkTi=vOQDtL5GobitKe8yiUoQFb2go_Q@mail.gmail.com> <BANLkTikaOXg0u+4d8Ly6OxUQ7PFUU=udgQ@mail.gmail.com> <BANLkTikiUkivJitZGU-+q6wBfJ3VW45F8g@mail.gmail.com> <BANLkTindmLQ0KE6K5qUX2ue+=hoLUaznLA@mail.gmail.com> <BANLkTim9w83iSY-TH1yuVAUXxypJk_tmrw@mail.gmail.com> <BANLkTimnMBwNgP_e29exT6dUkp60s2xU3g@mail.gmail.com> <BANLkTi==RTfqaYFT3CQs1pM5Tb501rk2Vg@mail.gmail.com> <BANLkTinqQiMQ4N1vWjyCe682BmdisW-=KA@mail.gmail.com> <BANLkTik1a6CEA8LiiLgsnBt9qHCaybmWfg@mail.gmail.com> <4DBA3809.4010004@oracle.com> <CA566BAEAD6B3F4E8B5C5C4F61710C11402DB23F@TK5EX14MBXW603.wingroup.windeploy.ntdev.microsoft.com> <BANLkTim8dkW3R2R1ukAqwkXOM0=uqfiPmA@mail.gmail.com> <4DD61D35.10404@warmcat.com> <BANLkTi=57EYWnuOv3n=crHsgC5t3x=PPkA@mail.gmail.com>
Date: Wed, 25 May 2011 12:40:02 +1000
Message-ID: <BANLkTi=hP1CPNE+3PSHUTWcBHW_WPxCBQw@mail.gmail.com>
From: Greg Wilkins <gregw@intalio.com>
To: Brian <theturtle32@gmail.com>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
Cc: Hybi <hybi@ietf.org>, Alan Coopersmith <alan.coopersmith@oracle.com>, "jg@freedesktop.org" <jg@freedesktop.org>, Gabriel Montenegro <Gabriel.Montenegro@microsoft.com>, Brodie Thiesfield <brodie@jellycan.com>
Subject: Re: [hybi] method of allocation of reserved bits to extensions
X-BeenThere: hybi@ietf.org
X-Mailman-Version: 2.1.12
Precedence: list
List-Id: Server-Initiated HTTP <hybi.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/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, 25 May 2011 02:40:04 -0000

The simplest solution is to say that the 3 bits (and spare opcodes) in
the framing are reserved for future versions of the protocol - ie off
bounds to all extensions.

Extensions that want to send bits and extra opcodes will always have
to allocated bytes in the payload to carry them.

Then we have two choices - come up with an allocation scheme in the
spec (eg based on ordering like I've suggested), that may save a few
bits per frame;  or we could leave this to the extensions to do their
own allocation (minimum 1 octect for extensions wanting flags and/or
opcodes).   I tend to agree that the bit savings might not be worth
the effort to specify such a system, specially if we have a
frame-deflate extension that would compress all those wasted bits
anyway.

The only outcome I'm strongly against is the status quo - where we
have a few scarce resources with no fair share mechanism defined.
This will just result in unfair market forces being used to make
defacto allocations of those bits (and opcodes for that matter).   It
is better not to have them than to have them with no fair share
policy.

cheers



On 21 May 2011 04:05, Brian <theturtle32@gmail.com> wrote:
> This seems fine to me too, but a bit more complicated than just
> letting extensions prepend a byte for themselves to the payload data.
> Honestly.. quibbling over wasting 7 bits by allocating a whole byte in
> this day and age seems silly, even for things like cell phones.  My
> cell phone (iPhone on AT&T in Los Angeles) is routinely able to
> transfer data at over a megabit per second (and even faster when I get
> out of the city).  So if there are a small handfull of "wasted" bytes
> in the payload to accommodate extension data/flags, nobody's really
> going to notice.
>
> I would support the dynamically allocated flags mechanism that can
> dynamically add more bytes to accomodate more extensions, but I just
> think it seems a little unnecessary.
>
> Brian
>
> On Fri, May 20, 2011 at 12:50 AM, "Andy Green (林安廸)" <andy@warmcat.com> wrote:
>> On 05/20/2011 07:42 AM, Somebody in the thread at some point said:
>>>
>>> Gabriel
>>>
>>> I'm concerned that if we really restrict usage of the reserved bits,
>>> then we will force extensions into using whole bytes at the start of
>>> the payload, when they really only want 1 bit.  If we really do get
>>> into the situation where we have many extensions, then we could have
>>> many wasted bits.
>>>
>>> How about just having a mechanism that if we can allocated as many
>>> reserved bits as we like, and if more than 3 are allocated then extra
>>> bytes are prepended to the payload (as needed) for the extra bits.
>>> Thus we could have unlimited extensions needing unlimited bits.
>>>
>>> If a client doesn't want to play that game, then all it need do is
>>> never handshake with extensions that need more than 3 bits.
>>
>> Sounds good to me.
>>
>> This idea of reserved bits being misered is not only unnecessary but it is
>> really inefficient - it'll lead to only special, big, connected players
>> being able to use them and because they are permanently allocated to
>> particular extensions in that model, there will always be a desire to
>> withhold them "for later".
>>
>> Dynamic allocation way anyone can randomly decide their extension will use
>> them, no central allocation is needed and multiple extensions using reserved
>> bits will always play well (plus or minus other doubts about extension
>> ordering not related to reserved bits).
>>
>> -Andy
>> _______________________________________________
>> hybi mailing list
>> hybi@ietf.org
>> https://www.ietf.org/mailman/listinfo/hybi
>>
>