The Spring Framework is an open source application framework that aims to make J2EE development easier. In this chapter we'll look at the motivation for Spring, its goals, and how Spring can help you develop high-quality applications quickly.
Spring is an application framework. Unlike single-tier frameworks such as Struts or Hibernate, Spring aims to help structure whole applications in a consistent, productive manner, pulling together best-of-breed single-tier frameworks to create a coherent architecture.
Since the widespread implementation of J2EE applications in 1999/2000, J2EE has not been an unqualified success in practice. While it has brought a welcome standardization to core middle-tier concepts such as transaction management, many—perhaps most—J2EE applications are over-complex, take excessive effort to develop, and exhibit disappointing performance. While Spring is applicable in a wide range of environments—not just server-side J2EE applications—the original motivation for Spring was the J2EE environment, and Spring offers many valuable services for use in J2EE applications.
Experience has highlighted specific causes of complexity and other problems in J2EE applications. (Of course, not all of these problems are unique to J2EE!) In particular:
J2EE applications tend to contain excessive amounts of "plumbing" code. In the many code reviews we've done as consultants, time ...