Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Choosing a java web framework 2011 [closed]

My question is based on the following question: Choosing a Java Web Framework now? ..only one year later.

The reason for my question is that plenty has happened in one year, play framework has matured etc., and I want to know whats the hot thing today. What are the advantages and disadvantages of todays frameworks.

like image 790
Skurpi Avatar asked Jun 06 '11 15:06

Skurpi


2 Answers

focusing on Java frameworks, it depends on your aim (as everything in IT!)

  • On products for big companies, you either go with Java EE or the standard Struts/Spring/Hibernate. They are proven stacks, the scalability needs in that environment are meet by those stacks and being stateful can be relevant in that environment. Besides, they apply a new version of "No one was fired by buying IBM" with the apps (Play, Scala, what's that?)

  • For your personal projects, no commercial aim, just or fun, any framework you like. Lift, Play, whatever.

  • For a startup, I would recommend either Lift or Play. I personally like Play more, but YMMV. Both are agile frameworks that simplify development and give a quick turnaround. Perfect match for a startup. The differences (stateless vs stateful, etc) are what you should check before deciding.

On Scala vs Java, again it depends. Unless you are lucky, you won't be allowed to use Scala in a corporate environment (slowly being spread though). For your own project, it doesn't matter. For startup, choose the one you know the best. I know, learning is appealing, but if you have 6 months experience as hobbyist in Scala and 5 years of commercial Java experience, the time and pain on creating your project in Scala won't be worth it.

like image 118
Pere Villega Avatar answered Oct 20 '22 11:10

Pere Villega


JSP is a legacy tech, JSF is like a dinosaur, it's stateful and component based. If you want to develop high traffic distributed apps that can scale tens, hundreds, thousands of nodes, prefer stateless frameworks over component based stateful ones. Stateless frameworks can scale easily. Wicket, Tapestry and Lift are stateful, too. There is Click framework but it doesn't have an innovation nor velocity. Struts was good but it's an old framework now, Spring mvc 3 is better than struts. Yes, Spring mvc was good, but now there is much more better Play! Spring become like Java EE in time, on the other hand Play is dead easy framework with a great community and documantation. It's future is bright. It has lots of features in the core (and its very light) and also there are lots of modules written for play (like rails gems). In the last release, it got websockets, depenency management, db version management, far better scala module,...

Especially, new play scala templating is dead easy, type safe with a state of art syntax (like asp.net mvc razor) with a great performance as you can see in the test http://www.jtict.com/blog/rails-wicket-grails-play-lift-jsp/ (play is fastest in the test)

You can use both java and scala with play, but in my opinion scala is a better language than java and compete with C#, Ruby, Python with new generation features (java cannot), so I prefer scala with play. Lift is a scala framework, too, but it's more and more complicated than play and highly stateful.

Also, your platform and language selection is great. As an experienced .net developer I don't recommend asp.net webforms nor asp.net mvc, always prefer platform independent open source technologies. Python/Django and Ruby/Rails are slow and not type safe. PHP and Perl are legacy techs. The best platform today is jvm (.net works only on windows and mono killed by attachmate), so you're on the right path.

like image 3
sirmak Avatar answered Oct 20 '22 11:10

sirmak