Re: [hybi] [Uri-review] ws: and wss: schemes

Jamie Lokier <jamie@shareable.org> Wed, 19 August 2009 16:46 UTC

Return-Path: <jamie@shareable.org>
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 C57F93A69FB; Wed, 19 Aug 2009 09:46:30 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -4.182
X-Spam-Level:
X-Spam-Status: No, score=-4.182 tagged_above=-999 required=5 tests=[AWL=-1.583, BAYES_00=-2.599]
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 Jbevx1yfPZh3; Wed, 19 Aug 2009 09:46:29 -0700 (PDT)
Received: from mail2.shareable.org (mail2.shareable.org [80.68.89.115]) by core3.amsl.com (Postfix) with ESMTP id BBF6D3A682E; Wed, 19 Aug 2009 09:46:29 -0700 (PDT)
Received: from jamie by mail2.shareable.org with local (Exim 4.63) (envelope-from <jamie@shareable.org>) id 1MdoIk-0000LW-7T; Wed, 19 Aug 2009 17:46:18 +0100
Date: Wed, 19 Aug 2009 17:46:18 +0100
From: Jamie Lokier <jamie@shareable.org>
To: noah_mendelsohn@us.ibm.com
Message-ID: <20090819164618.GA991@shareable.org>
References: <20090814213754.GD12021@shareable.org> <OF3B15D497.B76ABF1A-ON85257617.0058A11E-85257617.0059BD1A@lotus.com>
MIME-Version: 1.0
Content-Type: text/plain; charset="us-ascii"
Content-Disposition: inline
In-Reply-To: <OF3B15D497.B76ABF1A-ON85257617.0058A11E-85257617.0059BD1A@lotus.com>
User-Agent: Mutt/1.5.13 (2006-08-11)
Cc: hybi@ietf.org, uri-request@w3.org, Kristof Zelechovski <giecrilj@stegny.2a.pl>, uri@w3.org, uri-review@ietf.org, 'David Booth' <david@dbooth.org>
Subject: Re: [hybi] [Uri-review] ws: and wss: schemes
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: Wed, 19 Aug 2009 16:46:30 -0000

noah_mendelsohn@us.ibm.com wrote:
> Jamie Lokier writes:
> 
> > A HTTP URL does not tell you the type of resource, only where to 
> > find _a_ resource.
> 
> This misses an important point about http URIs and the HTTP protocol. 
> Although the URL itself does not tell you the type of the resource, the 
> response to an HTTP GET does indeed tell you the type of the entity body. 
> So, you can access any such URI on the Web, and you'll either: (1) know 
> how to interpret the response, I.e. because you recognize the Content-type 
> and know how to process data of that type, or (2) will reliably discover 
> that it's of a type you don't know how to process.  These characteristics 
> are what make it possible for you to click on any link, and know that your 
> browser won't misinterpret the results, even as new Content-types are 
> deployed (well, let's not get into the sniffing discussion just now). It's 
> also what allows search engine spiders to interpret the results returned 
> from GETs on pretty much any http link.

Firstly, I agree with the usefulness of Content-Type, which is why I
think it would be helpful if the WebSockets protocol defined something
equivalent, even just a single string to identify the protocol at the
start.

Secondly, this thread has talked about protocols on top of protocols
(because every WebSockets application will be one).  Given a URI, you
cannot tell from Content-Type whether that URI supports WebDAV, and
you cannot tell whether that URI accepts POSTs to submit new blog
entries - just to pick two widely used examples.

That requires another level of descriptive metadata, which
Content-Type does not provide and is not always available in any other
form.  But, just like people can enter a "blog posting" URI into their
mobile phone, there will be reasons why people enter WebSockets URIs
into applications, with no way for the application to verify the
protocol except by trying it.

> So, this is a desirable characteristic for Web resources, and it's
> one of the things that HTTP gives you.  Indeed, the whole Web is
> designed so that you can start with RFC 3986, the specification for
> URIs, and using the references to which it (recursively) delegates,
> discover how to correctly interact with and interpret responses from
> any resource on the Web.  Under the auspices of the W3C TAG, I
> prepared a "finding" [1] that goes into more detail on these issues
> and their implications.

In other words, I disagree with the above.  You can't find which
particular protocols are overlaid on top of HTTP at every findable URI
by the existing mechanisms, and it's unlikely that will ever be
possible.

> I do 
> think it is an interesting question (I think I've raised it before), 
> whether we expect search engines to come on ws/wss links,
> and if so, 
> whether it's valuable for those search engines to be able to discover 
> information about the resources identified by those links.

It's an intersting question, but please don't get too sidetracked from
the (imho) more important question of ensuring that specific web
applications can connect to WebSockets resource whose URI is provided
by a third party, with a reasonable level of safety and security.

-- Jamie