aspose file tools*
The moose likes JSF and the fly likes Struts v/s JSF Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Spring in Action this week in the Spring forum!
JavaRanch » Java Forums » Java » JSF
Bookmark "Struts v/s JSF " Watch "Struts v/s JSF " New topic
Author

Struts v/s JSF

zaxxon25
Ranch Hand

Joined: Feb 26, 2005
Posts: 35
Suppose i am having an exisiting project in struts. What are the specific advantages i will get by migrating that project to JSF. As far i have seen JSf is providing advantages just on the presentation layer . I think this is very small point in convicing client to migrate his current struts application to JSF.
Gregg Bolinger
GenRocket Founder
Ranch Hand

Joined: Jul 11, 2001
Posts: 15299
    
    6

I'd never suggest migrating a Struts app to JSF. I *might* suggest starting new project using JSF rather than Struts. But why change what works?


GenRocket - Experts at Building Test Data
Jonas Jacobi
Author
Greenhorn

Joined: Apr 04, 2006
Posts: 25
There are more to it than meets the eye, but I would probably not migrate a current application from Struts to JSF. Gregg's proposal is also what I would suggest - any new projects starting, use JSF.

There are more to JSF than "just" the viusal aspect - event/listener model, state saving, etc.. it is a pretty solid framework with lots of extension points giving developers the freedom they need.

Here are some open source examples on what can be done (not just components):

Weblets
Mabon
Facelets
Shale


Author: Pro JSF and Ajax: Building Rich Internet Components, Apress
Adeel Ansari
Ranch Hand

Joined: Aug 15, 2004
Posts: 2874
Originally posted by Gregg Bolinger:
I'd never suggest migrating a Struts app to JSF. I *might* suggest starting new project using JSF rather than Struts. But why change what works?


Cent percent agreement.

Struts vs JSF
Struts vs JSF
Struts vs JSF
Struts vs JSF
Struts vs JSF
zaxxon25
Ranch Hand

Joined: Feb 26, 2005
Posts: 35
Java is losing lot of web projects to .net stack becuase .net provides everything in one place, by one vendor and development time is also small. JSF Framework is being touted as strong contender to .net framework in web applications. The reason being foremost becuase of offical standardisation provided by Sun and secondly more advantageous from other J2ee open source frameworks like Struts (Jonas mentioned few advantages). Can anyone also tell me JSF advantages breifly in comparision to .net .
Gregg Bolinger
GenRocket Founder
Ranch Hand

Joined: Jul 11, 2001
Posts: 15299
    
    6

Java is losing lot of web projects to .net stack becuase .net provides everything in one place, by one vendor and development time is also small.

Really? How do you know?

Can anyone also tell me JSF advantages breifly in comparision to .net .

Might want to start a new thread for that one. But the main thing is JSF is java and .NET is, well, .NET.
George Stoianov
Ranch Hand

Joined: Jan 15, 2006
Posts: 94
I do not have stats to prove my point, either and depends on who's web site you are reading too, but I wanted to add my 2 cents to the .NET statement so that guys looking where to start Java, Struts, JSF or .NET can have another opinion .

The fact that .NET is one thing from one vendor is its biggest advantage and at the same time its biggest disadvantage, what I mean is - yes if there is more choice you have to know more and navigate better to succeed but if there is no choice there is no innovation nor evolution. Namely with frameworks like the Java open source projects everyone is able to make contributions even make there own solution where as with something like .NET that is much harder or impossible (not very familiar with Microsoft's process of advancing .NET). The other factor you have to consider is also that while Microsoft wants you to use .NET they are not doing the same (check if Vista their next OS is built on .NET), which means that you can only report bugs but if your business success etc. depended on it you could not make any changes...and that is not pleasant..to say the least.

Not every framework is for every project or everyone for that matter, some of the Java frameworks like struts are quite complex, in my mind, and learning them and using them efficiently is a challenge. They also involve a lot more code than a drag-and-drop control and form building in VS.NET but they can run on any platform out there starting from your laptop to even small devices as this is after all Java.

Between Struts and JSF I personally would choose JSF, and that would depend on the project I am working on, but because the UI life cycle and server background fits more my background knowledge in database GUIs and general style of coding I would lean to JSF or something similiar. For other projects that use Struts and are working just fine I would not change or just plug-in something from JSF that makes sense.

As pointed out here, in one of the forums/topics, the creator of Struts has been involved in the JCP for JSF and both can inter-operate.

Sun is also coming out with some GUI tools that make webapp building a dreamweaver guy job and are similar to .NET with one little exception they run on Linux and can be deployed on many more OS and devices.

Regards,
George
zaxxon25
Ranch Hand

Joined: Feb 26, 2005
Posts: 35
Thanks George for a detailed reply to my query.
Gregg had asked me how do i know that J2EE is losing to .Net. I am java consultant and in last 6-8 months i have seen more and more of our clients going for .Net framework for web app projects. We tried to reason with them in review meetings and everytime they are saying it takes very less time in .Net development and you get everything in one place.
Another reason can be that Microsoft might be doing aggressive marketing behind the scenes with the people who decide the project methodology.
Tim Holloway
Saloon Keeper

Joined: Jun 25, 2001
Posts: 16145
    
  21

.Net is probably faster to hack out an app. PHP certainly is. Ruby/Rails is very popular on that account as well. However, not every app should be designed based on how fast it can be hacked out, since the operative word there is hacked.

A lot of the complexity that slows down Java development is because it's designed for large-scale long-lifetime heavy workload operation where bizarre events may occur at unpredictable times. The hacked-out apps (including the Java ones) can't handle that. It takes extra time to lay out and bolt in good transaction management, backups that don't interfere with uptime and stuff like that.

A more immediate concern around here is that Microsoft solutions are viral. It's perilously easy to have a Microsoft solution drag in more and more Microsoft co-solutions until one day you wake up and discover that you can't get anything done without Windows.

With each new Windows security alert, people here get more and more unhappy with Windows - things have reached a point where they just all blur together. Now we heard (last week) from a Microsoft employee that you might as well give up on keeping Windows clean. We'd rather leave our options open.


Customer surveys are for companies who didn't pay proper attention to begin with.
George Stoianov
Ranch Hand

Joined: Jan 15, 2006
Posts: 94
Gregg had asked me how do i know that J2EE is losing to .Net. I am java consultant and in last 6-8 months i have seen more and more of our clients going for .Net framework for web app projects. We tried to reason with them in review meetings and everytime they are saying it takes very less time in .Net development and you get everything in one place.


Have a look at Sun's Java Studio Creator (http://developers.sun.com/prodtech/javatools/jscreator/index.jsp) it should make developing java webapps a lot faster and .NET-ish like. I personally like to quote James Goslin and say that "power (from Java) attracts complexity", what you should point out to your customers is power, standards and interoperability along with innovation, with .NET everything is about doing things one way for one goal ... You can ask any of your MS Programmer friends whether they liked debugging code from a VB project someone with a pharmaceutical degree (nothing against pharmacies etc, just a complex word which I probably spelled wrong ) in just 5 minutes with nice colors but forgot to put any error checking and by the way the date field accepts strings as they saw a message telling them something wierd did not do something weird...and this actually works.. All I am trying to say is quick-and-dirty is just that quick-and-dirty and if everything is made one and the same way one security flaw open many doors ...

regards,
george
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Struts v/s JSF