You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Right now, the plugin's feature of request abortion (https://github.com/silkimen/cordova-plugin-advanced-http#abort) is not supported. When a request via HttpClient gets aborted (no active subscribers on observable), the request will still be completed, even though the response will not be used.
Environment
version of angular
version of ionic-native-http-connection-backend - 3.3.0
version of @ionic/angular - does not matter
version of @awesome-cordova-plugins/http - 5.43.0
Steps to reproduce
Integrate native http backend, create a request via httpClient, unsubscribe before request ends, observe the native request getting completed and not aborted.
Expected behaviour
Requests should be canceable via the requestId property returned by the plugin. In a completer function the requestId can be used to abort the request.
Actual behaviour
Since this implementation relies on the awesome-cordova wrapper, which wraps the plugins functionalities in a Promise, the possibility to cancel a request gets lost. If you unsubscribe from a request it will complete.
The text was updated successfully, but these errors were encountered:
Thank you a lot for this issue! I was not aware of the newly created abort functionality of the cordova-plugin-advanced-http, but I've been waiting for it for a while. Cheers, to @silkimen 💐
Unfortunately, I'm not sure when I'll have time to update ionic-native-http-connection-backend, because I'm busy with something else.
If you or anyone else have time to pick this one up, feel free to do that. I can provide support if needed. Otherwise, I'll pick it up myself when I'm less busy.
Subject of the issue
Right now, the plugin's feature of request abortion (https://github.com/silkimen/cordova-plugin-advanced-http#abort) is not supported. When a request via HttpClient gets aborted (no active subscribers on observable), the request will still be completed, even though the response will not be used.
Environment
Steps to reproduce
Integrate native http backend, create a request via httpClient, unsubscribe before request ends, observe the native request getting completed and not aborted.
Expected behaviour
Requests should be canceable via the
requestId
property returned by the plugin. In a completer function the requestId can be used to abort the request.Actual behaviour
Since this implementation relies on the awesome-cordova wrapper, which wraps the plugins functionalities in a Promise, the possibility to cancel a request gets lost. If you unsubscribe from a request it will complete.
The text was updated successfully, but these errors were encountered: