Java's `CyclicBarrier` is really nice, but using i...
# getting-started
j
Java's
CyclicBarrier
is really nice, but using it from Kotlin is not nice, since it's not coroutine-friendly. I've searched high and low, and haven't found a good alternative other than to roll my own. Has anyone run into this?
1
It's not coroutine-friendly because awaiting the barrier blocks the thread rather than suspending the coroutine.
a
🙌 1
j
This looks very promising! Thank you so much!
Confirmed this is exactly what I needed, and is working great
It let me delete 469 lines of custom
CyclicBarrier
implementation and tests, which was certainly worse than the Arrow version https://github.com/hudson155/kairo/pull/694
👍 1
🎉 2