android - rajava,retrofit一个页面多个不相干请求
阿神
阿神 2017-04-18 09:28:01
0
2
587

一个页面包含4个不相干请求,如果用 rxjava 的 merge 或者 zip 会出现一个问题,就是如果其中一个请求报错了,其他的请求也无法继续。请问有办法解决吗?

阿神
阿神

闭关修行中......

reply all(2)
左手右手慢动作

If an error is reported, the onError method must be executed. There is an error handling function catch in RxJava, such as onErrorReturn() or onErrorResumeNext() or onExceptionResumeNext(). My idea is that if an error occurs, intercept it. Will this not affect other requests? As for request errors, you can add a retry mechanism.

迷茫

Observable.mergeDelayError

Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!