Win a copy of The Little Book of Impediments (e-book only) this week in the Agile and Other Processes forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

From Struts to Spring

 
Roel De Nijs
Sheriff
Posts: 10662
144
AngularJS Chrome Eclipse IDE Hibernate Java jQuery MySQL Database Spring Tomcat Server
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I have been developing web-applications with Struts since June 2004. Is it worthwhile to change for every application to Spring, or is this just another framework besides Struts (and some others)? Or is it specifically meant for some kind of application (working with EJBs or something like that)?
If you are an intermediate struts developer: would changing to Spring be very difficult (for me as developer) and time-consuming (changing jsp's, action forms, action classes,... to SpringMVC)
 
Chengwei Lee
Ranch Hand
Posts: 884
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
If I'm not mistaken, EJBs are a big no-no in Spring. To Spring, EJBs are the culprits that make J2EE applications too heavy-weight.

Correct if I'm wrong.
 
Christopher DeBracy
Greenhorn
Posts: 4
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You can use Spring and still continue to develop with Struts, Tapestry, JSF, etc. Spring offers its own MVC framework, but you're not required to use it.

I've been using Tapestry lately and looking forward to integrating it with Spring to see how well everything works together.
 
Matt Raible
author
Ranch Hand
Posts: 114
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by Cheng Wei Lee:
If I'm not mistaken, EJBs are a big no-no in Spring. To Spring, EJBs are the culprits that make J2EE applications too heavy-weight.


Spring doesn't really discourage the use of EJBs, in fact, it
makes EJBs easier. However, most applications don't need EJBs because they'll only ever run on a single server and they don't need the distributed/remote stuff that EJBs provide.

Also, Spring provides many of the services of an EJB container: i.e. declarative transactions and security (via Acegi Security) and makes it much easier to "test" your code. Testing EJBs is hard out-of-container.
 
Sonny Gill
Ranch Hand
Posts: 1211
IntelliJ IDE Mac
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by Christopher DeBracy:

I've been using Tapestry lately and looking forward to integrating it with Spring to see how well everything works together.


I think Matt forgot to mention that appfuse integrates Spring/Tapestry/Hibernate

You may find that a useful starting point for your Spring/Tapestry integration.

Cheers
[ February 23, 2005: Message edited by: Sonny Gill ]
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic