Search icon CANCEL
Subscription
0
Cart icon
Your Cart (0 item)
Close icon
You have no products in your basket yet
Arrow left icon
Explore Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Conferences
Free Learning
Arrow right icon
Arrow up icon
GO TO TOP
WS-BPEL 2.0 Beginner's Guide

You're reading from   WS-BPEL 2.0 Beginner's Guide Design and develop WS-BPEL executable business processes using Oracle SOA Suite 12c

Arrow left icon
Product type Paperback
Published in Sep 2014
Publisher
ISBN-13 9781849688963
Length 388 pages
Edition 1st Edition
Languages
Arrow right icon
Toc

Table of Contents (14) Chapters Close

Preface 1. Hello BPEL FREE CHAPTER 2. Service Invocation 3. Variables, Data Manipulation, and Expressions 4. Conditions and Loops 5. Interaction Patterns in BPEL 6. Fault Handling and Signaling 7. Working with Scopes 8. Dynamic Parallel Invocations 9. Human Tasks 10. Events and Event Handlers 11. Compensations A. Pop Quiz Answers Index

Time for action – creating XML Schema for the BPEL process

Before we can start developing our BPEL process, we have to specify the XSD elements used for the input and output messages (for the request and the response message). Also, the XSD elements are used for variables within the BPEL process.

The XML schema has already been created and can be found in the BookstoreABPEL.xsd file. The default XSD elements for request and response contain only strings, which are not adequate for our example. Therefore, we will modify it.

First, we will rename it from BookstoreABPEL.xsd to BookstoreBPEL.xsd. The reason is that we might use same XSD for more than one bookstore, so we would like to have a generic XSD filename.

Our request element consists of the following elements: book ISSN, book title, edition, and date of publishing. The response element consists of the following elements: book ISSN and stock quantity.

We will perform the following steps:

  1. To rename XSD, right-click on the BookstoreABPEL.xsd file in the project tree, select Refactor, and then Rename:
    Time for action – creating XML Schema for the BPEL process
  2. In the dialog box, enter the new name, BookstoreBPEL.xsd.
  3. Double-click on the BookstoreBPEL.xsd file in the Schemas folder and switch to source view.
  4. We have to define two complex elements. First, edit the existing process element, rename it to the BookData element, and enter the code shown in the following screenshot:
    Time for action – creating XML Schema for the BPEL process
  5. Next, define the content of the processResponse element, which we will rename to BookDataResponse and add the two elements shown in the following screenshot:
    Time for action – creating XML Schema for the BPEL process

Before we continue, let's save the XSD file.

What just happened?

We created the XSD elements used by the BPEL process. To be more accurate, we modified the autogenerated XSD file and specified the request element (BookData) and the response element (BookDataReponse).

The request element (BookData) is used as the input for the initial receive activity (receiveInput). The response element (BookDataReponse) is used by the final reply activity (replyOutput).

This is specified in the autogenerated WSDL file, which you can find in the WSDLs folder. It is named BookstoreABPEL.wsdl. Let's have a look at it.

You have been reading a chapter from
WS-BPEL 2.0 Beginner's Guide
Published in: Sep 2014
Publisher:
ISBN-13: 9781849688963
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at $19.99/month. Cancel anytime
Banner background image