[whatwg] reply() extension to postMessage()

On Sat, 1 Mar 2008, Jonas Sicking wrote:
> > 
> > Because then you could only pass an endpoint across a pipe once. The 
> > idea is to be able to send both ends across pipes many times.
> 
> Passing an endpoint multiple times would create multiple clones anyway 
> so I don't see the advantage to just passing in a pipe and have a new 
> other end of the pipe being created every time? But I don't really see 
> the use case for this anyway? If you really need to have multiple things 
> sending you events you might as well create multiple pipes all using the 
> same event handlers.
> 
> The one thing that I agree you couldn't do with my proposal is to pass 
> both ends of a pipe around. You also couldn't pass one end multiple 
> times. But again, I'd like to hear what the use case is?
> 
> And even that could be done by proxying messages.

The main idea is to allow for capabilities-based messaging without 
proxying. For example, having a page negotiate a connection between two 
<iframe> widgets, and then stepping away from them. Or a handle to a 
worker being passed to a gadget in another domain, and the worker itself 
later delegating the work to another worker.

-- 
Ian Hickson               U+1047E                )\._.,--....,'``.    fL
http://ln.hixie.ch/       U+263A                /,   _.. \   _\  ;`._ ,.
Things that are impossible just take longer.   `._.-(,_..'--(,_..'`-.;.'

Received on Saturday, 1 March 2008 20:49:58 UTC