views:

124

answers:

2

Hello
I'm asking this question because I'm having some difficulty choosing a framework (or selection of technologies) that I can learn and use for developing a web-based UI for a small Java application:
For background information relating to the app I'm developing please read this question:

So, developing the Java application is going ok and now I'm in a position where I would like to develop a web-base UI for it.
The application and database (MySQL) currently run on a Debian Linux box, as such I've decided that it would sense to use Tomcat to run the Web App. The Web App is to serve the following purposes:
1. Manage the execution of the App by CRUDing data from the MYSQL database.
2. Display status information about the app (i.e. what orders it's placed, what orders are pending, etc.)
3. Produce on demand reports on stuff like the running profit and loss, historic and realtime prices and pricing analytics

So far so good now here's the problem: There are a bewildering number of choices for how to develop the UI, to name a few I've looked at:
JSPs + Spring MVC
JSPs + Sping WebFlow
JSPs + JSF + Facelets
Wicket
JSPs + JSTL

etc, etc... The choices seem endless. Is there's a clear industry standard for developing web based UIs using Java related technologies? If so what is it? Ideally I would like to learn a framework which I can use in the majority of real world jobs (and preferably one which can be used from Eclipse).

Thanks and Kind Regards

+2  A: 

Personaly, I prefer another approach, I would go for Eclipse of course, Spring (or other IOC container), Hibernate / JPA + JAX-RS or JAX-WS for the server layer, but not nessecarily JSF / JSP for UI.

For presentation layer, I would rather go with Flex, GWT, or a JQuery in an SOUI approach. (the service layer returns incremental updates in the form of XML or JSON, I swore not to mention the term AJAX)

Your service layer would serialize partial object graphs by demand from the presentation layer, which will act as a disconected client (work on an "offline" dataset , and update dirty on demand)

But that is just my wet dream, and in my current project I'm stuck with Spring MVC, and JSP + JSTL

I would give Jboss SEAM a test drive, just because Gavin King is behind it, but I think its JSF based.

I don't know why I don't see JSF as a SOFEA / SOUI approach, as JSF and AJAX go together well, but for some reason, JSF didn't win my enthusiasm as much as the above suggestions (Flex as a favorite)

See my related question: http://stackoverflow.com/questions/1969278/web-architecture-mvc-lazy-initialization-data-transfer-objects-open-session

Ehrann Mehdan
Flex, GWT, why not. But seriously, this SOUI article is total bullshit. The only good piece of information comes from this comment http://www.infoq.com/news/2007/11/soui-death-of-mvc2#view_13750. It clearly points out why this this service-oriented-buzz acronym is ridiculously wrong. No, I'm not going to use this acronym. And by the way, this article is from 2007 but MVC is still alive as far as I know :)
Pascal Thivent
How would flex work other than that via consuming services from the server? you can't have FSPs (Flex Server Pages) I like this approach. maybe the term SOUI / SOFEA is not used correctly here, but I think that the notion of page flow, and web page should leave this world. e.g. Gmail (open a new browser, go to gmail, look at the back history, they are reinventing browser back functionality, since back doesn't mean previous page, but rather previous state)
Ehrann Mehdan
+2  A: 

Is there's a clear industry standard for developing web based UIs using Java related technologies?

Well, Sun's Java EE standard is Java Server Faces (JSF) but the version 1.x of JSF is IMHO a kind of failure. This explains why they are so many alternative out there. But NO, there is no clear winner.

Ideally I would like to learn a framework which I can use in the majority of real world jobs (and preferably one which can be used from Eclipse).

Actually, Matt Raible has done very famous presentations on presentation frameworks that you'll find in Comparing JVM Web Frameworks Presentation (the latest version goes beyond Java frameworks only). Really, have a look at both of them, this is very, very good material (with real life metrics).

Personally, I'm a JSF 1.x skeptic so I would not go in this direction (there isn't lots of demand for JSF in my country anyway) but rather choose an alternative. I think that Struts 2, Spring MVC, Stripes (this one is my preferred one), Wicket (this one is getting more and more attention) are all decent choices, they'll all get the job done, the 2 first one being I believe more asked on the job market (but not the smartest). For the final choice, I'd follow Matt's advice: Eliminate, Don't Include. If the popularity on the jobs market is an important criteria, then I guess Stripes and Wicket will get eliminated. If configuration verbosity is a concern, Stripes wins. If you're looking for a kind of Swing experience, Wicket is your friend.

Now, I need to mention that the freshly released JSF 2 and CDI (JSR 299) should be a big improvement (according to the people who worked on it). As I said, I'm a JSF skeptic and I need to take a second look (because Gavin says so). But I still didn't so I can't say anything for now and I won't make any bet on the adoption and future market demand of this new version. But it's worth noting that JSF 2 with CDI should be a really new and different experience.

Pascal Thivent