Re: HTTP Layer rework and PUSH_PROMISE contents

Mike Belshe <mike@belshe.com> Sat, 29 June 2013 00:56 UTC

Return-Path: <ietf-http-wg-request@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 5353B21F9DC1 for <ietfarch-httpbisa-archive-bis2Juki@ietfa.amsl.com>; Fri, 28 Jun 2013 17:56:41 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -9.976
X-Spam-Level:
X-Spam-Status: No, score=-9.976 tagged_above=-999 required=5 tests=[BAYES_00=-2.599, FM_FORGED_GMAIL=0.622, HTML_MESSAGE=0.001, RCVD_IN_DNSWL_HI=-8]
Received: from mail.ietf.org ([12.22.58.30]) by localhost (ietfa.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id rx1JWFdMS9V8 for <ietfarch-httpbisa-archive-bis2Juki@ietfa.amsl.com>; Fri, 28 Jun 2013 17:56:35 -0700 (PDT)
Received: from frink.w3.org (frink.w3.org [128.30.52.56]) by ietfa.amsl.com (Postfix) with ESMTP id E29A921F9DC0 for <httpbisa-archive-bis2Juki@lists.ietf.org>; Fri, 28 Jun 2013 17:56:34 -0700 (PDT)
Received: from lists by frink.w3.org with local (Exim 4.72) (envelope-from <ietf-http-wg-request@listhub.w3.org>) id 1UsjS8-0005O9-IE for ietf-http-wg-dist@listhub.w3.org; Sat, 29 Jun 2013 00:55:48 +0000
Resent-Date: Sat, 29 Jun 2013 00:55:48 +0000
Resent-Message-Id: <E1UsjS8-0005O9-IE@frink.w3.org>
Received: from maggie.w3.org ([128.30.52.39]) by frink.w3.org with esmtp (Exim 4.72) (envelope-from <mike@belshe.com>) id 1UsjRt-0005Mv-Ac for ietf-http-wg@listhub.w3.org; Sat, 29 Jun 2013 00:55:33 +0000
Received: from mail-bk0-f45.google.com ([209.85.214.45]) by maggie.w3.org with esmtps (TLS1.0:RSA_ARCFOUR_SHA1:16) (Exim 4.72) (envelope-from <mike@belshe.com>) id 1UsjRs-0001YA-G8 for ietf-http-wg@w3.org; Sat, 29 Jun 2013 00:55:33 +0000
Received: by mail-bk0-f45.google.com with SMTP id je9so997693bkc.32 for <ietf-http-wg@w3.org>; Fri, 28 Jun 2013 17:55:06 -0700 (PDT)
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type:x-gm-message-state; bh=g5QFCdH/43ztkLOLxljgrDCZRAtETQjGHffbPaRy1VI=; b=AVm9YArXxxWlsLdXBqxoSagNxlckpoUW0ZRae6mzkkHlrdxTiHc48A6t/nYkxQirUk qjEb+OWwb+ZasHHZyIedhgV4olachQnIXHsVgEL9prlANxF62T6W7ALdukHcHEV+oqxU mo1IEVpGIsdkKFaR2//zgt/k90275Eh8RoIG66NsSmz968iOxeIuld+WTjQZMLVBLMCD MlFp+ugOM6RvjmBX45ipbhzqGBoJIEVwBoZ7Sh6r3jjvdycZpCuovYR0VvrE/Q6tXVFL PpfUYzFouiDp3DHh6iTb8olyBzk/e9XKHR4t3lPhq3aFzj8Otl75lEo4EWfll0Qk118W Lqew==
MIME-Version: 1.0
X-Received: by 10.204.50.206 with SMTP id a14mr2092089bkg.64.1372467306022; Fri, 28 Jun 2013 17:55:06 -0700 (PDT)
Received: by 10.204.168.130 with HTTP; Fri, 28 Jun 2013 17:55:05 -0700 (PDT)
In-Reply-To: <15a394809da64b188945aa51ac0265b4@BY2PR03MB025.namprd03.prod.outlook.com>
References: <15a394809da64b188945aa51ac0265b4@BY2PR03MB025.namprd03.prod.outlook.com>
Date: Fri, 28 Jun 2013 17:55:05 -0700
Message-ID: <CABaLYCteDG6LrdoRJZAa8TCA2BdSx1epjZ41UFgFOnP_YHcZXw@mail.gmail.com>
From: Mike Belshe <mike@belshe.com>
To: Mike Bishop <Michael.Bishop@microsoft.com>
Cc: HTTP Working Group <ietf-http-wg@w3.org>
Content-Type: multipart/alternative; boundary="001a11c379223e216704e0407288"
X-Gm-Message-State: ALoCoQmev/5QFxoKDRi5BSk0AfbbBrPHsRjn/TRlOOlffr26TLY2JuSCJ71JGFgJsCvFGCMvJY/+
Received-SPF: none client-ip=209.85.214.45; envelope-from=mike@belshe.com; helo=mail-bk0-f45.google.com
X-W3C-Hub-Spam-Status: No, score=-3.8
X-W3C-Hub-Spam-Report: AWL=-3.100, HTML_MESSAGE=0.001, RCVD_IN_DNSWL_LOW=-0.7
X-W3C-Scan-Sig: maggie.w3.org 1UsjRs-0001YA-G8 231cab8f87baaa6cfa735b732f6f28c1
X-Original-To: ietf-http-wg@w3.org
Subject: Re: HTTP Layer rework and PUSH_PROMISE contents
Archived-At: <http://www.w3.org/mid/CABaLYCteDG6LrdoRJZAa8TCA2BdSx1epjZ41UFgFOnP_YHcZXw@mail.gmail.com>
Resent-From: ietf-http-wg@w3.org
X-Mailing-List: <ietf-http-wg@w3.org> archive/latest/18402
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>

On Fri, Jun 28, 2013 at 5:07 PM, Mike Bishop
<Michael.Bishop@microsoft.com>wrote:

>  In draft-ietf-httpbis-http2.xml:****
>
> >  ****
>
> > +        <t>****
>
> > +          The server can choose to send one or more push promises****
>
> > +          associated with the response. These notify the client that ****
>
> > +          the server intends to deliver additional resources to the client****
>
> > +          as specified in <xref target="PushResources" />. If the server****
>
> > +          sends PUSH_PROMISE frames, those MUST be sent prior to sending ****
>
> > +          any header blocks or DATA frames that reference the promised resources.****
>
> > +          For instance, if the server receives a request for a document****
>
> > +          containing embedded links to multiple image files, and the ****
>
> > +          server chooses to push those additional images to the client, ****
>
> > +          all of the push promises MUST be sent prior to sending the DATA frames ****
>
> > +          that contain the image links. Likewise, if the server pushes ****
>
> > +          resources referenced by the header block (i.e. using Link headers), ****
>
> > +          the server MUST send the push promises before sending the header****
>
> > +          block.****
>
> You're upgrading a SHOULD in the current spec to a MUST. Has this been
> discussed on-list?****
>
> This is part of minimizing races where the client makes the request for a
pushed resource before the server gets around to pushing it.

If the server has the intent to push, it really needs to do so as early as
possible.

I prefer the MUST.  From the client point of view, this means that once
you've received a reference to a resource, you know definitively whether or
not a server will push that resource.


> Speaking as the http.sys owner for Windows, this concerns me. We don't
> know the content of the entity body fragments or response headers an
> application hands us, only the order. The only way we can definitively
> comply with this MUST is to make all PUSH_PROMISE frames precede all DATA
> or HEADERS frames. As a SHOULD, we're free to leave proper behavior to the
> app using our APIs, while maintaining non-optional protocol compliance at
> our layer.
>
The reality is that you have no way to check whether a resource is
referenced or not...  unless you build a fully compliant javascript engine,
simulate all possible paths, etc...  :-)

So from this perspective, I agree with you - there is no way for middleware
to enforce correctness.  On the good news side, the spec does not specify
any retaliatory behavior upon receipt of resources which arrive after they
are referenced....

Mike