Win a copy of Reactive Streams in Java: Concurrency with RxJava, Reactor, and Akka Streams this week in the Reactive Progamming forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Liutauras Vilda
  • Junilu Lacar
  • Jeanne Boyarsky
  • Bear Bibeault
Sheriffs:
  • Knute Snortum
  • Tim Cooke
  • Devaka Cooray
Saloon Keepers:
  • Ron McLeod
  • Stephan van Hulst
  • Tim Moores
  • Tim Holloway
  • Carey Brown
Bartenders:
  • Piet Souris
  • Frits Walraven
  • Ganesh Patekar

When it comes to frameworks for web applications, which is better-Struts or JSF?

 
Ranch Hand
Posts: 91
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Please I would like to know which you would recommend among these two for any category of web applications.
Would it be preferable to use Struts or JSF?

Thank you for the usual quick replies.

Charles.
 
Enthuware Software Support
Posts: 4348
38
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Eventually, you will need to learn both. But I would suggest you to start with Struts not because it is better or worse but because it is still heavily used in the industry.
HTH,
Paul.
 
Rancher
Posts: 43011
76
  • Likes 2
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
This question can not be answered in general, so I very much disagree with Paul's answer. The answer may very well be "neither".

Note that the widely used version of Struts is Stuts 1, which has been dead (as a project) and thus obsolete (for new projects) for quite some time. Struts 2 is not nearly as widely used; I recommend to learn it only if you already know that you will need it.

As regards JSF, it has proponents and detractors. Most of its proponents seem to like it because it's part of JEE (not a good reason in my book, as other frameworks can easily be used with JEE), and not necessarily for its technical merits. Its detractors seem to have strong opinions about not liking it.
 
Paul Anilprem
Enthuware Software Support
Posts: 4348
38
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Ulf Dittmer wrote:This question can not be answered in general....


I have seen similar answer many times on this forum and I always find it annoying. You can always answer based on the information posted by the OP. Of course, the more information OP posts the more "correct" the answer can be. Why, you might even ask for the age of the poster to make your answer even more "correct". But that doesn't make any sense. I would rather OP ask further questions than the responder ask for more information.

OP's question is simple and I find such winding answers practically useless.
 
Marshal
Posts: 67287
170
Mac Mac OS X IntelliJ IDE jQuery Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I agree with Ulf.

No one will need to learn either; let alone both. While I've familiarized myself with both so that I can make informed decisions, I've never used either in a project. In fact, more than a handful of my jobs have been to take monstrosities developed in either (especially JSF) and refactor them into more manageable projects.

So while I would say that it's never a bad idea to learn something new, no one needs to learn either.

As to which is "better": that's unanswerable and subjective. My own opinion is obviously neither. If I have to recommend a framework, I'd recommend either of Play! or SpringMVC before Struts 1 or 2. And I'm on the record as thinking that JSF is a cancer that needs to be surgically excised from the face of the Earth.
 
Bear Bibeault
Marshal
Posts: 67287
170
Mac Mac OS X IntelliJ IDE jQuery Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Paul Anilprem wrote:You can always answer based on the information posted by the OP.


I do not see how Ulf's response fails to address the question that was asked; albeit with a differing opinion than yours.
 
Sheriff
Posts: 24654
58
Eclipse IDE Firefox Browser MySQL Database
  • Likes 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Paul Anilprem wrote:OP's question is simple...



Yes, it is. But simple questions don't necessarily have simple answers, or even any answers at all.
 
Sheriff
Posts: 11604
178
Hibernate jQuery Eclipse IDE Spring MySQL Database AngularJS Tomcat Server Chrome Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
In the past (6-7 years ago) I developed web applications with both Struts (version 1) and JSF. But today I would recommend neither for web application development. Without any doubt my recommendation is Spring MVC when you are looking for a framework to develop web applications. Since 2012 I develop mainly web applications and all of them were developed using Spring, Spring MVC and Hibernate.
 
Ranch Hand
Posts: 231
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Charles, depends on what you are seeking to build. There was a good answer provided here: http://stackoverflow.com/questions/2845271/struts-2-or-jsf which details the difference between Action Framework and Component Framework. Is your question purely from learning point of view?
 
It is an experimental device that will make my mind that most powerful force on earth! More powerful than this tiny ad!
Java file APIs (DOC, XLS, PDF, and many more)
https://products.aspose.com/total/java
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!