These are chat archives for ReactiveX/RxJava
RxJava – Reactive Extensions for the JVM – a library for composing asynchronous and event-based programs using observable sequences for the Java VM.
Singleto a POST api returning a
Completable. I am not able to achieve that. I posted a SO question but no help till now. Please suggest how to do this. https://stackoverflow.com/questions/53633071/how-to-pass-output-of-a-single-to-a-completable-in-rxjava
single.subscribe( r -> completableAPi(r).subscribe ... )but the code will be messy. I want to chain operations the way i mentioned in the SO
singleAPI.map(result -> completableAPI(result)it returns me a
Single<Completable>. My usecase is that i just want to return a
Completableon which i can subscribe.
Completable.fromSingle(...single<completable> here...)then it the completable call is ignored.
singleAPi.flatmapCompletable(result -> completableAPI(result)), I am able to get an object of type
Completablebut the inner call happens on the main thread even if i do
.subscribeOn(io())in the save observable too
RxJava2CallAdapterFactory.createWithScheduler(io())call, that assert that all request call are evaluated in the io scheduler