Take the 2-minute tour ×
Programmers Stack Exchange is a question and answer site for professional programmers interested in conceptual questions about software development. It's 100% free, no registration required.

I want to develop a big personal project using Play 2 Framework.

I am expert with Java language but it seems, with the few articles I read that Play 2 works perfectly and especially with Scala.

I've never worked with Scala but I already learned concept as closures, functional programming etc... Learning it would be interesting.

I am really motivated for but I wonder if there are some people who have started coding with Play2/Java and have changed for Play2/Scala that could explain their major concrete advantages.

share|improve this question
3  
I can't speak in the context of Play, but I can say this would be a great opportunity to learn Scala. I picked up Scala a few months ago and it has been great fun and is a very fun language to work with. It's concise, type safe, designed for concurrency/distribution, and comes with an awesome standard library. In addition, if your project involves working with databases, Typesafe's Slick looks pretty awesome as well. Akka (which I think Play uses) also has a prettier API for Scala than Java. –  adelbertc Nov 14 '12 at 2:54
2  
Learn Scala. The only problem is that subsequently you will never want to write Java again. –  kevin cline Nov 14 '12 at 3:22
add comment

closed as not constructive by gnat, Walter, ChrisF Nov 14 '12 at 20:45

As it currently stands, this question is not a good fit for our Q&A format. We expect answers to be supported by facts, references, or expertise, but this question will likely solicit debate, arguments, polling, or extended discussion. If you feel that this question can be improved and possibly reopened, visit the help center for guidance.If this question can be reworded to fit the rules in the help center, please edit the question.

1 Answer

up vote 1 down vote accepted

I've been using Play v1.2.x for almost a year and I've dabbled a little in Play 2.x.

You will most likely NOT learn Scala by picking up Play 2.x. what you'll learn is how to use Play's Scala templates/API (not the Scala language). You'll have to learn Scala separately as @kevin cline stated.

You still have the option of using Java in Play v2.x. I'm sticking with Play v1.2.5 for now. I will eventually switch to v2.x

the reasons to use Play 2.x:

  • You want to do development in Scala instead of Java
  • Your app needs to keep 10,000 or more concurrent connections open for 20 or more minutes, streaming data in real time… without consuming 10,000 threads in the JVM. (This use case is the entire reason for the development of Play 2.0)

    Cons of Play 2.x

  • Increased complexity
  • slower compile time
  • harder to debug

  • share|improve this answer
        
    Thanks :) So firstly, I will learn Scala with the famous Book "Programming in Scala, 2nd edition". Play 2 effectively interests me since my project would involve a huge numbers of concurrent connections. –  Mik378 Nov 14 '12 at 14:14
    add comment

    Not the answer you're looking for? Browse other questions tagged or ask your own question.