Feb 28th, 2011, 03:47 PM
Spring 3.0.x and Struts 1.x support
I have a web application using Struts 1.2.9 I need to support for about another year or so until time and resources free up to rewrite the application using Spring MVC. I want to upgrade to Spring 3.0 soon, but have found mixed information as to whether the ContextLoaderPlugIn class and Struts 1.x is still supported. I read the 3.0 reference and it looks like 3.0 does support ContextLoaderPlugIn and other Struts 1.x based Spring Support classes (albeit depreciated, which is fine), I just don't want the Struts code to blow up if I add Spring 3.0 jars to the project. I want to know whether it makes a difference as to which Spring 3.0.x jars I use (I believe there 5 versions)? I did try and search the forum on this topic but did not find anything conclusive. Again, I just need to support this 1.2.9 Struts app through the year and then we rewrite the web apps using Spring MVC.
Mar 14th, 2011, 10:58 AM
I did a bit more research and found that Struts 1.x IS still supported in Spring 3.x although depreciated. I also ran a test and found that Struts 1.2.9 will run using the Spring 3.0.5 jar files. I hope this post provides a bit more community help than I got on this question.
May 11th, 2011, 12:44 PM
I am working with a project where we are being Spring 3.0 into a Struts 1.x project. I have tried to follow the steps to integrating Spring using the plugin. I am using annotation with my Spring classes. What is happening when I get the WebApplicationContext, I see all my DAOs (from a jar file I added to the WEB-INF/lib directory). However, I cannot see any beans in the struts application. All the Beans are annotated in their respective classes. Does the Sruts plugin only recognize bean definitions in the applicationContext. xml file?
May 11th, 2011, 04:40 PM
I am not sure. There is another developer here who deals primarily with the web portion of the code. I originally asked the question for her. She is actually in class this week, but when she gets back Monday, I'll ask her and try and get an answer for you.
Tags for this Thread