[Reprinted] SOA technology Overview

Source: Internet
Author: User

What is SOA?

SOA is an architecture model that allows you to deploy, combine, and use loosely coupled coarse-grained application components in a distributed manner based on your needs. The service layer is the basis of SOA and can be directly called by applications to effectively control the human dependency between the system and the software agent.

The key to SOA is the concept of "service". W3C defines a service as "a service provider completes a set of work and delivers the final results required for service users. The final result usually changes the user's status, but may also change the provider's status, or both parties have changed ".

Service-architecture.com defines SOA as: "essentially a collection of services. Services communicate with each other. such communication may be simple data transmission, or two or more services coordinate certain activities. Some methods are required to connect between services. A service is a function that accurately defines, encapsulates, and is independent of the environment and status of other services ."

Looselycoupled.com defines SOA as: "A system that connects resources on demand. In SOA, resources are provided to other members of the Network as independent services that can be accessed in a standard way. Compared with the traditional system structure, SOA defines a more flexible and loose coupling relationship between resources ."

Gartner described SOA as: "the client/server software design method. An application consists of software services and software service users ...... SOA differs from most common client/server models in that it emphasizes loose coupling of software components and uses independent standard interfaces ."

Gartner believes that the combination of BPM and SOA will be of great help to all types of application integration ?? "SOA has benefited a lot from BPM technology and methodology, but the real problem facing SOA is to establish a correct corporate awareness, that is, to strengthen strategic SOA plans (for supply and use) and encourage reuse."

Although different vendors or individuals have different understandings of SOA, we can still see several key features of SOA from the above definition: a coarse-grained, loosely coupled service architecture, services communicate with each other through simple and precise interfaces, and do not involve underlying programming interfaces and communication models.

It should be noted that SOA is not a new thing ?? IT has been successfully built and deployed by large IT organizations for many years ?? This is much longer than the existing XML and Web services. Ibm cics and bea tuxedo are two technical examples used to build SOA applications in the past.

IT is important to note that SOA is not a ready-made technology, but a method for architecture and organization of IT infrastructure and business functions. SOA is a model for designing, developing, deploying, and managing discrete logical units (services) in a computing environment. This definition clarifies the scope of SOA.

SOA requires developers to design applications as a collection of services. SOA requires developers to think out of the application itself, consider the reuse of existing services, or think about how their services can be reused by other projects. One of the key advantages of "independent", "independent", and "encapsulated" services is that they can be combined into larger services in a variety of different ways, to achieve reuse.

However, SOA is not just a development method ?? It also has management advantages. For example, administrators can now directly manage the same services built by developers, which is far better than the previous method of managing a single application. By analyzing interactions between services, SOA helps enterprises understand when and why business logic is actually executed, which enables administrators or analysts to optimize business processes.

Basic Features of SOA

The implementation of SOA has several distinctive basic features. The key objective of implementing SOA is to achieve the maximum reuse of enterprise IT assets. To achieve this goal, we must keep in mind the following characteristics during the implementation of SOA:

1. access from outside the enterprise

External users, often referred to as business partners, can also access the same service as internal enterprise users. Business partners use advanced B2B protocols (ebXML or RosettaNet) for mutual cooperation. When business partners exchange business information for business purposes, they participate in a session. A session is a series of business information exchanges between business partners. The session type (the session is complex or simple, long, or short) depends on the business purpose.

In addition to the B2B protocol, external users can also access enterprise services provided by Web Services.

2 Available at any time

When a service user requests a service, SOA requires that a service provider be able to respond. Most SOA services can be provided for Synchronous applications such as portal applications and asynchronous applications such as B2B. Synchronous applications are highly dependent on the services they use.

Many synchronization applications are usually deployed on the frontend, and end users are vulnerable to a shortage of service providers. In many cases, synchronous applications use distributed service providers to respond to more user requests. However, as the number of servers providing specific service functions increases, the possibility of shortage also increases exponentially.

In contrast, asynchronous applications are more stable because they adopt the queue request design, which allows for service provider shortage or delay. Asynchronous applications are deployed in the background in most cases, and users are not aware of a short shortage. In most cases, asynchronous applications can stably cope with short-term shortage, but long-term shortage may cause serious problems. When the service shortage is solved, and the queue engine pushes a rare amount of work to the shared application resources, there may be queue overflow or even service deadlocks.

When a service user requests to provide a synchronization service, it is generally based on their own understanding or usage habits. In most cases, adopting an asynchronous model can achieve the same effect, but it can better reflect the best characteristics of SOA.

Of course, not all cases should adopt the asynchronous design mode. However, in most cases, asynchronous messages ensure system scalability under different loads, especially when the interface response time is not very short.

3. coarse-grained service interfaces

Coarse-grained services provide a specific service function, while fine-grained services represent technical component methods. Which of the following is the clearest example ?? Adding a customer to the billing system is a typical coarse-grained service, and you can use several fine-grained Services to implement the same function. For example, adding a customer name to the billing system, add detailed customer contact information and billing information.

The advantage of using coarse-grained service interfaces is that the user and service layer do not have to perform multiple reciprocating operations, and one reciprocating operation is sufficient. Guaranteed TCP/IP sessions in the Internet environment are no longer dominant, and the cost of establishing connections is too high. Therefore, the advantages of coarse-grained service interfaces in application development in this environment are even more obvious.

In addition to the basic reciprocating efficiency, transaction stability is also very important. Multi-segment fine-grained requests contained in a single transaction may cause the transaction to take a long time, cause the backend service to time out, and thus stop. On the contrary, from the transaction perspective, the only way to request large data blocks from the backend service may be to obtain feedback.

4. Classification

A debate about coarse-grained services is that such services are less reusable than fine-grained services, because coarse-grained services tend to solve specialized business problems, which makes it difficult to design versatility and reusability. One way to solve this debate is to allow different levels of coarse granularity to be used to create a service. Such service classification includes services with fine granularity and high reusability, as well as services with coarse granularity and poor reusability.

In terms of service classification, it should be noted that the public service at the service layer is usually composed of the background system (BES's) or the existing local service in the SOA platform. Therefore, it is very important to allow the creation of private services at the service layer. Correct documentation, configuration management, and reuse of private services have an important impact on the IT department's ability to quickly develop new public services at the SOA service layer.

5 loose coupling

SOA has "loose coupling" component services, which is different from most other component architectures. This method is designed to isolate service users from service providers in terms of service implementation and how customers use services.

The key point behind loose coupling between service providers and service users is that service interfaces exist as entities separated from services. This means that the service implementation can be modified without affecting the service users at all.

Most loose coupling methods rely on messages based on service interfaces. Message-based interfaces are compatible with multiple transmission modes (such as HTTP, JMS, TCP/IP, and MOM ). Message-based interfaces can be implemented using synchronous and asynchronous protocols. Web services are an important standard for SOA service interfaces.

When a user calls a Web service, the called object can be a CICS transaction, DCOM or CORBA object, J2EE EJB or TUXEDO service, but this has nothing to do with the service user. Underlying implementation is not important.

Interest-free Web services are usually loosely coupled and document-driven, which is better than the connection with specific service interfaces. When a customer calls a message-type Web service, the customer usually sends a complete document (such as a purchase order), rather than a set of discrete parameters. The Web Service receives, processes, and may or will not return results. Message-type Web Services provide loose coupling between customers and servers because there is no tightly coupled request response between customers and Web services.

6 reusable service and Service Interface Design Management

 

If services are designed in full accordance with reusable principles, SOA can make applications more flexible. Reusable services use common formats to provide important business functions, saving developers a lot of time. Designing reusable services is the most valuable work similar to database design or general data modeling. As service design is the key to success, SOA implementers should find an appropriate method for service design process management.

Service Design Management is basically a service design issue. service design needs to be compromised between two points ?? Project tactics that take shortcuts and the long-term goal of building reusable general services for enterprises.

Developing and evaluating service interfaces beyond the project's short-term objectives is an important step towards precisely defining service interfaces, you also need to set up standards for interface documents, service implementation documents, and all important non-functional features.

A prerequisite for reuse in large organizations is the establishment of a general (design phase) service library and development process to ensure the correctness and universality of reuse. In addition, evaluation of service documentation describing service design and development is also the key to successful use of the service library.

Simply put, writing services based on rules cannot guarantee the successful implementation of reusable SOA. Financial fees are incurred during the execution of rules and need to be taken into account when developing an SOA Implementation Plan.

7. Standardized Interfaces

In recent years, two important standards, XML and Web services, have added new important functions, pushed SOA to a higher level, and greatly increased the value of SOA. Although traditional SOA products are proprietary and require IT departments to develop all applications in their specific environments, however, the openness of XML and Web Service standardization enables enterprises to adopt SOA in all technologies and applications deployed. This is of great significance!

Web services enable application functions to be provided through the standardized interface (WSDL), and can be called Based on the standardized transmission method (HTTP and JMS) and using the standardized protocol (SOAP. For example, developers can easily create a new portal application using the most suitable tool for portal development, and reuse existing services in ERP systems and customized J2EE applications, there is no need to understand the internal working principles of these applications. With XML, portal developers can easily exchange data between these applications without having to know specific data representation formats.

You can also create SOA applications without using Web services or XML. However, these two standards are becoming increasingly important and increasingly common. Although only several service users currently support this standard, most service users will use it as an enterprise service access method in the future.

8 support various message Modes

The following message modes may exist in SOA. In an SOA implementation, services that use different message modes are often mixed.

Q: stateless message. Each message sent by the user to the provider must contain all the information required by the provider to process the message. This limitation makes it easier for the service provider to expand without storing the user's status information.

Q: A stateful message. The user and the provider share the user's specific environment information, which is contained in the messages exchanged between the provider and the user. This limitation makes the communication between the provider and the user more flexible, but because the service provider must store the shared environment information of each user, its overall scalability is obviously reduced. This limitation enhances the coupling between the service provider and the user, and increases the difficulty of switching the service of the service provider.

Q and other power messages. Sending repeated messages to the software proxy has the same effect as sending a single message. This limitation allows the provider and consumer to simply copy messages when a fault occurs, thus improving service reliability.

9. precisely defined service interfaces

A service is defined by a contract between the provider and the user. The contract specifies the service usage method and the final result expected by the user. In addition, you can specify the service quality. Note that the service contract must be precisely defined.

META defines SOA as: "A general-purpose, scalable, and collaborative architecture, all processes are defined as services, A service is delegated to a service provider through a class-encapsulated service interface, which is described separately based on the Extensible identifier, format, and protocol." The last part of the definition indicates that there is a clear boundary between the service interface and its implementation.

Advantages of SOA

After understanding the definition and basic features of SOA, let's look at the potential advantages of SOA:

Encoding flexibility

You can create high-level services based on Modular low-level services and different combinations to achieve reuse. These reflect the flexibility of coding. In addition, because service users do not directly access the service provider, this service implementation method can also be used flexibly.

Clarify developer roles

For example, developers familiar With BES can focus on Reusing the access layer, while developers at the coordination layer do not have to have a special understanding of the implementation of BES, but focus on solving high-value business problems.

Supports multiple customer types

With precisely defined service interfaces and support for XML and Web Service Standards, you can support a variety of customer types, including new access channels such as PDAs and mobile phones.

Easier maintenance

The loose coupling between service providers and service users and the adoption of open standards ensures the implementation of this feature.

Better scalability

Scalability is achieved by the architecture model used for service design, development, and deployment. Service providers can be independently adjusted to meet service requirements.

Higher availability

This feature is embodied in the loose coupling between service providers and service users. The user does not need to understand the implementation 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 available routines.

SOA can be seen as a natural extension after the B/S model and XML/Web Service technology. SOA will help us understand the development and deployment forms of various components in enterprise-level architecture from a new perspective, it will help enterprise system architects build the entire business system more quickly, reliably, and reusable. Compared with the past, SOA-based systems can face rapid business changes with greater ease.

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.