views:

755

answers:

4

I'm looking to make a selection of a (Java-based) framework for UI development, with the following constraints:

  1. The application requires very simple UI (form with 1 or 2 buttons results in a list of images, texts, etc) but the actual types of UI element rendered are numerous.
  2. We already have the backend logic (in the form of a web service) implemented the way we want it.
  3. Componentization is important
  4. We'd like to have extensibility points (in the future) to allow external developers to change the look and feel of the UI, without having to build, compile, and stage the entire application or even the entire front end.
  5. Performance and scalability of the UI layer is important, but we aren't expecting 100tps per machine, and the backend is most likely going to be the bottleneck anyhow
  6. Ease of maintenance is crucial
  7. Support for easy internationalization
  8. (and this is a bit unique) we may want some UI components to be rendered differently based on browser capabilities, browser version, etc. However, we want to hide this fact from the developers who build any specific screen (as far as possible).

So far, our top choices are Tapestry and JSF (maybe with Facelets). I've read past discussions here such as http://stackoverflow.com/questions/257712/best-java-framework but they do not seem to address my specific points. Any advice?

A: 

We are also considering Grails on Groovy, although I am less familiar with the RoR-style approach to web development. I also looked into Spring mvc, but I am not sure I liked it for my use case. A straight jsp-based solution is obviously an option, but would require us to build any smartness in, and may lead to ugly 'code inside jsp pages' which is unmaintainable, which is why I hesitate to do just that.

Yaniv
+1  A: 

One of the big things to think about is what changes you expect. if it's a web-based application, you'll generally do well with a choice that is built around JSP because it is easy to change, and can be changed by designers.

update

"How is it easy to change?" I'm asked. Basically, there are two things about JSP that make it easier to change: it's a rich platform, in the sense that you can write relatively little JSP compared to, say writing your own servlets and writing the servlets to generate styled, consistent HTML; and second, since most of the JSP looks more like templated HTML than Java code, you can let designers loose on it directly. That means all the fussy design decisions can be made by designers, instead of needing to have a designer do it, show it to the coder, have the coder re-code it, then show the results back to the designer.

Charlie Martin
How is a jsp-based solution easy to change? can you provide more insight? thanks!
Yaniv
+1  A: 

IMO, Stripes is a viable option too. Stripes is a presentation framework for building web applications using the latest Java technologies. Since, you are already having all the back-end, as you mentioned, and require just a UI Framework.

Spring MVC, Seam, Struts are not suitable here.

JSF is a good choice, but it has quite a learning curve. I don't find it too difficult though, but folks usually complain this alot and I have seen developers doesn't really understand the philosophy soon enough. The advantage is there are good number of developers out there. I still recommend to, at least, have a glance of Stripes.

Adeel Ansari
A: 

Since you have web services, GWT and Flex are viable options. Flex, in particular, is designed to use Web Services as the service layer.

davetron5000