StackShareStackShare
Follow on
StackShare

Discover and share technology stacks from companies around the world.

Follow on

© 2025 StackShare. All rights reserved.

Product

  • Stacks
  • Tools
  • Feed

Company

  • About
  • Contact

Legal

  • Privacy Policy
  • Terms of Service
  1. Stackups
  2. Application & Data
  3. Frameworks
  4. Frameworks
  5. Apache Struts vs Spring Framework

Apache Struts vs Spring Framework

OverviewDecisionsComparisonAlternatives

Overview

Spring Framework
Spring Framework
Stacks6.5K
Followers886
Votes0
GitHub Stars59.1K
Forks38.8K
Apache Struts
Apache Struts
Stacks61
Followers57
Votes0
GitHub Stars1.3K
Forks833

Apache Struts vs Spring Framework: What are the differences?

Introduction

Apache Struts and Spring Framework are two popular Java frameworks used for developing web applications. While both frameworks provide tools and features to simplify the development process, they have several key differences that developers should consider when choosing the right framework for their project.

1. MVC Architecture:

Apache Struts is based on the Model-View-Controller (MVC) architecture, which helps in separating the presentation logic from business logic. It provides a controller servlet that handles the flow of requests and manages the application's states. On the other hand, Spring Framework follows the Model-View-Controller (MVC) design pattern, which provides more flexibility and allows developers to use various view technologies like JSP, Thymeleaf, or HTML.

2. Dependency Injection:

Spring Framework is well-known for its powerful dependency injection container. It allows developers to define and manage bean dependencies effectively. The framework promotes loose coupling and makes it easier to test and maintain the code. Apache Struts does not provide its own built-in dependency injection mechanism, making it less flexible and more tightly coupled.

3. Component-based vs Convention-based:

Spring Framework follows a component-based approach, where developers can choose components as needed and configure them accordingly. It offers a wide range of components like controllers, services, repositories, etc., providing more flexibility. In contrast, Apache Struts follows a convention-based approach, where developers need to follow specific naming and configuration conventions. This can be helpful in reducing development time but may limit customization options.

4. ORM and Data Access:

Spring Framework provides strong support for object-relational mapping (ORM) frameworks like Hibernate or JPA. It offers seamless integration with these frameworks, making it easy to develop database-related applications. Apache Struts, on the other hand, does not provide explicit support for ORM frameworks and relies on external libraries for data access operations.

5. Integration with Other Frameworks and Libraries:

Spring Framework has extensive integration support with other Java frameworks and libraries. It can seamlessly integrate with technologies like ORM, security frameworks, messaging frameworks, and more. Apache Struts, although it provides good integration capabilities, may have limited options compared to Spring in terms of integrating with various third-party libraries and frameworks.

6. Community and Support:

Spring Framework has a large and active community, with a vast amount of resources, forums, and documentation available. It is continuously being developed and maintained, providing regular updates and bug fixes. Apache Struts, although still used in some legacy applications, has seen a decrease in community involvement and fewer resources compared to Spring.

In Summary, Apache Struts and Spring Framework differ in terms of their architectural approaches, dependency injection capabilities, customization options, ORM and data access support, integration with other frameworks and libraries, and community support. Developers should carefully analyze their project requirements and choose the framework that best suits their needs.

Share your Stack

Help developers discover the tools you use. Get visibility for your team's tech choices and contribute to the community's knowledge.

View Docs
CLI (Node.js)
or
Manual

Advice on Spring Framework, Apache Struts

juan9222
juan9222

Jul 25, 2020

Needs advice

Hi there, I'm deciding the technology to use in my project.

I need to build software that has:

  • Login
  • Register
  • Main View (access to a user account, News, General Info, Business hours, software, and parts section).
  • Account Preferences.
  • Web Shop for Parts (Support, Download Sections, Ticket System).

The most critical functionality is a WebSocket that connects between a car that sends real-time data through serial communication, and a server performs diagnosis on the car and sends the results back to the user.

616k views616k
Comments

Detailed Comparison

Spring Framework
Spring Framework
Apache Struts
Apache Struts

It provides a comprehensive programming and configuration model for modern Java-based enterprise applications - on any kind of deployment platform. The framework's core features can be used by any Java application, but there are extensions for building web applications on top of the Java EE platform.

It is a free, open-source, MVC framework for creating elegant, modern Java web applications. It favors convention over configuration, is extensible using a plugin architecture, and ships with plugins to support REST, AJAX and JSON.

Lightweight; Dependency Injection; Transaction Management
MVC framework; extensible using a plugin architecture; ships with plugins to support REST, AJAX and JSON
Statistics
GitHub Stars
59.1K
GitHub Stars
1.3K
GitHub Forks
38.8K
GitHub Forks
833
Stacks
6.5K
Stacks
61
Followers
886
Followers
57
Votes
0
Votes
0
Integrations
AngularJS
AngularJS
MySQL
MySQL
NetBeans IDE
NetBeans IDE
Hibernate
Hibernate
IntelliJ IDEA
IntelliJ IDEA
AngularJS
AngularJS
Java
Java
Hibernate
Hibernate

What are some alternatives to Spring Framework, Apache Struts?

Node.js

Node.js

Node.js uses an event-driven, non-blocking I/O model that makes it lightweight and efficient, perfect for data-intensive real-time applications that run across distributed devices.

Rails

Rails

Rails is a web-application framework that includes everything needed to create database-backed web applications according to the Model-View-Controller (MVC) pattern.

Django

Django

Django is a high-level Python Web framework that encourages rapid development and clean, pragmatic design.

Laravel

Laravel

It is a web application framework with expressive, elegant syntax. It attempts to take the pain out of development by easing common tasks used in the majority of web projects, such as authentication, routing, sessions, and caching.

.NET

.NET

.NET is a general purpose development platform. With .NET, you can use multiple languages, editors, and libraries to build native applications for web, mobile, desktop, gaming, and IoT for Windows, macOS, Linux, Android, and more.

ASP.NET Core

ASP.NET Core

A free and open-source web framework, and higher performance than ASP.NET, developed by Microsoft and the community. It is a modular framework that runs on both the full .NET Framework, on Windows, and the cross-platform .NET Core.

Symfony

Symfony

It is written with speed and flexibility in mind. It allows developers to build better and easy to maintain websites with PHP..

Spring

Spring

A key element of Spring is infrastructural support at the application level: Spring focuses on the "plumbing" of enterprise applications so that teams can focus on application-level business logic, without unnecessary ties to specific deployment environments.

Spring Boot

Spring Boot

Spring Boot makes it easy to create stand-alone, production-grade Spring based Applications that you can "just run". We take an opinionated view of the Spring platform and third-party libraries so you can get started with minimum fuss. Most Spring Boot applications need very little Spring configuration.

Android SDK

Android SDK

Android provides a rich application framework that allows you to build innovative apps and games for mobile devices in a Java language environment.

Related Comparisons

Bootstrap
Materialize

Bootstrap vs Materialize

Laravel
Django

Django vs Laravel vs Node.js

Bootstrap
Foundation

Bootstrap vs Foundation vs Material UI

Node.js
Spring Boot

Node.js vs Spring-Boot

Liquibase
Flyway

Flyway vs Liquibase