Do people actually use Akka with Spring?

There is a lot of material on the internet about combining Akka with Spring.
Is this really used in practice?
Does anyone have actors with such complex implementation that the need to put them together with dependency injection for example?
Or is there some other value there?

This is my opinion only, but I tried a few small projects using Spring and Akka, but when I started a large one, I decided to go without Spring or any other DI tool. The only pieces of Spring I suspected I’d miss were JDBC templates (replaced with Apache DbUtils) and REST Templates (replaced with Akka HTTP) – dependencies were almost all constructor injected. A few were later broadcast (over the system event stream) to anyone who needed them – but everything was easy enough to do manually.

I believe the reason for it being simpler is that the Akka solution was much more focused on the business problem – with actors representing the domain rather than filling in slots in a framework. I didn’t need to wire together an “add item controller” with a “session repository” and “item repository” – the Session actor used event sourcing (no repository needed) and managed its own state (no business process controllers needed) and the ItemDataService actor was already created before any of the Session actors.

2 Likes

So basically if you remove the framework features Spring brings on top of basic DI, you can do without it, because you can assemble actors in a sufficiently decoupled way with simpler means.

Would you say that it is a bad decision to mix DI and actors since they are self-sufficient ways to structure an application?