https://kotlinlang.org logo
Title
f

fkrauthan

09/06/2020, 10:17 PM
Hey does anyone know a good AMQP library that works well with coroutines?
r

rrva

09/07/2020, 10:11 AM
you could probably use something that integrates with CompletableFuture.await() extension function
if there is no native coroutine implementation
however that scales differently since the completablefutures probably run on normal threads so its a seam between threads and coroutines
m

muliyul

09/07/2020, 12:21 PM
Coroutines can also run on threads too I don't see your point @rrva.
r

rrva

09/08/2020, 10:32 AM
what I meant was that with a coroutine-native implementation (where the library would be written in kotlin and exposes suspendable functions to the user) the callee would be guaranteed that the same resources in terms of thread pool size would be used when accessing the AMQP resource. With a solution where you call something that only returns CompletableFuture, you have to think about how those thread pools work
l

Luis Munoz

10/13/2020, 7:18 PM
Vertx