Looked at the company's several projects, found that the project's Web layer framework is the use of SPRINGMVC, and gave up the Struts2, through the communication with colleagues, as well as their own development experience, more feel springmvc simple and practical.
Comparison between SPRING3MVC and STRUTS2MVC
1, SPRINGMVC support restful URL, this feeling cool, in terms of development efficiency, can throw struts2mvc a street
2, SPRINGMVC Basic implementation of the 0 configuration, the configuration of spring Applicationcontext.xml and Web. XML, the basic will not need additional configuration. And spring's configuration is relatively simple. And struts2, the need for a relatively more configuration, but also more complex
3, SPRINGMVC to each request is a method-level interception, interception method, according to the parameters of the annotations, the request data injection. One method corresponds to a request, and the Springmvc method is independent of each other, and the request and response data are exclusive. While STRUTSMVC is a class-level intercept, each time a request comes, an action is created, and then the getter, setter method is called. An action corresponds to a request context.
4, let people more cool is SPRINGMVC knowledge JSR303, processing AJAX request more aspects, only need to annotate a @responsebody, and then directly return the corresponding file.
This article is from the "Ah Cool blog source" blog, please make sure to keep this source http://aku28907.blog.51cto.com/5668513/1839865
Comparison of Strutsmvc and SPRINGMVC