Sagas in Akka Serverless?

Hello Everyone,

Very excited to be participating in the Akka Serverless Private Beta to see how well it can be used to implement subsystems using CQRS.

Of course, a lot of the required infrastructure, like event sourcing, is there because it’s how Cloudstate works but other parts are still emerging. I’ve discussed additional Read Models with Leon and the infrastructure needed for those seems to be coming through Google Cloud Pub/Sub.

However, one aspect of CQRS that I can’t seem to figure out is how sagas (aka process managers) would be implemented in Akka Serverless. How can we make a service that responds to events and produce commands, not as we generally do the other way around. Any suggestions? Examples?


1 Like

Ok, I can see now that Actions (stateless services) can subscribe to events and publish commands.

However, I thought that Sagas are generally stateful, i.e. they need to remember where they are in the process.

So, I guess Sagas needs to be a Service that can subscribe to events and publish commands, sort of a stateful Action?