Hi Karen, Karen <ka...@...> writes:
> [...] I looked closer and noticed that the big difference between Stripes and > Spring MVC still is, that Stripes action beans are threat safe and Spring 3 > MVC beans are not thread safe. > Just like Servlets the Spring MVC beans are singletons with multiple active > threads running through them. Unlike Stripes they can't use instance > variables. > Thus the Spring beans have to use local variables, a programming model that > leads to more complex procedural code. I've looked more closely to Spring MVC. Now, my feeling is that it's not a problem for Spring MVC controller beans to be singletons. It's just a different approach than Stripes. Whereas Stripes has instance variables that can be set from request parameters, Spring event handler methods accept those same objects as parameters. In other words, in Stripes you'd have private User user; /* getters and setters */ public Resolution save() { // do something with user } In Spring MVC you'd have public void save(User user) { // do something with user } The "do something"s in both Stripes action beans and Spring controllers are best left to injected helpers, daos, and so on, keeping the action/controller classes simple. So, in that respect, I'm not sure that using local variables leads to more complex procedural code, if you keep things simple in controllers. But, you seem to speak from experience, so I'd love to read your thoughts on this. Cheers, Freddy ------------------------------------------------------------------------------ Start uncovering the many advantages of virtual appliances and start using them to simplify application deployment and accelerate your shift to cloud computing. http://p.sf.net/sfu/novell-sfdev2dev _______________________________________________ Stripes-users mailing list Stripes-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/stripes-users