3. Composition: Example
2
Why do we need composition?
•In SOA bigger parts are brokendown into smaller parts.
•How to re-assemble these parts?
Example:
•Student’s subscription to a school
•Thestudent access the student’s platform and populates his name, adress, etc
•The student pays the subscription fees.
•The Student is assigned a subscription Identifier.
•Student’s subscription to a student’s accomodation
•Subscription using his student Identifier
•Select the accomodation
•Paiement of the accomodation’s fees
•Assigning an Identifier in the accomodation
4. 3
Composition: Example
• Student’s subscription to the Bus andTrain
• Select the Bus orTrain line.
• Apply fees discount
• Paiment
• Assigning an Identifier
5. 4
Composition: Solution
• Solution 1:
• The student accedes each plateform and populates the same data each
time to susbcribe.
• Solution 2:
• Students accede a single platform (the student’s platform)
• Each Platform exposes its functionalities
• The student’s plateform composes the School, Accomodation and
Transport services.
• Behind the scenes, the services process the subscription and generate
student’s identifiers and prints the student’s cards
6. Composition: Definition
5
• Implementation of an application (offered as a service) whose logic involves
the invocation of operations offered by other services.
• The new service is called composite service.
• The services invoked are service components.
• From the customer's point of view, a composite service and a basic service
(implemented by a traditional programming language) are
indistinguishable.
• Meaning of Service Mashup: A Mashup, in web development, is a web page,
or web application, that uses content from more than one source to create
a single new service displayed in a single graphical interface
7. 6
Orchestration: Introduction
◦ The most common approach
◦ The step sequence is defined in a process, with conditions and exceptions
◦ A central controller is then created to implement the sequence
◦ The individual steps of a sequence are implemented by operations on
services
◦ For simple service compositions, the orchestration is done in the code (Java,
C # ...) residing in the composite
◦ For complex orchestrations, a tool is used to:
◦ Create a visual model of a sequence
◦ Generate code that executes this sequence in a dedicated runtime
environment
◦ Business Process Model (BPM) approach
8. 7
Orchestration: Standards
BPMN (Business Process Modeling Notation)
◦ Successor of BPML (Business Process Modeling Langage)
◦ Defined using a visual representation of the séquence
BPEL (Business Process Execution Language) ou BPEL4WS (BPEL for
Web Services)
◦ The code that executes the sequence
◦ Uses XML
◦ Uses WSDL:
◦ Interact with the resources required by the process
◦ Describe the BPEL process itself
◦ Defines two types of activities:
◦ Base Activity: Interacts with external processes (invoke, receive,
reply)
◦ Structured Activities : Controls internal processes flow (sequencial
flow, condition, loops…)
9. 8
Orchestration: Summary
◦ Defines a single master controlling all aspects of the process
◦ Supports a graphical view of the runtime
◦ Easily coupling with SOA
◦ Provides a good starting point, but a difficult scaling-up for
complex processes
◦ Supported by most tools