W3C home > Mailing lists > Public > public-webapps@w3.org > April to June 2009

Re: XHR and the storage mutex

From: Anne van Kesteren <annevk@opera.com>
Date: Mon, 04 May 2009 16:52:40 +0200
To: "Ian Hickson" <ian@hixie.ch>
Cc: public-webapps@w3.org
Message-ID: <op.utet92fl64w2qv@annevk-t60>
On Thu, 26 Mar 2009 09:50:27 +0100, Ian Hickson <ian@hixie.ch> wrote:
> HTML5 now has a "storage mutex" concept to cope with cookies being set in
> a multiprocess UA architecture without having scripts be exposed to race
> conditions.
>
> This affects XHR in a couple of ways.
>
> For both sync and async XHR, we should add a must-level requirement that
> UAs are to "obtain the storage mutex" (term of art defined in HTML5)
> before setting cookies.
>
> For sync XHR, we should add a must-level requirement that UAs are to
> "release the storage mutex" (storage mutex is a term of art defined in
> HTML5) at the start of the sync process and again immediately after
> setting cookies.

XMLHttpRequest is currently completely transparent to cookies. Maybe I can "simply" use the "fetch" algorithm as defined by HTML5?

Looking at that algorithm, how do I hook into it? E.g. for synchronous requests I want to wait until the request has completed (though I want to handle redirects, network errors, user aborting the request, etc.). For asynchronous requests it is mostly the same but I also want to dispatch events. Do these events require a new task source?


-- 
Anne van Kesteren
http://annevankesteren.nl/
Received on Monday, 4 May 2009 14:53:25 GMT

This archive was generated by hypermail 2.3.1 : Tuesday, 26 March 2013 18:49:31 GMT