Time for action – declaring a business event

To declare the BookshelfEvent business event, we will go to the composite view. We will proceed as follows:

  1. Right-click on the project in the Application window and select New and then Event Definition:
    Time for action – declaring a business event
  2. A Create Event Definition dialog box will open. We will specify the EDL filename. This is the file where all the events are defined (similar to WSDL, where the web service operations are defined). We will use the BookEDL for the EDL filename. For the Namespace field, we will use http://packtpub.com/events/edl/BookEDL, as shown in the following screenshot:
    Time for action – declaring a business event
  3. Next, we need to define the business events. We will use the green plus sign to declare the BookshelfEvent business event. After clicking on the green plus sign, the Create Event dialog box will open. We need to specify the event name, which is BookshelfEvent. We also have to specify the XML Type, which will be used for the event data payload. We will use the BookData from the Book Warehousing BPEL process schema, as shown in the following screenshot:
    Time for action – declaring a business event
  4. After clicking on the OK button, we should see the following:
    Time for action – declaring a business event

What just happened?

We have successfully declared the BookshelfEvent business event. This has generated the BookEDL.edl file with the source code as shown in the following screenshot:

What just happened?

Developing a book shelving BPEL process

After declaring the business event, we are ready to develop the event-driven book shelving BPEL process. The process will be triggered by our BookshelfEvent business event. This means that the process will not have a classic WSDL with the operation declaration. Rather it will be triggered by the BookshelfEvent business event.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset