Uh oh!
There was an error while loading. Please reload this page.
feat($http): add support for timeout promises - #2529
Conversation
IgorMinar
commented
May 1, 2013
I like this quite a bit since unlike all the other attempts it doesn't try to introduce an explicit bi-directional communication between deferred and a promise. Can you add the missing higher level test please? I'll then highlight this PR one angular-dev for api review. I'm quite hopeful about this PR this time around :) |
dbinit
commented
May 1, 2013
Excellent! I'll get some more tests in there ASAP. Looks like I'll have to add timeouts to the mock version of $httpBackend, but it shouldn't take long. |
dbinit
commented
May 1, 2013
Ok, tests added. I did my best to follow the style/spirit of existing code with this (while keeping changes minimal). Let me know if there are any issues there. |
If the timeout argument is a promise, abort the request when it is resolved. Implemented by adding support to $httpBackend service and $httpBackend mock service. Closesangular#1159
dbinit
commented
May 6, 2013
Hi @IgorMinar. Any update on this? |
petebacondarwin
commented
May 10, 2013
|
petebacondarwin
commented
May 10, 2013
I'll ping the dev team on this. |
aaronleesmith
commented
May 15, 2013
Waiting for this to go through to build a feature. Any update? |
vojtajina
commented
May 20, 2013
LGTM. |
vojtajina
commented
May 20, 2013
🚢 it |
IgorMinar
commented
May 20, 2013
Landed as 9f4f593! Thanks so much for being patient with us. If you don't have an angular t-shirt please fill out this form and we'll send you one: http://goo.gl/075Sj |
If the timeout argument is a promise, abort the request when it is resolved.
Implemented by adding support to $httpBackend service and $httpBackend mock service.
This is yet another approach to the $http cancel issue (see #2452 and #2523). Obviously there is still a lack of consensus on how to handle it (see kriskowal/q#64), so I propose this as an alternative.
Closes#1159