Re: New Version Notification for draft-kamp-httpbis-structure-01.txt (fwd)
Kazuho Oku <kazuhooku@gmail.com> Thu, 17 November 2016 10:37 UTC
Return-Path: <ietf-http-wg-request+bounce-httpbisa-archive-bis2juki=lists.ie@listhub.w3.org>
X-Original-To: ietfarch-httpbisa-archive-bis2Juki@ietfa.amsl.com
Delivered-To: ietfarch-httpbisa-archive-bis2Juki@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id 1E66A1294D4 for <ietfarch-httpbisa-archive-bis2Juki@ietfa.amsl.com>; Thu, 17 Nov 2016 02:37:25 -0800 (PST)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -7.998
X-Spam-Level:
X-Spam-Status: No, score=-7.998 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, HEADER_FROM_DIFFERENT_DOMAINS=0.001, RCVD_IN_DNSWL_HI=-5, RCVD_IN_SORBS_SPAM=0.5, RP_MATCHES_RCVD=-1.497, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001] autolearn=ham autolearn_force=no
Authentication-Results: ietfa.amsl.com (amavisd-new); dkim=pass (2048-bit key) header.d=gmail.com
Received: from mail.ietf.org ([4.31.198.44]) by localhost (ietfa.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id JwPS6NGRIiXe for <ietfarch-httpbisa-archive-bis2Juki@ietfa.amsl.com>; Thu, 17 Nov 2016 02:37:23 -0800 (PST)
Received: from frink.w3.org (frink.w3.org [128.30.52.56]) (using TLSv1.2 with cipher DHE-RSA-AES128-SHA (128/128 bits)) (No client certificate requested) by ietfa.amsl.com (Postfix) with ESMTPS id 809CC129656 for <httpbisa-archive-bis2Juki@lists.ietf.org>; Thu, 17 Nov 2016 02:37:23 -0800 (PST)
Received: from lists by frink.w3.org with local (Exim 4.80) (envelope-from <ietf-http-wg-request@listhub.w3.org>) id 1c7K0z-0002xU-I0 for ietf-http-wg-dist@listhub.w3.org; Thu, 17 Nov 2016 10:33:57 +0000
Resent-Date: Thu, 17 Nov 2016 10:33:57 +0000
Resent-Message-Id: <E1c7K0z-0002xU-I0@frink.w3.org>
Received: from mimas.w3.org ([128.30.52.79]) by frink.w3.org with esmtps (TLS1.2:RSA_AES_128_CBC_SHA1:128) (Exim 4.80) (envelope-from <kazuhooku@gmail.com>) id 1c7K0u-0002vZ-5U for ietf-http-wg@listhub.w3.org; Thu, 17 Nov 2016 10:33:52 +0000
Received: from mail-wm0-f49.google.com ([74.125.82.49]) by mimas.w3.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.84_2) (envelope-from <kazuhooku@gmail.com>) id 1c7K0o-0002bT-40 for ietf-http-wg@w3.org; Thu, 17 Nov 2016 10:33:46 +0000
Received: by mail-wm0-f49.google.com with SMTP id t79so135535419wmt.0 for <ietf-http-wg@w3.org>; Thu, 17 Nov 2016 02:33:25 -0800 (PST)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc; bh=qxkg4Wy82J4y0GrhqUH2WSE3r870JnPBTu8CFZue6c8=; b=bz4L1SH9r5DgDjbxgC0Z3h3rT0nyRudbFyzyar2LSmGWwRDwspNlosfNr/qL8X+W70 e0Hvfm6wpH528BSrA5l1oEH4eTZg4gLwnek6TNPcxrvPcTo+p1yoQ/TcdjTLB7ADJyo5 RRhBkGgn8OruGCEOvqLJGS4k9Eq03PxBhrgpTF7NVGElGwsC0QX2QuxZ95kJILxqaq6p EBj2xIsgBq9VN71hkFGMulPcivDqWs4QKtuzCgE0zE6fmcxrGkOpJb09U0Gbg0oCz+g9 90yjDNjm/Qhagy5G+XTOEvhvQrliR2sq14aCJdzuPrOb3LvzxomjDEY3+w6/Bky7giFu WtQA==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc; bh=qxkg4Wy82J4y0GrhqUH2WSE3r870JnPBTu8CFZue6c8=; b=FmgcPuYEuBFYPN5io4iZ2o7bYL9oHpYhgdOVZTWJwPldJ3+TnwCAeK3y3DWd858QZy UZ1mAQvuqyY1f0w/q+cmpliIDv+Be3m7ilCxYrec9B3BSFeXkEZHVIljKrOECajyrZX8 6ZrSnsCSJuYMWGb1O1TRC2fRT/n6+7v4SykqE3ke4xA95Ci8nKDIagKMC0SvIJQNG0o8 FhizApByVfS+U1pHXrghFnzecXaNoVo6Nh0XswOJeBqI/r3OjmxkroIDa47mfTIRV5B+ KbUr20/9WS7EB5P5MaA0u3mIYNqjEaP7byjPgIeGpa1OnznFU0bbEx5LSFDvlouioSzc l2Rw==
X-Gm-Message-State: ABUngvetxVK4JJFYhgxEIugjS/U58zQeRJXZgTOf2Qg/UTt5TZ0c1blNUCRgBY+W4tTzmQnEx4G82VhUjPSSOQ==
X-Received: by 10.28.98.66 with SMTP id w63mr16777761wmb.142.1479378799485; Thu, 17 Nov 2016 02:33:19 -0800 (PST)
MIME-Version: 1.0
Received: by 10.194.32.1 with HTTP; Thu, 17 Nov 2016 02:33:18 -0800 (PST)
In-Reply-To: <83650.1479378061@critter.freebsd.dk>
References: <78354.1477853918@critter.freebsd.dk> <CANatvzx5RSnnN9ybqh6tRqKV=7NVO+PTpgAuVUU+6JuKGFtczg@mail.gmail.com> <20161117055345.GB9646@1wt.eu> <CANatvzwrPxyRPET5SO6fYGZ_6NnqToU9a630x1gjZXx5uAbeuw@mail.gmail.com> <83170.1479371676@critter.freebsd.dk> <CANatvzx1mASDCBKdFNWWHAK5SFB-wv5F0n+NvD0R7K9cRGMyBA@mail.gmail.com> <83650.1479378061@critter.freebsd.dk>
From: Kazuho Oku <kazuhooku@gmail.com>
Date: Thu, 17 Nov 2016 19:33:18 +0900
Message-ID: <CANatvzyUuVAeqzuV+6f-ovXTZB2T5KP5Azidmwu5soN4JGMtQA@mail.gmail.com>
To: Poul-Henning Kamp <phk@phk.freebsd.dk>
Cc: Willy Tarreau <w@1wt.eu>, HTTP Working Group <ietf-http-wg@w3.org>
Content-Type: text/plain; charset="UTF-8"
Received-SPF: pass client-ip=74.125.82.49; envelope-from=kazuhooku@gmail.com; helo=mail-wm0-f49.google.com
X-W3C-Hub-Spam-Status: No, score=-4.3
X-W3C-Hub-Spam-Report: AWL=-0.750, BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H3=-0.01, RCVD_IN_MSPIKE_WL=-0.01, RCVD_IN_SORBS_SPAM=0.5, SPF_PASS=-0.001, W3C_AA=-1, W3C_WL=-1
X-W3C-Scan-Sig: mimas.w3.org 1c7K0o-0002bT-40 6fb3b083aca749d614b18125fc081bc8
X-Original-To: ietf-http-wg@w3.org
Subject: Re: New Version Notification for draft-kamp-httpbis-structure-01.txt (fwd)
Archived-At: <http://www.w3.org/mid/CANatvzyUuVAeqzuV+6f-ovXTZB2T5KP5Azidmwu5soN4JGMtQA@mail.gmail.com>
Resent-From: ietf-http-wg@w3.org
X-Mailing-List: <ietf-http-wg@w3.org> archive/latest/32929
X-Loop: ietf-http-wg@w3.org
Resent-Sender: ietf-http-wg-request@w3.org
Precedence: list
List-Id: <ietf-http-wg.w3.org>
List-Help: <http://www.w3.org/Mail/>
List-Post: <mailto:ietf-http-wg@w3.org>
List-Unsubscribe: <mailto:ietf-http-wg-request@w3.org?subject=unsubscribe>
2016-11-17 19:21 GMT+09:00 Poul-Henning Kamp <phk@phk.freebsd.dk>: > -------- > In message <CANatvzx1mASDCBKdFNWWHAK5SFB-wv5F0n+NvD0R7K9cRGMyBA@mail.gmail.com> > , Kazuho Oku writes: > >>For example, consider the case in which I am writing a draft that >>passes an integer using Common Structure. >> >>Since Common Structure allows an integral number to be sent with a >>dot, a sender is permitted to send 100 as '100.00' > > So this is clearly something the draft needs to explain better. > > CS does not decide what values are legal and which are not, it only > helps you transport values safely across the wire. > > When you define your header you define the kind of values it accepts, > and if you say that "value X is an integer", it should be pretty > obvious to anybody that sending it as "100.0" is not OK. > > If you think people will not get that fine detail right, you can > add text to your header definition which drives the point home. > >>you would need to decode a floating point number even in the case >>where you only need to deal with integers. > > So this brings up an interesting efficiency detail related to the > HTTP1 serialization: > > You cannot tell the difference between an identifier and a number > by looking at the data on the wire, because RFC7230::token allows > both DIGIT, "." and "-". > > Your parser will therefore initially classify any "number" as > "identifier", and only once your application code tells it that it > expects an integer, will that string be interpreted as a number. > > That means that no numeric processing needs to happen until it > is unavoidable. > > (Any design I can imagine for a future HPACK/H3 semantic compression > will have the same property.) > > As I hint in 7.2 as "Future work", having the individual headers > defined in a machine readble format (a "schema") would allow us to > use programs to generate combined CS parser+validator for such a > header. Once we start people using CS to define new headers, I think I'd be likely writing a parser generator handle them, regardless of whether if a schema language is defined as a specification. The generated parser would just deserialize the properties that the application care of, while skipping unknown parameters. > However, history is particularly unkind to that concept, so I > left it in "Future work" and I think we should leave it there > for now. > >>My understanding is that most (if not all) headers that will use >>Common Structure would need to encode floating point numbers. > > I don't think so. > > First, just because they look like floating point numbers in the > H1 serialization, doesn't mean you have to process them as IEEE754 > in your application. > > If I recall right, the q= weights can be processed as integer > "milli-q", and still be compliant. In reality comparison of q= > weights is very often done as strings. > > Second, apart from q= and possibly future timestamps, I don't see > much call for fractional numbers anyhow[1]. > > All that said, it probably does makes good sense to have "integer" > as a special case of "number", like "ascii_string" is a subset of > "unicode_string", because it will make it easier for people > to specify their HTTP headers. Thank you for considering that. I think that would be a good move. > Poul-Henning > > [1] Somebody will undoubtedly use them for monetary values, but I > have a hard time seeing that make it into a published RFC for > many reasons. > > -- > Poul-Henning Kamp | UNIX since Zilog Zeus 3.20 > phk@FreeBSD.ORG | TCP/IP since RFC 956 > FreeBSD committer | BSD since 4.3-tahoe > Never attribute to malice what can adequately be explained by incompetence. -- Kazuho Oku
- New Version Notification for draft-kamp-httpbis-s… Poul-Henning Kamp
- Re: New Version Notification for draft-kamp-httpb… Julian Reschke
- Re: New Version Notification for draft-kamp-httpb… Poul-Henning Kamp
- Re: New Version Notification for draft-kamp-httpb… Kazuho Oku
- Re: New Version Notification for draft-kamp-httpb… Willy Tarreau
- Re: New Version Notification for draft-kamp-httpb… Kazuho Oku
- Re: New Version Notification for draft-kamp-httpb… Julian Reschke
- Re: New Version Notification for draft-kamp-httpb… Poul-Henning Kamp
- Re: New Version Notification for draft-kamp-httpb… Poul-Henning Kamp
- Re: New Version Notification for draft-kamp-httpb… Kazuho Oku
- Re: New Version Notification for draft-kamp-httpb… Willy Tarreau
- Re: New Version Notification for draft-kamp-httpb… Poul-Henning Kamp
- Re: New Version Notification for draft-kamp-httpb… Willy Tarreau
- Re: New Version Notification for draft-kamp-httpb… Poul-Henning Kamp
- Re: New Version Notification for draft-kamp-httpb… Poul-Henning Kamp
- Re: New Version Notification for draft-kamp-httpb… Kazuho Oku
- Re: New Version Notification for draft-kamp-httpb… Poul-Henning Kamp