JSF - Still pretty much a steaming pile of donkey turd March 13, 2007
Posted by Wille in Java, Software Development.trackback
After two late evenings of playing around with JSF, I can reaffirm my previous conclusion from 1.5 year ago: It’s still pretty much a steaming pile of crap, mostly pushed and flogged by vendors creaming their pants at the prospect of selling development tools to companies.
To enumerate some (but not all by far) of my objections about JSF:
- Why of why would I want to learn yet another tag-language?! Furthermore, looking at something like Ajax4JSF, the number of attributes on most tags is bewildering and for someone who didn’t write the actual tags working out what attributes do what, which ones are critical as opposed to optional is mostly a matter of trial and error (the Ajax4Jsf commandLink tag has some 46 different attributes you can set!).
- What is wrong with HTML?! JSF seems not only invent yet another tag language, it pretty much wants to replace anything that has to do with HTML. HTML and CSS is fine, why try to replace it?
- Unpredictable behaviour for a JSF-newbie: if you do get something wrong, how a component will behave seems completely arbitrary. If it is wrong in one way it may throw a semi-obscure stacktrace. If it is wrong in another way, clicking somewhere where you expect behaviour may result in absolutely nothing, nada, not even a stacktrace.
- Touched on it previously: obscure stacktraces. If you are a seasoned developer you might be able to decipher what might be wrong. But I can bet good money on a developer with <3 years of experience being utterly bewildered at some of the stacktraces that can be thrown at you.
- Sloooooooooooow. How slow could a webapp possibly be? Answer: like a JSF webapp.
- Learning curve. Is JSF supposed to be easy to learn? Not compared to any other MVC framework I’ve come across at least.
Those are only a few of my objections to JSF. The end impression is that it is a horribly convoluted, over-engineered framework that goes to great lengths to replace existing, well functioning technologies without addressing any of the pain-points at all. It might be possible that with the right tooling, and once you get over the initial learning curve JSF might be quite nice, but at the moment the learning curve compared to any other MVC framework in the market is just too much of a pain. Once upon a time, I learnt how to do 80% of what was needed with Webwork in about 1.5 hour with minimal pain. After about 8 hours with JSF I am still bewildered, puzzled and above all annoyed at having wasted 8 hours of my life I will never get back.
It’s no great wonder that JSF skills aren’t in great demand. Who in their right mind would use it unless they where a JSF-vendor? As for me, I think I’ll stick to the combination of Struts2/Webwork and DWR, despite my objections about the lack of progress.
Ok, I agree some parts of JSF are over engeered but we have accept the point that JSF is standard and weather we like it or not it will get its demand.
I saw this positive points.
- Event driven model
- Working with pojo class in backend
- Having capability to plug in componet
And some other.
You may didn’t notice there are more than 10 Ajax frameworks already written on top of JSF
And at end I think you will have to look back again.
Ali:
I agree that some of the premises of JSF are definitely good, however so far it just feels horribly overengineered and flawed. The good premises are outnumbered by the flaws so far.
But as you say: I will probably look back at JSF again in a while to see what’s changed. The last time I looked at it was about 1.5 year ago. So far I stand by my initial impressions. I might give it a spin in 1.5 years again.
[...] Wicket - day one April 29, 2007 Posted by Wille in Software Development, Java. trackback I’ve been quite disillusioned with the state of Java web-frameworks so far, especially when it comes to the incomprehensibly pushed and backed JSF. [...]
i remember intreview with guy behind JSF and i was loling when he said that JSF doesnt depend on HTTP and you will be able to use it when HTTP will be replace by some other protocol.
Me too. I recently tried JSF to see what all the fuss is about - and decided to document a side by side comparison with Wicket here:
http://ptrthomas.wordpress.com/2007/05/14/a-wicket-user-tries-jsf/
Regarding the first comment that JSF is a “standard” - there are plenty of comments at the above link that address this.
Willie - from your earlier blog posts, I see you have been experimenting Wicket as well. Wicket rulez
Peter: Yes, my impressions of Wicket are very favourable, far superior to JSF.
One thing I missed in this post, but that is almost the single biggest flaw of JSF is it’s bleeding abstraction: if you don’t know the JSF lifecycle inside-out, you are pretty much stuffed.
What good is a framework if I have to know everything about its internal workings?
I agree that the Stack Trace from Hell must go, but I think you are wrong about “HTML is fine”. The strong point of JSF is that I don’t have to think about loops that make a mess of nested tr and td tags. I just drop in a data table, and someone else produces the HTML. Ditto with trees, file upload, etc. Components are a good thing.
Cay:
Components are great.
But you can have your cake and eat it too: just look at Wicket: the HTML is the template, the components are in Java-code.
Makes both things understandable and separated. AND you can actually properly unit-test your use of components, since they are code and not mark-up.
I completely agree. JSF is a complete disaster. You can spend days trying to figure out what even the simplest error means, I’m glad to see it’s not just me that has these frustrations. I’ve also used webwork successfully for many years. It’s simple, yet powerful and dead easy to write tests around. I think I’ll stick with it for now.
Meh, I’ve been using java for about a year, mostly with JSF & facelets, and now with Seam.
They all let me rock on and keep me productive, so I don’t know what you guys are doing.
Need to know the JSF lifecycle? No more so than having to know the nuances of any other framework to get real work done. I write my JSF pages in a text editor which also dispels the notion that IDEs are a must for JSF page writing.
Both facelets and seam provide their own aid to error messages, and from what I’ve seen, nobody in the java world has any idea on how to deliver an error message that is useful and not shrouded in 200 lines of irrelevant error details.
Raveman, perhaps you missed Oracle ADF which has a TelNet renderkit which allows you to use the same JSF page code, and backing code over a telnet session, or instant messenger.
JSF is definitely packed with obstacles to get to a decent proficiency level in a short amount of time. What is the suggested alternative framework that is Component oriented?
My background has been in several years of WebObjects development, and the current batch of Component based framework competitors are all a far cry from the ease and power of building WOComponents. Agreed that WebObjects has it’s own issues…
I’ve looked at Tapestry, but with that changing every version, it would not be easy to get corporate buy in for using that moving forward.
Wicket looks like it might be good, is that still a growing and active project?
Has anyone heard of or used the “click framework” (http://click.sourceforge.net/) — a colleague at the office uses that for personal projects… but otherwise I have never seen any chatter on it…
John:
Try Wicket, don’t have much experience in it (so I might have missed some obstacles), but as opposed to JSF, I instantly fell in love with Wicket. And it is component-oriented and stateful.
As for Click, don’t know much about it, but I think it has been inspired to some degree by Wicket, which is the best kind of flattery.
[...] around 630 visitors on the web-page, with a slightly smaller spike in RSS-readership. Apparently this old post on JSF that got picked up by DZone (which is a new acquaintance for [...]
I agree that JSF is a “pile of donkey turd”.
I’ve been using Stripes for about 6 months now and am super happy with it.
http://mc4j.org/confluence/display/stripes/Home
Try to make a SEO friendly web 2.0 application with support for bookmarks and deep linking with JSF. I claim it is impossible!
Ah, yes the “everything is a POST”, almost forgot about that..
me too.. Tapetsry is the original framework.. JSF is a pile of donkey turd.. I know the exadel team(eltegra in 2002) who created JSF studio.. They are a group of Russian developers who created a IDE for a pile of Donkey turd.. JBoss is also produced a similar product - jboss seam. My company doesn’t use any jboss. Only BEA. jboss is good for toy applications not enterprise.. Why did tapestry get Duke’s choice award, and not JSF?
JSF makes web application development easier - I think only for sales demos. For large complex projects, involving criss cross navigation, JSF is really horrible.