What is SOA?
SOA is an architectural model that can be distributed, combined, and used by the network based on the needs of the loosely coupled coarse granular application components. The service layer is the foundation of SOA, which can be used directly to be applied, so that people with the software agent interact with the software agent are dependent.
The key to the SOA is the "service" concept. W3C defines the service as: "The service provider completes a set of work to deliver the final result of the service user. The final result usually makes the user's state change, but also It may make the status of the provider, or both parties have changed. "
Service-architecture.com defines SOA as: "Essentially the collection of services. The service is communicated with each other, which may be simple data transfer, or two or more service coordination for certain activities. Service. Service Some methods are needed to connect. The so-called service is a function of accurate definition, well-packaged, independent of the environment and status of other services. "LooselyCoupled.com defines SOA:" The system is connected to the resource. In SOA, The resource is provided as other members of the network as a standalone service that can be accessed by standard. Compared to the traditional system structure, SOA specifies more flexible loose coupling relationships between resources. "
Gartner describes SOA as: "The software design method of the client / server, one application consists of software service and software service users ... SOA is different from most common client / server models, which is highly Emphasize the loose coupling of software components and use independent standard interfaces. "
Gartner believes that the combination of BPM and SOA has a great help for all types of application integration. "SOA is greatly benefited from BPM technology and methodology, but the true problem facing SOA is to establish the correct corporate awareness, namely: strengthen strategy The SOA program (for supply and use) and encourage reuse. "
Although different vendors or individuals have different understandings, we can still see several key features of SOA from the above definition: a coarse granular, loosely coupled service architecture, and services are simplified and accurately defined. Communication does not involve the underlying programming interface and communication model. It is important to pay attention to that SOA is not a new thing. The large IT organization has successfully built and deploying SOA applications for many years. This is much longer than existing XML and Web services. IBM CICS and BEA TUXEDO are two technical examples used to build SOA applications.
The focus shows that SOA is not an off-the-shelf technology, but a method of architecture and organization of IT infrastructure and business functions. SOA is a model for designing, development, deploying, and managing discrete logic units (serving) in a computational environment. This definition clarifies the range of SOA.
SOA requires developers to design a collection of services. SOA requires developers to jump out of the application itself, consider reused existing services, or thinking about how their services can be reused by other projects. A key benefit that "separate", "independent", "well-packaged" service is that there can be used in a variety of different methods to combine them into larger services, thereby reuse.
However, SOA is not just a development method? It also has the advantages of management. For example, the administrator now can directly manage the same services built by developers, which is much better than in the past management. By analyzing the interaction between services, SOA can help companies understand when and why business logic is implemented, which enables administrators or analysts to optimize business processes. Basic characteristics of SOA
The implementation of SOA has several distinctive basic features. The key objective of implementing SOA is to maximize the importance of enterprise IT assets. To achieve this goal, we must keep in mind the following features during the implementation of SOA: 1 can be accessed from the outside of the company
Usually known as external users of business partners can also access the same services as within the company's internal users. Business partners cooperate with each other using advanced B2B protocols (EBXML or ROSETTATAT). When business partners are based on business-based exchange business information, they participate in a session. The session is a collection of one or more business information between business partners. The session type (more conversation is complex or simple, long or short, etc.) depends on the business purpose. In addition to the B2B protocol, external users can also access corporate services provided in Web service. 2 Available at any time available When there is a service user request service, SOA requirements must have a service provider to respond. Most SOAs can provide services for synchronous applications such as portal applications and asynchronous applications such as B2B. Synchronous applications have strong dependence on the services they use. Many synchronous applications are usually deployed at the front desk, and its end users are easily influenced by the shortage of service providers. In many cases, synchronization applications use a distributed service provider that can respond to more user requests. However, with the increase in the number of servers that provides specific service functions, the possibility of shortage has increased in an index level. In contrast, asynchronous applications are more robust because they are designed with queue requests, so they can allow the service provider shortage or hysteresis. Asynchronous Application Most cases are deployed in the background, users usually will not be a short shortage. In most cases, asynchronous applications can stabilize short-term shortages, but long-term shortages will trigger serious problems. In the service shortage resolution, the queue engine pushes a rare large number of work to the shared application resource, there may be a queue overflow or even a service deadlock. Service users are required to provide synchronous services, usually based on their own understanding or usage habits. In most cases, an asynchronous model can achieve the same effect, but it is more possible to reflect the best features of SOA. Of course, not all circumstances should be used asynchronous design mode. However, in most cases, asynchronous messages ensure the scalability of the system under different loads, especially in the interface response time is not very short. 3 coarse granular service interface
Rough granular service provides a specific business function, while fine-grained services represent technical components. For example, the most clear ?? Add a customer to the billing system is a typical coarse granular service, and you can use several fine-grained services to implement the same function, such as adding the customer name into the billing system, add details Customer contact information, add billing information, etc. The advantage of using a coarse particle size service interface is that no need to perform multiple times between the user and the service layer, and the reciprocity is sufficient. The security TCP / IP session in the Internet environment is no longer dominated, and the cost of establishing the connection is too high, so the advantages of the coarse grain size service interface are more obvious during application development. Remove basic reciprocation efficiency, the problem of transaction stability is also important. The multi-stage requests included in a separate transaction may cause the transaction time to overexpose, resulting in a background service timeout, thereby abort. In contrast, from the perspective of transaction, requesting large block data to the background service may be the only way to get feedback. 4 level
An argument about coarse particle size services is a reuse of such services than fine particle size services, because coarse particle size services tend to solve specifically business problems, so poor universality, difficulty design is difficult. One way to solve this controversy is to allow different coarse granular grades to create services. Such a service level includes a fine particle size, high reuse, also includes a wide particle size and a poor reusability. In terms of service grading, you must pay attention to the public service of the service layer usually consist of an existing local service in the background system (BES's) or SOA platform. Therefore, it is important to allow private services to create private services in the service layer. The correct documentation, the reuse of configuration management and private services has an important impact on the ability of IT departments to quickly develop new open services in SOA service layers. 5 loosely coupled coupling
SOA has a "loose coupling" component service, which is distinguished from most other component architectures. This method is intended to separate service users and service providers from service implementation and how customers use service. The key point behind the service provider and service user loose coupling is that the service interface exists as an entity that is separated from the service. This is the service implementation to be modified without affecting the service user. Most loose coupling methods rely on a service-based message. Message-based interfaces are compatible with multiple transmission modes (such as HTTP, JMS, TCP / IP, MOM, etc.). Message-based interfaces can be implemented with synchronous and asynchronous protocols, and the Web Services is an important standard for SOA service interfaces. When the user calls a web service, the called object can be a CICS transaction, a DCOM or a CORBA object, J2EE EJB or TUXEDO service, but this is not related to the service user. The underlying implementation is not important. Message Web services are usually loose coupling and document drivers, which is superior to the connection to the service specific interface. When a customer calls a message web service, the customer usually sent a complete document (such as a purchase order), not a set of discrete parameters. The web service receives the entire document, processes, and then may or will not return the result information. Since there is no tight coupling request response between customers and web services, message web services provide more loose coupling between customers and servers. 6 Reusable service and service interface design management
If you are designed in a reusable principle, SOA will make it more flexible. The reusable service uses the general format to provide important business functions to save the developers a lot of time. Design reusable services are the most valuable work similar to database design or universal data modeling. Since the service design is the key to success, the SOA implementer should find an appropriate method for service design process management. The service design management fundamentally is a service design problem, and the service design needs to be compromised in two points. Take the shortcut project tactics and the enterprise to build a long-term goal of reusable common services. Transcending the project short-term goal for the development and assessment of the service interface is an important step towards the precise definition of the service interface, and it also needs to set up a standard for interface documents, services to document and all important non-functional feature. A prerequisite for reuse in large organizations is to establish a general (design phase) service library and development process to ensure the correctness and versatility of reuse. In addition, the evaluation of service documents descriptated and developed is also the key to successfully utilizing service libraries. Briefly, it is not possible to ensure the successful implementation of the SOA that provides reuse. Financial expenses are generated during the implementation of the rules, and it is necessary to consider when the SOA implementation plan is set. 7 Standardized interface
In recent years, two important standards XML and Web services have added new important functions to push SOA to higher levels and greatly enhance the value of SOA. Although the past SOA products are proprietary and require IT departments to develop all applications in their specific environments, XML and Web services standardized openness allows companies to use SOA in all technologies and applications deployed. This has a huge meaning! The web service enables the application function to be provided by the Standard Interface (WSDL) and can be called based on standardized transmission mode (HTTP and JMS), using a standardization protocol (SOAP). For example, developers can easily create a new portal application with tools that are best suited for portal development and reuse existing services in the ERP system and customizing J2EE applications, but do not need to understand the internal work of these applications. With XML, the portal developers do not have to understand the specific data representation format, they can easily exchange data between these applications. You can also create SOA applications without Web services or XML, but the importance of these two standards is increasing, and the application is increasingly common. Although only several service users are currently supporting this standard, most of the service users in the future will use them as a business service access method. 8 support a variety of message modes
The following message mode may be present in the SOA. In a SOA implementation, a mix of different message modes will often occur. Q No stateful message. Each message sent by the user to the provider must include all the information required for the provider to process the message. This limitation makes the service provider do not need to store the status information of the user, making it easier to expand. q There is a stateful message. Users share the user's specific environmental information with the provider, this information is included in the message exchanged in the provider and user. This limitation makes the provider more flexible with the user's communication, but because the service provider must store the shared environment information of each user, its overall scalability is significantly reduced. This limits enhances the coupling relationship between service providers and users, and improves the service difficulty of the exchange service provider. Q, etc. power messages. The effect of sending multiple repetition messages as the software agent is the same as the sending single message. This limitation enables providers and consumers to improve the service reliability when the failure is fails. 9 Precisely defined service interface services are defined by the provider and the user. The contract specifies the final result of service usage and user expectations. In addition, the quality of service can be specified in it. The key points you need to pay attention to here are that the service contract must be precisely defined. Meta defines SOA as: "A generic purpose, scalable, combined collaborative architecture, all processes are defined as a service, and serve the service provider through the service interface based on the package-based service interface, the service interface The extended identifier, format, and protocol are separately described. "The last part of this definition indicates a clear boundary between the service interface and its implementation. SOA advantages
Understand the definition and basic characteristics of SOA, and finally let's take a look at the potential advantages of SOA:
Encoding flexibility
The high-level service can be created based on the modular low-level service, which is reused, which reflects the flexibility of the encoding. In addition, this service implementation method itself can be used flexibly because the service user does not directly access the service provider.
Clear developer role
For example, developers who are familiar with BES can focus on reuse accessories, and coordinate developmenters do not have to understand BES-based implementation, and will focus on resolving high-value business issues.
Support a variety of customer types
With precisely defined service interfaces and support for XML, Web service standards, you can support a variety of customer types, including new access channels such as PDA, mobile phones.
More easy to maintain
The loose coupling relationship of service providers and service users and the adoption of open standards ensure this feature. Better scalability
Relying on the architecture model used by service design, development, and deployment. Service providers can adjust each other to meet service needs.
Higher availability
This feature is reflected in the loose coupling relationship between the service provider and the service user. Users do not need to understand the details of the provider, so that the service provider can be flexibly deployed in the WebLogic cluster environment, and the user can be transferred to the available routines.
SOA can be seen as a B / S model, and the natural extension after the XML / Web Service technology. SOA will be able to help us to stand in a new highly understood in the development, deployment form of various components in an enterprise architecture, which will help enterprise system architects throughout the business system, more reliable and more reused architecture. Conventionally, the system of SOA architecture can be more calmly faced with a sharp change in the business.
Author: Cui Xiaobo BEA Systems (China) Co., Ltd. Senior Technical Consultant