@uli Is there a better way? Or maybe I set up my pipeline wrong?
I need to receive a response from api server, parse the result into actions, and dispatch them into respective handler for each action. Some actions have multiple steps that I fanOut coroutines to handle them (like downloading files concurrently) and fanIn to process (one file at a time)... In the end I must modify the SyncResult object passed to me by android's SyncAdapter to report how many errors or successful steps while still keeping the Sync thread open the whole time.