First, Spring introduction
Spring is a framework extracted from real-world development, so it has done a lot of common steps in development, leaving developers with only the parts that are relevant to a particular application, providing a significant development efficiency for enterprise applications
Spring provides a lightweight solution for enterprise application development. This solution includes: core mechanism based on dependency Injection , declarative transaction management based on AOP , integration with multiple persistence layer technologies, and excellent Web MVC framework .
Spring is dedicated to Java EE application-level solutions, rather than just focusing on a single layer of solutions. It can be said that spring is a "one-stop" choice for enterprise application development, and spring is a presentation, business, and persistence layer
Advantages of Spring:
1, low-intrusive design, code pollution is very low
2, independent of various application servers, based on the application of Spring framework, can truly realize the commitment of write Once, Run anwhere
3. The Spring di container reduces the complexity of business object substitution and provides decoupling between components
4. Spring's AOP support allows for centralized processing of some common tasks such as security, things, logs, etc., providing better reuse
5. Spring's ORM and DAO provide good integration with third-party persistence layer frameworks and simplify the underlying database access
6, Spring's high openness, does not enforce the application is completely dependent on spring, the developer is free to choose some or all of the spring frame
When using the spring framework, you must use the Spring core Container (the Spring container), which represents the core mechanism of the spring framework, mainly by core, beans, context, expression ( Spring3.0 added: Provides spring Expression language support) consisting of four packages and their sub-packages, mainly providing spring IOC container support
Ii. changes in Spring3.0
Compared with Spring2.5, the changes in Spring3.0 are:
1, Spring3.0 no longer adopt the former unified construction method, but instead use the organization mode of multi-project structure; spring's release no longer provides a full packaged file: Spring.jar, but consists of 20 jar packages
2. Spring no longer provides with-dependencies downloads, the developer must download the Spring core project and spring dependencies (the third-party class library on which spring compiles and runs)
3, Spring3.0 has been fully developed and compiled with JAVA5, no longer support Java1.4 or earlier versions
4, Spring3.0 introduced a new function: Expression language (EL) support, referred to as Spel
5. Spring3.0 also adds a feature: Use Java class configuration instead of XML configuration
Spring-----Spring Introduction