Spring Module parsing

Source: Internet
Author: User
Tags aop arithmetic operators

The Pring framework is composed of about 20 modules. These modules are divided into core containers, data access/integration, WEB,AOP (aspect-oriented programming), instrumentation,messaging, and test, as shown in the following figure.

The

The following sections list the available modules for each feature, their artifact names, and the topics they cover. The artifact name is associated with the artifact ID used in the Dependency management tool. The core Container core container consists of Spring-core, Spring-beans,spring-context,spring-context-support, and spring-expression (Spring expression Language) are composed of 5 modules. The Spring-core and Spring-beans modules provide the basic components of the framework, including IOC and dependency injection features. Beanfactory is a complex factory model implementation. It eliminates the need for programmatic single cases and allows the separation of the configuration and specification of dependencies in the actual program logic. The context (Spring-context) module is established by a core and a legume module set on a solid substrate: it is a device that accesses a frame style that is similar to a Jndi registry object. The context module inherits its features from the Beans module and adds support for internationalization (for example, using resource bundles), event propagation, resource loading, and, for example, the creation of contextual transparency for the servlet container. The context module also supports Java EE features such as EJB,JMX and basic remoting. The ApplicationContext interface is the focus of the context module. Spring-context-support provides support for integrating common third-party libraries into the context of the spring application, especially for caching (Ehcache,jcache) and scheduling (Commonj,quartz). The Spring-expression module provides a powerful expression language for querying and manipulating an object graph at run time. It is an extension of the Unified Expression language (Unified El) as defined in the JSP 2.1 specification. The language supports setting and getting property values, property assignments, method invocations, accessing the contents of the array, collections and indexers, logical and arithmetic operators, named variables, and retrieving objects by name from spring's IOC container. It also supports list prediction and selection as well as common list aggregation. AOP and Instrumentation (instrumentation)

The SPRING-AOP module provides a aspect-oriented programming implementation that conforms to the AOP Alliance, allowing you to define method interceptors and pointcuts to cleanly detach code that implements the functionality that should be detached. With the source level metadata feature, you can also use behavior information similar to. NET properties into your code.

The Spring-aspects module provides integration with the ASPECTJ.

The Spring-instrument module provides class-tool support and ClassLoader implementations for use in a particular application server. The Spring-instrument-tomcat module contains the Tomcat Spring tool agent. Messaging

The Spring Framework 4 includes spring-messaging from the critical Abstraction Module Spring integration project, such as Message,messagechannel,messagehandler, and others as a basis for messaging based applications. The module also includes a set of annotations to map messages to methods, similar to the programming model based on the spring MVC annotation. Data access/integration (Access/integration)

The data access/integration layer is provided by the JDBC,ORM,OXM,JMS and the transaction module. The SPRING-JDBC module provides a jdbc-abstraction layer eliminates the need for verbose JDBC encoding and database vendor-specific error code resolution. The SPRING-TX module supports programming and declarative transaction management for implementing special interfaces and classes for all Pojo (normal Java objects). The Spring-orm module provides an integration layer for the popular object-relational mapping APIs, including JPA and Hibernate. Using the Spring-orm module, you can use these O/R mapping frameworks in conjunction with all other features provided by spring, such as the simple declarative transaction management features mentioned earlier. The SPRING-OXM module provides an abstraction layer that supports object/XML mapping implementations such as JAXB,CASTOR,JIBX and XStream. The SPRING-JMS module (Java Messaging Service) contains features for generating and using messages. Since the spring Framework 4.1, it has provided integration with the Spring-messaging module. Web

The network layer consists of Spring-web, SPRING-WEBMVC and Spring-websocket modules.
1. The Spring-web module provides basic web-oriented integration features, such as multiple file uploads, initialization of the IOC container using servlet listeners, and web-oriented application contexts. It also contains a web-related part of HTTP client and spring Remoting support.
2. The Spring-webmvc module (also known as the Web-servlet module) contains spring's model-view-controller (MVC) and Web application's Rest Web service implementations. Spring's MVC framework provides a clear separation between domain model code and Web Forms, and integrates with all other features of the spring framework. test (testing)

The Spring-test module supports unit testing and integration testing of the Spring component using JUnit or TestNG. It provides consistent spring loading applicationcontext and caching of these contexts. It also provides a mock object that you can use to test your code individually. Working with scenes

The building blocks described earlier make spring a reasonable choice in many scenarios, from embedded applications running on resource-constrained devices to full enterprise applications that integrate with the Spring transaction management feature and the web framework.
using the spring middle tier of a Third-party Web framework:

Spring's declarative transaction management capabilities make Web applications fully transactional, just as transactions are managed using EJB containers. All custom business logic can be implemented with simple Pojo and managed by spring's IOC container. Additional services include support for sending e-mail and validation independent of the Web tier, which allows you to choose where to perform validation rules. Spring's ORM support integrates with JPA and hibernate; For example, when using Hibernate, you can continue to use your existing mapping file and the standard hibernate sessionfactory configuration. The form controller integrates the network layer seamlessly with the domain model without using actionforms or other classes that convert HTTP parameters to the values of your domain model.
using the spring middle tier of a Third-party Web framework:

Sometimes situations don't allow you to completely switch to a different frame. The spring framework does not force you to use everything in it; This is not a solution that is all or no solution. An existing front-end built with STRUTS,TAPESTRY,JSF or other UI frameworks can be integrated with a spring based middle tier, allowing you to use the Spring transaction feature. You just need to use a link to your business logic, ApplicationContext and use a webapplicationcontext to integrate your Web layer.

Remote usage:

When you need to access existing code through a Web service, you can use spring's hessian-,rmi-or Httpinvokerproxyfactorybean classes. Enabling remote access to an existing application is not difficult.

EJBs-Packaging of existing Pojo:

The spring framework also provides a level of access and abstraction for enterprise JavaBeans, allowing you to reuse existing Pojo and wrap it in stateless session beans for scalable, fail-safe Web applications that may require declarative security. Spring Framework Artifacts

GroupId Artifactid Description
Org.springframework Spring-aop Broker-based AOP support
Org.springframework Spring-aspects Based on the ASPECTJ aspect
Org.springframework Spring-beans Beans support, including groovy
Org.springframework Spring-context When the application context is running, including scheduling and remote abstraction
Org.springframework Spring-context-support Classes that support the integration of common third-party libraries into the context of the spring application
Org.springframework Spring-core Core utilities, many other spring modules use
Org.springframework Spring-expression Spring expression Language (spel)
Org.springframework Spring-instrument JVM-Guided instrumentation proxy
Org.springframework Spring-instrument-tomcat Tomcat's instrumentation Agent
Org.springframework Spring-jdbc JDBC Support packages, including datasource settings and JDBC Access support
Org.springframework Spring-jms JMS support packages, including help classes for sending and receiving JMS messages
Org.springframework Spring-messaging Support Messaging architecture and protocols
Org.springframework Spring-orm Object/relationship mappings, including JPA and hibernate support
Org.springframework Spring-oxm Object/XML Map
Org.springframework Spring-test Support Unit testing and integration test Spring components
Org.springframework Spring-tx Trading infrastructure, including DAO support and JCA integration
Org.springframework Spring-web Web support packages, including client and web remoting
Org.springframework Spring-webmvc Rest Web services and Model view controller implementations for Web applications
Org.springframework Spring-websocket WebSocket and SOCKJS implementations, including stomp support

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.