Future cancellation

Bill Frantz frantz at pwpconsult.com
Wed May 1 13:29:18 PDT 2013

On 5/1/13 at 11:13 AM, jackalmage at gmail.com (Tab Atkins Jr.) wrote:

>I think you're making this far too complicated.  It's much simpler than this:
>1. XHR is a very reasonable API to Future-ize.
>2. XHRs are cancellable.
>3. Ergo, we should have a cancellable Future subtype.

Why make it more complex than necessary. While a XHR 
implementation may wish to add a cancel operation, JS is a 
broader language than just the web. There are use cases that 
don't need cancel and they should not have to pay the costs of 
the additional communication paths that cancel will require.

With a simple promise, others can build objects which use the 
promise as an internal component and provide cancel or other 
useful operations. Leaving the implementations of these other 
operations to libraries will allow experimentation to proceed standardization.

Cheers - Bill

Bill Frantz        | Since the IBM Selectric, keyboards have gotten
408-356-8506       | steadily worse. Now we have touchscreen keyboards.
www.pwpconsult.com | Can we make something even worse?

More information about the es-discuss mailing list