Play2 vs Phoenix

Hi all

How would you compare Play2 and Phoenix?
Play2 with Scala.

Thanks

2 Likes

See this post where @sasajuric pointed me about some JVM specifics and proper way to perform benchmarks.

If you ever going to compare the performance, then I commend you to read the article, pay special attention to fifth point “Overload is not Capacity”. And it would be nice to hear from you about the results :slight_smile:

4 Likes

Having worked with both Play2 (Scala) and Phoenix, I personally prefer Phoenix.

Play2 was really fun around the 2.2 / 2.3 releases, but at some point there was some volatility around the ORM libraries. When 2.4 hit and the big restructuring happened (Dependency Injection was all of a sudden the solution to everything!) the framework ended up being a huge mess, with documentation largely outdated, old stuff that you were used to no longer working and no canonical guide to go on. Lost me completely at that point.

4 Likes

I don’t like Play2 (Scala , Java … the same mess), prefer http://spray.io/ if you need build simple rest API. There is also fun http://vertx.io/ project.

2 Likes

Here @Mandemus wrote about his Vert.x experience:

I played with it for awhile but in the end it was a lonely affair, with very little activity on their Google group.

1 Like

I assume that Elixir forum gives better support :slight_smile: .
But if you are from JVM land this is nice framework. Specially I see the recently added support for Scala and Kotlin language.

1 Like

As someone with little experience with web application frameworks, I found Phoenix more approachable than Play, even though I had more experience with Scala when I tried them both. This is mostly because the Play! documentation is sometimes lengthy, describing the concepts behind it rather than focusing on examples, but also because Play! seems to be somewhat of a moving target: Often, what you read in some tutorial or book doesn’t quite work because it was written for an earlier version.
Play! seems to be more accepted in the industry, however, which also has its advantages. For example, when I write a web application, I prefer to have a single, self-contained package that can be installed with a single command, including a systemd service to have the application start on boot. With Play!, you can use the sbt-native-packager to achieve just that, it only takes a few minutes to set up and requires no knowledge about Debian packages (if you choose to create a Debian package, that is. Other options, including Docker, are also available). Deployment with Phoenix on the other hand is a more complex topic.

1 Like

Using Play professionally. Wish I could kill it with fire. Play seems like the outcome of people who wanted to bring Rails to Scala without any regard for whether that was a good idea or not.

Phoenix, on the other hand, actively encourages “best practices”, and is actively built to work as idiomatic Elixir (with the current potential exception of in-phoenix-app umbrella projects, which mimics idiomatic Elixir instead).

3 Likes