advertisement

Facilitating Rich Data Manipulation in BPEL using E4X

50 %
50 %
advertisement
Information about Facilitating Rich Data Manipulation in BPEL using E4X
Technology

Published on March 4, 2009

Author: vanto

Source: slideshare.net

Description

Talk at ZEUS 2009 about rich data manipulation in BPEL using E4X.
advertisement

Facilitating Rich Data Manipulation in BPEL  using E4X Tammo van Lessen, Jörg Nitzsche, Dimka Karastoyanova Institute of Architecture of Application Systems (IAAS) University of Stuttgart Universitätsstr. 38 70569 Stuttgart Germany tammo.van.lessen@iaas.uni‐stuttgart.de

The Talk Today Motivation and Introduction Combining WS‐BPEL with E4X Extension Assign Operation & Extension Activity Injecting BPEL variables Built‐in functions Conclusions © Tammo van Lessen 2

Problem Statement Business Analyst Process Developer © Tammo van Lessen 3

Low‐level Problems BPEL Variables must be initialized var TShoppingCart shoppingCart var TItem item var EItem eitem Data types are typically not aligned Create  Data mediation required Shopping selectionFailure Cart Array manipulation is cumbersome doXSLTransform AddItem Complete Custom XSL scripts needed Data type  Check Submit Reuse not possible mismatch Availability Order Add to Confirm doXSLTransform Cart © Tammo van Lessen 4

Alternatives BPELJ Use plain old Java snippets Pro: Easy to use Con: W3C DOM still quite cumbersome Semantic Data Mediation SUPER technology Pro: Killer feature on the conceptual level Con: Requires too much modelling efforts <s:mediate inputVariable=quot;xquot; outputVariable=quot;yquot; mediatorIRI=quot;urn:anyquot;? /> © Tammo van Lessen 5

What is JavaScript/E4X? JavaScript ECMA 262, Edition 3 JavaScript 1.6 E4X Proposed by BEA ECMA 357 XML support at the language level Literals, nodes, attributes, namespaces… XPath‐like syntax foreach… Allows nodesets as LHS expressions var items = <items> <item name=quot;SOA bookquot; price=quot;40quot; quantity=quot;2quot;/> <item name=quot;BPM bookquot; price=quot;35quot; quantity=quot;3quot;/> <item name=quot;EAI bookquot; price=quot;30quot; quantity=quot;1quot;/> </items>; alert( items.item.(@name == quot;SOA bookquot;).@quantity ); for each( var thisPrice in items..@price ) { sum += thisPrice; } 6 © Tammo van Lessen

Using Javascript/E4X in BPEL <assign> <assign name=quot;e4x-assignquot;> <extensionAssignOperation> <js:snippet> myVar.TestPart += ' World'; </js:snippet> </extensionAssignOperation> </assign> <assign name=quot;e4x-array-assignquot;> <extensionAssignOperation> <js:snippet> load('shoppingCartUtils.js'); shoppingCart.parameters = createShoppingCartSkeleton(); shoppingCart.parameters.items += createCartItem(item); shoppingCart.parameters.items.item.(@hyped=='true').price *= 2; </js:snippet> </extensionAssignOperation> </assign> BPEL variables are injected into JS context Variables can be read and written 7 © Tammo van Lessen

Using Javascript/E4X in BPEL <extensionActivities> <extensionActivity name=“adjustShippingDetailsquot;> <js:snippet> if (goldRatio > 1.0 || silverRatio > 1.0) { throwFault('urn:myprocess', 'IllegalArgumentFault', 'discount ratios must be <= 1.0'); } if (customer.type == 'gold') { po.items.item.price *= goldRatio; } else if (customer.type == 'silver') { po.items.item.price *= silverRatio; } else if (customer.type == 'besteffort') { po.shippingMode = 'snailmail'; } </js:snippet> </extensionActivity> JavaScript functions can be used to reuse such  snippets Use with caution! 8 © Tammo van Lessen

Built‐in Functions load(…) Loads custom JS/E4X library print(…) Prints debug output to console piid() Returns process instance ID activityName() Returns activity name processName() Returns the process’ QName throwFault(namespace, localpart, faultmsg) throwFault(xmlobject) Throws a BPEL fault validate(…) Validates a variable’s content against its schema 9 © Tammo van Lessen

Conclusions Variable Assignments in vanilla BPEL are cumbersome Adding items to lists is not possible Would require a nodeset as LHS expression Can be done using external XSL scripts Batch‐updating an XPath match is not possible Variable initialization is very verbose No reuse possible for recurring data manipulation tasks. Using E4X in BPEL Provides a convenient syntax for rich XML manipulation Reuse of such scripts across activities and processes is possible Simplifies array manipulation Implementation available Publicly available in Apache ODE Will be part of the upcoming 2.0 release 10 © Tammo van Lessen

End of Document

Add a comment

Related presentations

Presentación que realice en el Evento Nacional de Gobierno Abierto, realizado los ...

In this presentation we will describe our experience developing with a highly dyna...

Presentation to the LITA Forum 7th November 2014 Albuquerque, NM

Un recorrido por los cambios que nos generará el wearabletech en el futuro

Um paralelo entre as novidades & mercado em Wearable Computing e Tecnologias Assis...

Microsoft finally joins the smartwatch and fitness tracker game by introducing the...

Related pages

Facilitating Rich Data Manipulation in BPEL using E4X)

Facilitating Rich Data Manipulation in BPEL using E4X Tammo van Lessen, Jorg Nitzsche, and Dimka Karastoyanova¨ Institute of Architecture of Application ...
Read more

Facilitating rich data manipulation in BPEL using E4X (PDF ...

The Business Process Execution Language (BPEL) uses XML to specify the data used within a process and realizes data flow via (globally) shared variables ...
Read more

CiteSeerX — Facilitating Rich Data Manipulation in BPEL ...

Facilitating Rich Data Manipulation in BPEL using E4X . Cached. Download Links ... {Facilitating Rich Data Manipulation in BPEL using E4X}, year = {}} ...
Read more

Ontology Based Data Mediation in BPEL (for Semantic Web ...

Facilitating rich data manipulation in BPEL ... BPEL enabling data manipulation based on ontological knowledge. Using the semantics of data used ...
Read more

IAAS | Institut | Ehemalige Mitarbeiter | Nietzsche

Nitzsche , Jörg ... Message Exchange Patterns using BPEL light ... Jörg; Karastoyanova, Dimka: Facilitating Rich Data Manipulation in BPEL using ...
Read more

DBLP: Jörg Nitzsche - RWTH Aachen University

... , Dimka Karastoyanova: Facilitating rich data manipulation in BPEL using E4X ... Extending BPEL light for Expressing ... Exchange Patterns using BPEL ...
Read more

Rich Data | LinkedIn

Rich Miller CEO and Managing ... Consultant at Rich Data Solutions, Inc., ... Facilitating Rich Data Manipulation in BPEL using E4X. 1,310 Views ...
Read more

Ontology-Based Data Mediation in BPEL (For Semantic Web ...

Semantic Scholar extracted view of "Ontology-Based Data Mediation in BPEL ... rich data manipulation in BPEL using E4X. ... of our Collaborators using ...
Read more

Search results for "Jörg Nitzsche" – FacetedDBLP

Interaction Choreography Models in BPEL: Choreographies on the Enterprise Service Bus. S-BPM ONE : 2010: ... Composing services on the grid using BPEL4SWS.
Read more