These are some experiments in what suspendable functions and channels can mean for Akka.
I wrote an article about it.
- use channels to send messages to an Akka actor and receive them.
- a channel as inbox in the actor implementation. Calling async methods as suspending functions.
- a channel as inbox in the actor implementation with exception handling.
Also in there:
- use suspendable functions to call (ask) akka actor.
- use functions with receiver for an imperative seeming api.
- use extension functions to document the request response protocol for the actor.
- make actorsystem available in coroutine context.
- make akka actor be the coroutine context so it can call suspendable functions. The coroutines involved have the lifecycle of the actor.
Kotlin actors send a CompletableDeferred in a message to an actor. We can do this for Akka. But that won't work across a cluster of course. So it's of limited use.