views:

191

answers:

1

I am coming from Struts 1 world. Now I am starting a new project and we are using Spring.

I could use Spring MVC, but seeing how simple it is to use Stripes (no xml is a big plus) I am tempted to use that with our brand spanking new Spring web application. I have no experience in either Stripes or Spring MVC (apart from basic CRUD application).

Question is, what are the downsides of using Stripes as opposed to Spring MVC? Several parts of the application will be RESTful, will it make it harder if we use Stripes? What about validation? I suppose Stripes will be easier to implement, no?

+1  A: 

Stripes is a great framework. It's been our framework of choice the past few years and has yet to disappoint.

However, if you mean RESTful in the sense that you want to use HTTP PUT/DELETE, etc. Stripes might not be your answer. I think you'd have to set up Filters, or additional logic in your Beans, it wouldn't be straight-forward (as it seems to be in Spring from a cursory googling).

On the other hand, if you mean things like /app/delete/3 or /app/update/4 & pass POST params, Stripes is an excellent choice.

The Stripes book (Pragmatic Programmers) explains the framework well, and has a chapter on using DI with Spring. All the normal bells and whistles (including validation) are excellent.

lucas
No I won't be using PUT/DELETE. But I will be using a lot of AJAX. Normally I would let JQuery to POST/GET and a Servlet will return response in JSON (which is easily parseable by JQuery).
Rosdi
We do exactly this, often. Stripes can either return a JavaScriptResolution (http://stripes.sourceforge.net/docs/current/javadoc/net/sourceforge/stripes/ajax/JavaScriptResolution.html) where it converts Java objects to eval'able JSON, or can just create JSON yourself and pass it back as a StreamingResolution (http://stripes.sourceforge.net/docs/current/javadoc/net/sourceforge/stripes/action/StreamingResolution.html)
lucas
@lucas, Thanks for the JavaScriptResolution and StreamingResolution links, didn't know about these two actually.
Rosdi