top | item 43480701

(no title)

nikitaga | 11 months ago

I meant FP libraries like Cats Effect / FS2 / ZIO et al. – they don't really do the things that Akka / Pekko is very good at, such as multi-machine parallelism, but the conventional wisdom nowadays seems to be that it's easier to start with those libraries and progress to Pekko if you ever need that, rather than architect the system with Pekko from the start when you don't need its power.

I don't know if I personally agree with that, I've had a better experience with Akka (even raw actors) than with FP libraries, but what I mentioned is definitely the general vibe in the publicly active part of the community that's I'm observing. We gotta keep in mind that there are lots of companies and devs that never talk about what they're doing in public, so of course my perception is biased by that.

My own expertise is shifting more and more to the frontend / Scala.js these days, so please forgive/correct any inaccuracies.

discuss

order

vvillena|11 months ago

The assumption that Cats Effect / FS2 / ZIO is easier than Akka / Pekko is questionable. There's the assumption that the Akka ecosystem requires the entire system to be built using the various features the ecosystem offers, when in reality it easily scales down to simple microservices just as well, if that's the only option or the overall preference.

One reason to reach for the pure functional libraries is a desire to avoid some of the many footguns Akka / Pekko has. For a long time, using Akka meant not being able to rely on the Scala type system for checking messages sent between actors, and for the people attracted to Scala due to the advanced type system, this was a deal-breaking drawback.

All in all, the FP libraries and the actor system libraries are almost direct opposite approaches to problem solving.

renegade-otter|11 months ago

Well, Akka/Pekko is typed now. There is a learning curve to Akka, but it took me 3-4 weeks to get my system working. I can't imagine doing it with pure FP, it would break my brains.

There are inspiring talks on the capabilities of actor-based streams, like this one: https://www.youtube.com/watch?v=ilhImUjF53A

As someone said - these are very cool but niche capabilities that companies do not talk about. It's almost like a secret weapon in the sea of over-engineering and hype.

dionian|11 months ago

these are two different problems (remoting/cluster vs local concurrency). Shardcake + ZIO is way better than Akka remoting + akka