https://kotlinlang.org logo
Title
a

Alex Gotev

04/15/2020, 9:41 PM
Has somebody replaced a ThreadPoolExecutor + BlockingQueue with Coroutines? The Thread pool acts as a spooler for the blocking queue. Jobs can continue to arrive indefinitely while some of them are executed. Primarily each jobs does I/O, so I want to get rid of the current blocking solution in favor of a coroutine based solution. Right now I can control also the number of parallel jobs (which are tied to the number of threads) and wonder if I could still do the same with Coroutines. Any advice greatly appreciated!
o

octylFractal

04/15/2020, 9:43 PM
a

Alex Gotev

04/16/2020, 6:19 AM
Thank you! I'll give it a try