Hi, I'm using RNFB 0.8.1 to download a file, where the download can take pretty long (sometimes 30secs).
Even if I don't pass in the timeout option, I see, that RNFB after 30secs not finished REST Call, retries the call.
Is it possible to disable the retry?
I also tried react-native-fs which downloads files, too, without retry when timeouts happen. But I like, that this library downloads the files simultaneously.
Another point: When I send a 408: Request timeout with the server, the Fetch Promise doesn't reject.
Is it possible to just reject then and cancel the retry?
Thanks!
Anyways, keep up the good work, it's awesome that you made the whole node fs api available for react native!!
@timsuchanek , thank you for your information 馃憤 I think this behavior does not look right. I'll try to fix this problem once I have time. Besides, does it happen on both IOS and Android?
Wow, fast answer :)
Currently only developing on android, so for iOS I can't say anything yet
@timsuchanek , I've done a quick fix (https://github.com/wkh237/react-native-fetch-blob/commit/8961f106fdf3b2ead8958dfb96f9ade628348fd7) and a simple test case, please refer to the links.
The fix will be launched in next release (0.8.2) 馃槒
Looks like the retry on 408 behavior is a default mechanism okhttp/pull/2302, we can't prevent it from happening, but the promise will only reject once.
Most helpful comment
Wow, fast answer :)
Currently only developing on android, so for iOS I can't say anything yet