aspose file tools*
The moose likes Other Application Frameworks and the fly likes STRUTS OR SPRING ?? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Frameworks » Other Application Frameworks
Bookmark "STRUTS OR SPRING ??" Watch "STRUTS OR SPRING ??" New topic
Author

STRUTS OR SPRING ??

sameer khazi
Greenhorn

Joined: Sep 05, 2008
Posts: 28
HI

As far as my knowledge goes, Struts and Spring are the two among many Web Application Frameworks.... right?

i want to learn a framework among these two, in fact both.

But which frame work should i first pick up and which is the important one among these : Struts or Spring , keeping in view various IT companies want from a candidate.

Please let me know..

Thank you.
Joe Ess
Bartender

Joined: Oct 29, 2001
Posts: 8903
    
    8

This question comes up a lot. Searching the forum will give you many opinions, including mine


"blabbing like a narcissistic fool with a superiority complex" ~ N.A.
[How To Ask Questions On JavaRanch]
Rosco Duncan
Ranch Hand

Joined: Apr 23, 2007
Posts: 41
Spring includes a web/mvc framework which is not dissimilar to Struts, but also includes framework support for a great many other things.

If you are just interested in learning a web framework, or coming to grips with MVC (Model View Controller pattern) then either Struts or Spring MVC would suit your purpose and add to your hireability in my opinion. If you a looking for a broader learning experience however I would suggest focusing on Spring as it has so many other useful features.

Good luck!
sameer khazi
Greenhorn

Joined: Sep 05, 2008
Posts: 28
Hi,

Thanks Rosco...

You gave a clear picture of Spring and Struts.

Keeping in view the broader features that Spring offers and also since it is in great demand by IT companies,

i will start by Spring.

Thank you...
Antonio Fornie
Ranch Hand

Joined: Aug 07, 2008
Posts: 117
I think Struts (in fact Struts 2 or Stripes, because Struts is a little old) is a good framework for MANY projects. But there are alternatives.

I think Spring is very good for ALL projects. And I don't know any serious alternative.

Obviously, as Spring is far larger, you may prefer to learn Struts 2 fast and then think about learning Spring. By the way, once you know both of them I think you'll agree it's better to use both together than using Spring alone, 'cause Spring's MCV is not as rich as Struts 2.

And to tell you one more thing you may agree, GWT, Echo2... are very modern frameworks that help you develop a real Web2.0 app. If you develop a web app without many javascript and AJAX features, it will seem a little out of date. I know many people won't agree. I'm not saying you have to use AJAX for EVERYTHING, but surely you'd better use it for at least some things. And the same goes for javascript effects. You can always use a Struts like framework with jQuery or a similar one.

Right now I'm working in a project with GWT, Spring, Hibernate and hibernate4GWT. Sometimes I miss Struts2, but I have to admit that I'm creating some features much faster than I'd do without GWT.

I hope you find useful my response.

Antonio


I feel there must be far better ways to do what I do... that makes learning even funnier
sameer khazi
Greenhorn

Joined: Sep 05, 2008
Posts: 28
Hi Antonio..

Well, You have kept things simple while talking about the available frameworks.

As far as quick learning is concerned you have preferred Struts as the one.

On the other hand , about the usage of Spring and Struts 2 is concerned , you said they find their place in "MANY" AND "ALL" PROJECTS.


Well, i do understand that Spring is very large.

Kindly guide me in the following..


My point of concern is that i want to learn a MVC framework which quickly gives a foundation and keeps me going as far as looking for a job is concerned.



I am not trying to look out for a easy way out. i am equally eager to go with so-called "Large" Spring. But since i am new to this framework world, i don't know how deep it is.


Well, i had finally zeroed in on Starting with Spring.

But your point of importance being given to Struts2 for quick learning has again put me in dilemma .

Help me out..

thank for everything..

Suggestions and advices are highly appreciated...

thank you.
Sonny Gill
Ranch Hand

Joined: Feb 02, 2002
Posts: 1211

sameer khazi wrote:
But your point of importance being given to Struts2 for quick learning has again put me in dilemma .


You could start off by learning just Spring MVC, which should be no harder than learning Struts 2, and then move on to other parts of Spring.
You will still need to know the basics of Spring dependency injection but it isn't too hard. Do a google search or search this forum for Spring MVC step by step tutorial, which teaches you just enough to get started quickly.


The future is here. It's just not evenly distributed yet. - William Gibson
Consultant @ Xebia. Sonny Gill Tweets
Antonio Fornie
Ranch Hand

Joined: Aug 07, 2008
Posts: 117
One thing I guess you already knew: Spring is a suite of frameworks and Spring MVC is only one of those frameworks. They all rely on Spring core. But there are other frameworks inside Spring: Spring MVC (similar to Struts), Spring security (acegi), JMS templates, DB templates (for JPA, Hibernate, Ibatis, JDBC...), Spring Workflow...

I agree with Sonny. Go for Spring and Spring MVC as a first solution. And then, consider if you go for Struts 2, or you prefer to go for GWT or a similar one, because knowing Spring MVC you don't really need Struts 2. Struts 2 is another way of doing what Spring MVC already does. Both Spring MVC and Struts 2 are page-based MVC frameworks, so once you know Spring MVC the first reason to learn Struts could be just that you need it for a job.

I've got the feeling there's little future for page-based MVC frameworks. Today everybody wants Web 2.0 and that's not the concept of pages, but AJAX based applications. I think soon we'll all be using Echo 2, GWT, jQuery...

 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: STRUTS OR SPRING ??