Re: [hybi] Questions and comments on draft-hybi-thewebsocketprotocol-10

Willy Tarreau <w@1wt.eu> Mon, 18 July 2011 08:08 UTC

Return-Path: <w@1wt.eu>
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 17BC021F8B78 for <hybi@ietfa.amsl.com>; Mon, 18 Jul 2011 01:08:03 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -6.19
X-Spam-Level:
X-Spam-Status: No, score=-6.19 tagged_above=-999 required=5 tests=[AWL=-4.147, BAYES_00=-2.599, HELO_IS_SMALL6=0.556]
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 wPxe1EJSzTww for <hybi@ietfa.amsl.com>; Mon, 18 Jul 2011 01:08:02 -0700 (PDT)
Received: from 1wt.eu (1wt.eu [62.212.114.60]) by ietfa.amsl.com (Postfix) with ESMTP id 362AB21F8B79 for <hybi@ietf.org>; Mon, 18 Jul 2011 01:08:01 -0700 (PDT)
Received: (from willy@localhost) by mail.home.local (8.14.4/8.14.4/Submit) id p6I87xeJ002615; Mon, 18 Jul 2011 10:07:59 +0200
Date: Mon, 18 Jul 2011 10:07:59 +0200
From: Willy Tarreau <w@1wt.eu>
To: Greg Wilkins <gregw@intalio.com>
Message-ID: <20110718080759.GA2444@1wt.eu>
References: <4C26A6A5-DA13-45A3-9DBA-D2515DF923CD@mnot.net> <CAH_y2NHf6=8-CN_CVUKy=KH7yRcm1_4jzQAf7jt=qpQBeFqbpw@mail.gmail.com>
Mime-Version: 1.0
Content-Type: text/plain; charset=iso-8859-1
Content-Disposition: inline
Content-Transfer-Encoding: 8bit
In-Reply-To: <CAH_y2NHf6=8-CN_CVUKy=KH7yRcm1_4jzQAf7jt=qpQBeFqbpw@mail.gmail.com>
User-Agent: Mutt/1.4.2.3i
Cc: Mark Nottingham <mnot@mnot.net>, "hybi@ietf.org HTTP" <hybi@ietf.org>
Subject: Re: [hybi] Questions and comments on draft-hybi-thewebsocketprotocol-10
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: Mon, 18 Jul 2011 08:08:03 -0000

On Mon, Jul 18, 2011 at 05:50:28PM +1000, Greg Wilkins wrote:
> On 18 July 2011 17:06, Mark Nottingham <mnot@mnot.net> wrote:
> > In other words, I'd like to understand things a bit more before making LC comments; there may be good reasons for the few things I saw that raised my eyebrows.
> 
> _this response is non-normative_
> 
> > 1) I missed the end of the handshake saga; can someone speak to why GET was chosen over, say, OPTIONS? Roy seems to have strong feelings about that (see recent discussion on HTTPbis).
> 
> I think we went with GET because Roy was not able to well communicate
> his concerns.   He's done a better job in the recent thread in
> httpbis, and I now understand that he is concerned about the
> outstanding semantic GET.

I would add that there was a GET very early in the specification, when
the protocol was not even HTTP compatible yet. It dates back the era
where it was desirable to use an HTTP-like protocol that was easy to
parse by a simple script. Now we're more in line with HTTP and despite
all the discussions on GET vs OPTIONS, it appeared that there was no
real preference for one vs the other, so it was suggested that this
would not change unless there is a valid reason.

> However I still don't understand why he
> thinks OPTION is any better, as it still is a request that requires a
> semantic response.   In either case I think that websockets should be
> free to define an implicit response (eg 204 No Content) is represented
> by a successful handshake.

Alternatively we could consider that the server's hello is the response
to the request.

> > 2) The Upgrade token has no version; e.g., from the examples in 1.2:
> >    Upgrade: websocket
> > Why? The protocol version seems to be carried in the Sec-WebSocket-Version header; could it not be moved (or copied) to the upgrade token?
> 
> I think we are only just coming around to the acceptance that we
> really do need a version beyond the draft stage.  The version was put
> in a header as it was originally only considered needed to distinguish
> drafts.  If it is going to be there to stay, then perhaps the
> protocol/version format would be better.

I too find it more useful to have the version in the Upgrade header than
anywhere else. For intermediaries it can be very useful to know the version
from the Upgrade header because they can decide what processing to start
depending on what they see there.

Regards,
Willy