The Web Service-Oriented Business Process Execution Language (BPEL or BPEL4WS) is a language that uses Web Services to define and execute business processes. You can combine, orchestrate, and coordinate web services to implement a Service-Oriented Architecture (SOA) from top to bottom ). BPEL provides a relatively simple and easy-to-understand method that combines multiple web services into a new composite service (called a business process.
(1 ),BPELSpecificationsThe Business Process Execution Language for Web Services (BPEL4WS) specification of Web Services is positioned as a Web service standard for integration. You can create different activities that can complete Web service calls, throw a fault, or terminate a process, and then connect them to create a complex process. These activities can be nested into structured activities. structured activities define the running mode of the activities, such as string or column or parallel operations, depending on certain conditions. It is essentially a combination of IBM's WSFL and Microsoft's XLANG and has become an industry standard. WSFL supports graphical processes, and XLANG has unique methods in structural construction. BPEL4WS has learned the advantages of both and abandoned some complicated and complicated parts, it forms a natural high-level abstract language that describes business activities.
(2) features of the BPEL LanguageThe BPEL4WS language was less than a year since its birth. We can say that it is a new language, but it is not completely independent of the existing programming languages, we can summarize the following three highlights:
<1> BPEL4WS is not "new ": Why is it not new? This is mainly because, in terms of the syntax structure and programming ideology of the BPEL4WS language itself, it is familiar to the majority of programmers (of course, you must be familiar with the XML language and basic programming ideas, the concept of a distributed system, such as DCOM and CORBA, must also be established ). The syntax of BPEL4WS is fully based on XML specifications. If you do not consider its program language features, you can fully understand it as a common XML document specification, that is to say, all nodes in BPEL4WS can be mapped to a virtual DTD file. Without considering the features of the program, you can compile a common XML file only according to the specification defined in this DTD when writing a BPEL file. BPEL4WS is mainly based on the following XML specifications: WSDL 1.1, XML Schema 1.0, and xpath1.0. The WSDL message and XML Schema type definitions provide all the data models required by the BPEL4WS process. All required external resources and partners are described as the WSDL service.
If you study the syntax of BPEL4WS, you will find that it only inherits and develops the original programming language idea.
(1) concerning inheritance, the BPEL4WS language has some basic features of the traditional programming language, such:
Assign a value (the operation on "Assign" is completed );
Loop operation (completed by the while operation );
Select an operation (completed by the switch and case operations );
Remote Call operation (completed by the invoke operation );
The error capture operation is completed by the "catchfault" and "catchall" operations );
Error throw operation (completed by the throw Operation)
Try operations in Java and C # (completed by scope operations)
(2) In terms of development, BPEL4WS language is a language that combines the characteristics of business processing;
Because the BPEL4WS language is designed for the execution of business processes, it naturally has the characteristics of a business processing language, which is reflected in the following aspects:
2. synchronous and asynchronous processing of remote calls (<invoke>;
This is mainly determined by the characteristics of commercial processing. Take the civil aviation ticket booking as an example. When you send a ticket booking request to the Web Service of the Civil Aviation ticket booking system, you cannot expect immediate results (synchronization), because the civil aviation system must first perform complex identification to determine whether your system has the permission to book a ticket, then, you need to query the flight status to determine whether your flight has an empty seat. Then, you will receive a reply, and you cannot wait until you get a reply, even if you want your server, you may not be able to bear this burden. Therefore, you must select the asynchronous mode, that is, to continue other operations after the request is sent. This is similar to the relationship between the TCP/IP protocol and the UDP protocol.
2. provides parallel operations (supported by flow operations );
For general programming languages, the concept of parallelism is only used on the surface. For example, some may say that the multi-task execution capability of Windows (or Unix or Linux) is used, I can allow a program to execute computing in the background while complex human-computer interaction is performed in the foreground. Isn't it a parallel operation. Indeed, this is also a kind of parallelism, but it is only a CPU-Level Parallelism. the BPEL4WS language shows a wider range of parallelism and Internet-based parallelism. In some aspects, similar to traditional parallel processing systems (using clusters for Large-Scale Complex parallel computing ). With BPEL4WS, you can call web services (such as computing and ordering) located in different places (different cities or even countries) for processing at the same time ).
2. The compensation operation is supported by the compensate operation );
The execution of any program may fail, and the consequences are different. Some operation errors do not have any direct consequences, and some operation errors must be corrected, that is, some compensation operations must be performed. For example, if customer a subscribes to a ticket in the system, when the Web Services of the civil aviation system completes all the ticket booking operations and submits the ticket to Customer A for confirmation, if Customer A cancels the ticket booking operation or the system fails for other reasons, the customer a must perform the compensation operation, cancel all the operations that have been performed, and restore the database information. In a certain aspect, this is very similar to the rollback operation in DBMS, but it is executed at a micro level in the database system, while it is executed at a macro level in BPEL4WS.
<2> BPEL4WS is not "executable ": Although BPEL4WS is defined as a commercial Execution Language, it does not actually execute any details in the commercial process, that is, it does not involve the storage and processing of commercial data at all. The BPEL4WS language is essentially a descriptive language. When does it only describe? In what order? Where? Which Web services are called? How to organize these calls? No. Therefore, there are no complex data structures and Data Types in BPEL4WS, and there are no operations on data storage and persistence, the only thing that involves explicit data operations is the use of the "Assign", but the data is only temporary data. Once the business process ends, the data disappears, the data is like a variable in a traditional programming language, but it is not that complex. The BPEL4WS language is a commercial process execution language because, from a macro perspective, all operations are completed by BPEL4WS, and the operations behind it, such as web service calls, are invisible, that is to say, it is not transparent. This is like the black box test in software testing. Users only see the user interfaces they should see, instead of worrying about how these functions are implemented.
<3> BPEL4WS is a real distributed system: With the rapid development of Internet, new technical ideas are emerging in the field of distributed technology. Soap, XML, and Web Services Based on them. The emergence of these new technologies provides a solid foundation for the new distributed processing model. The birth of BPEL4WS is the true sublimation of distributed technology. Compared with the traditional distributed system, the distributed system implemented by BPEL4WS has higher flexibility, which is mainly reflected in the following aspects:
1> nodes can be heterogeneous systems;
2> You can dynamically select a node machine for processing during running;
3> various communication protocols can be used for communication as long as they comply with the SOAP protocol. ========================================================== ===================================== WS-BPEL 2.0 specifications see http://www.oasis-open.org
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.