O'Reilly logo

WS-BPEL 2.0 Beginner's Guide by Denis Weerasiri, Matjaz B. Juric

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Time for action – selecting the bookstore with the lowest quantity

In the previous chapter, we introduced three bookstores into our composite BPEL application, BookstoreA, BookstoreB, and AnotherBookstore. Let's now modify the conditions in the <if> activity, where we select the bookstore with the lowest book quantity. We have to compare three book quantities of stores in the BookstoreAResponse, BookstoreBResponse, and AnotherBookstoreResponse variables. To access the BookstoreAResponse quantity, we should use the following XPath expression:

$BookstoreAResponse.payload/ns1:StockQuantity

Similarly, we would access the BookstoreB and AnotherBookstore stock quantities.

To select the lowest quantity, we should do the following comparisons:

  • Compare the ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required