I have a Flowable<List<Item>>
for which I want to :
- Make an operation on each item
- After that, I want to make an operation on the whole resulted list.
This is not working now because it looks like is entering in an infinite loop::
return list.concatMap(list ->
Observable.fromIterable(list)
.map(item -> {
item.setValue(value);
return item;
}).toList().toFlowable()
.flatMap(updatedList -> mLocalDataSource.update(updatedList)))
.subscribeOn(Schedulers.io())
.observeOn(AndroidSchedulers.mainThread());