Struts migration
Migrate Struts to Spring Boot, one action at a time.
Struts code is mostly controllers, form beans and JSPs. That structure can be moved in slices while the application keeps running.
The short answer
A Struts migration moves an Apache Struts 1 or 2 web application to a supported framework, usually Spring Boot with Spring MVC. Actions become controllers, form beans become model objects and validation moves to Bean Validation. The view layer is the largest job. Ace8 migrates in slices, behind tests, with senior engineer review.
Risk
Why migrate off Struts?
Struts 1 reached end of life in 2013 and gets no security fixes. Struts 2 is maintained, but it has a record of serious remote code execution flaws, and versions that lag behind are a common finding in security scans. Many Struts applications also sit on old Java versions and application servers, so the framework blocks every other upgrade.
- Struts 1 receives no fixes at all.
- Old Struts 2 versions carry known critical vulnerabilities that scanners flag.
- The framework ties the application to older Java and servlet versions.
- Fewer engineers know it, which raises the cost of every change.
Mapping
What does Struts become in Spring?
Effort ratings are typical relative sizes, not estimates for your application. The assessment sizes yours.
| Struts concept | Spring Boot equivalent | Effort |
|---|---|---|
| Action / ActionForward | @Controller method returning a view name | Low, mostly mechanical |
| ActionForm / form bean | Model object or DTO bound by Spring MVC | Low to medium |
| struts-config.xml / struts.xml | Annotations and Java configuration | Medium, needs a full route inventory |
| Validation framework XML | Bean Validation annotations | Medium |
| Interceptors / RequestProcessor | Spring HandlerInterceptor or filters | Medium, behavior-sensitive |
| Tiles templating | Thymeleaf layouts or another template engine | Medium to high |
| Struts tag libraries in JSPs | Template engine tags or a retained JSP with Spring tags | High, the largest part |
Sequence
In what order do we migrate?
Running both side by side is the same strangler idea in the Ace8 method: small steps, each reversible.
- 1
Inventory the routes
List every action, form, forward and interceptor, with traffic and test coverage for each.
- 2
Test the behavior
Add tests at the HTTP level so the same requests can be replayed before and after.
- 3
Run both frameworks together
Add Spring MVC beside Struts in the same application so routes can move one at a time.
- 4
Move routes in slices
Convert a group of actions, review the diff, run the tests, deploy, then take the next group.
- 5
Retire Struts
When no route is left, remove the dependency and move to an embedded server and a current Java version.
Tooling
What can AI-assisted tools do here?
Action-to-controller conversion is rule-shaped, so a deterministic tool or a model can draft it. We use these tools for the mechanical edits and rely on engineers for the rest. See AI-assisted modernization and OpenRewrite.
- Tools help with: converting action classes, moving imports, translating simple validation rules.
- Engineers handle: custom interceptors, Tiles layouts, JSP scriptlets, session handling and security integration.
- Rewrite of the view layer is the bulk of the work and is mostly manual review.
Decisions
Should we move to Spring Boot or another target?
The target should be open and supported, so the application does not trade one dead end for another. See Spring Boot 3 migration.
- Spring Boot with Spring MVC suits most Struts applications: closest model, large talent pool, open source.
- A separate single-page front end suits applications with heavy interaction, but it is a redesign of the view layer, not a migration.
- Struts 2 upgrade to the latest release is a short-term option if the application is small and security patching is the only goal.
Evidence
What have we measured?
We have not yet published a Struts migration with figures. When we do, it will report routes converted, tests before and after, manual fixes and review time. Until then this page claims no numbers.
After go-live
Keep it running after cutover.
Moving an Apache Struts 1 or 2 application to a supported framework, typically Spring Boot with Spring MVC. Actions become controllers, form beans become model objects and validation moves to annotations.
Struts 1 is, since 2013, and receives no security fixes. Struts 2 is maintained, but old versions carry known critical vulnerabilities.
It depends on the number of routes, the size of the JSP layer and test coverage. We size it in the assessment rather than quote a general figure.
Yes. Spring MVC can run beside Struts in one application, so routes move in groups while the application stays live.
Tools can convert the mechanical parts such as actions and imports. The view layer and custom behavior still need engineers.
Know the cost before anything moves.
A fixed-price assessment gives you the inventory, the risk score and a phased plan. Scope and cost are fixed before the migration starts.
Book a Fixed-Price AssessmentGet in touch
Talk to a modernization engineer
Tell us what you run today. An engineer, not a sales script, replies within one business day.