Скачать презентацию Service-Oriented Architectures Instructor Dr Hany H Ammar Dept Скачать презентацию Service-Oriented Architectures Instructor Dr Hany H Ammar Dept

0b9c92e196ddb88e1493e937c38481a2.ppt

  • Количество слайдов: 85

Service-Oriented Architectures Instructor: Dr. Hany H. Ammar Dept. of Computer Science and Electrical Engineering, Service-Oriented Architectures Instructor: Dr. Hany H. Ammar Dept. of Computer Science and Electrical Engineering, WVU

outline n What is SOA. – – n Service-Oriented Architecture (SOA) Style – – outline n What is SOA. – – n Service-Oriented Architecture (SOA) Style – – n Perspective, Evolution, SOA v/s Traditional Architecture Key Concepts Differences between SOA and UDDI (UDDI vs SOA) Elements of SOA, SOA ERD Model What is a service, service characteristics, service interface, and service types The Enterprise Service Bus ESB Business Processes Management

What is SOA? A Business Perspective n SOA is the application of well-founded concepts What is SOA? A Business Perspective n SOA is the application of well-founded concepts which exploit the modern ability for system resources to – n n Collaborate independent of location n Across Heterogeneous technologies A set of architectural principles backed by technology to tap into system resources to freely participate in a larger community Provide tools and techniques to orchestrate the reuse of these newly available resources into processes that drive the business.

What is SOA? A Technical Perspective n n A Service Oriented Architecture is a What is SOA? A Technical Perspective n n A Service Oriented Architecture is a collection of self-contained services that can communicate with each other. Key characteristics of services: ü loosely coupled ü coarse grained ü typically published & available for invocation on a Service Bus • Defining services at a “business level” enables rapid composition of end-to-end business processes, delivering on the promise of greater IT flexibility and agility

The Evolution… From Three-Tier Applications Presentation Layer Databases Application Business Layer The Evolution… From Three-Tier Applications Presentation Layer Databases Application Business Layer

The Evolution to: SOA-Based Applications Process #1 Presentation Process #2 Process #3 Service Components The Evolution to: SOA-Based Applications Process #1 Presentation Process #2 Process #3 Service Components Databases

SOA v/s Traditional Architecture Calls for a Paradigm Shift Traditional Architecture Service Oriented Architecture SOA v/s Traditional Architecture Calls for a Paradigm Shift Traditional Architecture Service Oriented Architecture Functionality Driven Process Oriented Designed to last Designed for change Long development cycles Iterative development Tightly Coupled Loosely Coupled Application Specific Heterogeneous Data Oriented Business Service Oriented But must be built on standards to enhance interoperability

Service-Oriented Architecture: Key Concepts Service A unit of business functionality that can be invoked Service-Oriented Architecture: Key Concepts Service A unit of business functionality that can be invoked over the network Web service A service that is called in a standard way, so anyone can use it without knowing its internals “Loosely coupled” When services are self-contained, and can be easily combined and disassembled, they are called loosely coupled. Service. Oriented Architecture Orchestration A standards-based platform that lets you model, develop, find, and combine services into flexible business processes Combining and assembling services into a coherent business process – also known as business process management

Differences between SOA and UDDI vs SOA n What is UDDI? Ø Ø Ø Differences between SOA and UDDI vs SOA n What is UDDI? Ø Ø Ø UDDI is a platform-independent framework for describing services, discovering businesses, and integrating business services by using the Internet. UDDI stands for Universal Description, Discovery and Integration UDDI is a directory for storing information about web services UDDI is a directory of web service interfaces described by WSDL (Web Services Description Language) UDDI communicates via SOAP (Simple Object Access Protocol, ) UDDI is built into the Microsoft. NET platform

UDDI vs SOA n n n What is UDDI Based On? UDDI uses World UDDI vs SOA n n n What is UDDI Based On? UDDI uses World Wide Web Consortium (W 3 C) and Internet Engineering Task Force (IETF) Internet standards such as XML, HTTP, and DNS protocols. UDDI uses WSDL to describe interfaces to web services Web Services Description Language (WSDL) is an XML grammar that defines the functionality offered by a Web service and the format of messages sent and received by a Web service. Additionally, cross platform programming features are addressed by adopting SOAP, known as XML Protocol messaging specifications found at the W 3 C Web site.

UDDI vs SOA: UDDI Architecture UDDI registry look for service in UDDI registry requester UDDI vs SOA: UDDI Architecture UDDI registry look for service in UDDI registry requester retrieve provider location and WSDL service description bind and send request via SOAP/http or other transport to provider Another View publish services in registry provider create request from WSDL description It was assumed that fully automated agents (request entities) could perform lookups and use services thereby executing business tasks.

UDDI vs SOA: Why UDDI Could Not Work n n n central registries of UDDI vs SOA: Why UDDI Could Not Work n n n central registries of service descriptions independent automatic agents searching for services machines understanding service descriptions machines deciding on service use machines being able to use a service properly machines being able to construct advanced workflows (i. e. , bussiness processes) from different services Even if you replace machines with human beings (e. g. for the service decision) UDDI does not work: Too much in services is ambiguous, undefined or expressed in different and incompatible terms – not to forget that the service interface use (order of calls, meaning of datatypes etc. ) is undefined as well.

WS Stack based on UDDI Service Discovery UDDI Service Publication WSDL SOAP HTTP, FTP, WS Stack based on UDDI Service Discovery UDDI Service Publication WSDL SOAP HTTP, FTP, MQ Email, IIOP 3/15/2018 Service Description Quality of Service UDDI Management Service Flow Security WSFL XML-based Messaging Network 13

UDDI vs SOA: Missing Technology Behind UDDI Meaning of data types and interfaces Ontologies UDDI vs SOA: Missing Technology Behind UDDI Meaning of data types and interfaces Ontologies policies Autonomous Agent Meaning of actions create request from WSDL description Business Domain knowledge Trust Establishment Risk Understanding and matching of constraints Business Process Exectution Languages Understanding Flows and Goals Important to remember: business languages which standardize business terms like contract, sale, customer etc. Generally speaking a ton of meta-data where missing. Webservices (WSDL, SOAP) merely covered the mechanics of message exchange.

Elements of SOA n n n Services offer high-level, business type interfaces Service Choreography Elements of SOA n n n Services offer high-level, business type interfaces Service Choreography (aka workflow) is performed outside services which allows the combination of services into larger business processes A set of semantic standards and technologies allows agents to understand services and their interfaces (OWL, SAML, Semantic Web etc. ) Legacy applications will be wrapped through a service interface and become available to other companies SOA will use Web Service technology as its base

SOA Elements Model This diagram from „Web Services Architecture“ shows internal and external elements SOA Elements Model This diagram from „Web Services Architecture“ shows internal and external elements of the SOA architecture. Action e. g. is not an externally visible element. Note the important roles of „policy“ and „semantics“

Another Simplified Model Adheres to governed by Policy Binds to Exposes End Point Serves Another Simplified Model Adheres to governed by Policy Binds to Exposes End Point Serves Understands Service Consumer implements Contracts describes Service Key Sends/Receives Messages Component Relation

outline n What is SOA. – – n Service-Oriented Architecture (SOA) Style – – outline n What is SOA. – – n Service-Oriented Architecture (SOA) Style – – n Perspective, Evolution, SOA v/s Traditional Architecture Key Concepts UDDI vs SOA Elements of SOA, SOA ERD Model What is a service, service characteristics, service interface, and service types The Enterprise Service Bus ESB Business Processes Management

Service Oriented Architecture (SOA) Style: An Architecture Style Service-Oriented Architecture (SOA) is an architectural Service Oriented Architecture (SOA) Style: An Architecture Style Service-Oriented Architecture (SOA) is an architectural style. n Applications built using the SOA style deliver functionality as services that can be used or reused when building applications n SOA uses open standards to integrate software assets as services n It provides a standard form of interactions of services n

A Map of SOA Components Registry and Repository Manage and monitor Security Web Portals A Map of SOA Components Registry and Repository Manage and monitor Security Web Portals Human Business Process Management (BPM) Enterprise Service Bus (ESB) Data Services Process Services Business Logic Orchestration System BPM Databases Systems of Record

Banking Examples of SOA Registry and Repository: Find Stop Payment Service, Charge Fee service Banking Examples of SOA Registry and Repository: Find Stop Payment Service, Charge Fee service Manage and monitor Security: Authenticate user Internet Banking Business Process: Stop Payment ESB: Routes to appropriate core system Data Services Process Services Business Logic: If Customer_Status = Gold Service_Fee = $8 else Service_Fee = $20 Fee database DDA / Current Account Orchestration:

Place customer orders: 1. Basic Data Service – access operations, 2. Composed Services - Place customer orders: 1. Basic Data Service – access operations, 2. Composed Services - business logic, 3. Process Services – complex business logic

A Unified Patience Journal System A Unified Patience Journal System

Service Oriented Architecture (SOA) Style: SOA services become the building blocks that form business Service Oriented Architecture (SOA) Style: SOA services become the building blocks that form business flows n Services can be reused by other applications n What is a service? n – A service provides a discrete business function that operates on data. Its job is to ensure that the business functionality is applied consistently, returns predictable results, and operates within the quality of service required.

Service Oriented Architecture (SOA) Style: n What is a service? ØA service is a Service Oriented Architecture (SOA) Style: n What is a service? ØA service is a reusable component that can be used as a building block to form larger, more complex business-application functionality. Ø A service may be as simple as “get me some person data, ” or as complex as “process a disbursement. ”

Service Oriented Architecture (SOA) Style: n Characteristics of a Service Ø Ø Supports open Service Oriented Architecture (SOA) Style: n Characteristics of a Service Ø Ø Supports open standards for integration: Although proprietary integration mechanisms may be offered by the SOA infrastructure, SOA’s should be based on open standards. Open standards ensure the broadest integration compatibility opportunities Loose coupling: provides well defined interfaces to clients Stateless: The service does not maintain state between invocations. If a transaction is involved, the transaction is committed and the data is saved to the database.

Service Oriented Architecture (SOA) Style: n Characteristics of a Service Ø Location agnostic: Users Service Oriented Architecture (SOA) Style: n Characteristics of a Service Ø Location agnostic: Users of the service do not need to worry about the implementation details for accessing the service. The SOA infrastructure will provide standardized access mechanisms with service-level agreements.

SOA Design Business Object Component Service Business Service Choreography Business Object Component Service This SOA Design Business Object Component Service Business Service Choreography Business Object Component Service This diagram is modelled after O. Zimmermann et. al. „Elements of a Service. Oriented Analysis and Design“. The paper also shows nicely how flow oriented a SOA really is and that a class diagram does not catch the essence of SOA. A statediagram performs much better. The authors also note that SOA is process and not use-case driven design.

Interface Design Ø Object interface: accepts transactions, fast, Object references Ø Component interface: value Interface Design Ø Object interface: accepts transactions, fast, Object references Ø Component interface: value objects, relatively fast. Mostly stateless. Ø Service interface: long running transactions with state in DB. Composable to larger services (choreography) or composed of smaller services (orchestration). Stateless. Only objects (classes) are programming language constructs. But a detailed look at the interfaces reveals that component and service type interfaces are just different types of the interface model.

SOA Blueprint Service Types n n n n Basic Service: atomic operation on a SOA Blueprint Service Types n n n n Basic Service: atomic operation on a simple object (e. g. DBaccess) Composite Service: atomic, uses several basic services (orchestration), stateless for caller. Workflow Service: Stateful, defined state changes (state kept in persistent store) Data Service: Information integration via message based request/response mechanism. Pub/Sub Service: typical event service with callbacks and registration. Service Broker: Intermediate, rule based message manipulation and forwarding Compensation Service: revert actions (not rollback like)

Service Oriented Architecture (SOA) Style: Makes use of an Enterprise Service Bus ESB Used Service Oriented Architecture (SOA) Style: Makes use of an Enterprise Service Bus ESB Used in web-based systems and distributed computing The SOA Style Before SOA nodes make resources available to other participants in the system as independent services that the participants access in a standardized way using the ESB

Legacy Integration Legacy Integration

SOA Integration SOA Integration

Service Oriented Architecture (SOA) Style: The Enterprise Service Bus ESB n n An enterprise Service Oriented Architecture (SOA) Style: The Enterprise Service Bus ESB n n An enterprise service bus is an infrastructure used for building compound applications Similar to the Software Bus in a CORBA based distributed application architecture The enterprise service bus is the glue that holds the compound application together The enterprise service bus is an emerging style for integrating enterprise applications in an implementationindependent fashion An enterprise service bus can be thought of as an abstraction layer on top of an Enterprise Messaging System

Service Oriented Architecture (SOA) Style: The Enterprise Service Bus ESB n Characteristics of an Service Oriented Architecture (SOA) Style: The Enterprise Service Bus ESB n Characteristics of an ESB – – – – Streamlines development Supports multiple binding strategies Performs data transformation Intelligent routing Real time monitoring Exception handling Service security

Service Oriented Architecture (SOA) Style: The Enterprise Service Bus ESB Functions Ø Invocation Ø Service Oriented Architecture (SOA) Style: The Enterprise Service Bus ESB Functions Ø Invocation Ø Synchronous and asynchronous transport protocols, service mapping (locating and binding) Ø Routing Ø Addressability, static/deterministic routing, content-based routing, policy-based routing Ø Mediation Ø Adapters, protocol transformation, service mapping Ø Message processing, message transformation and message enhancement

The ESB Boundaries The ESB (in its simplest form) is responsible for getting a The ESB Boundaries The ESB (in its simplest form) is responsible for getting a message from point A to point B.

Get the Message on the Bus A binding component “speaks” the service’s protocol, which Get the Message on the Bus A binding component “speaks” the service’s protocol, which happens to be SOAP over JMS.

Perform the Person Read The request is now routed to the Get Person Data Perform the Person Read The request is now routed to the Get Person Data Service, which will perform the business logic.

Do the SSIM Lookup A call is made to the SSIM service to perform Do the SSIM Lookup A call is made to the SSIM service to perform a lookup of the Student Identifier (SID). The SSIM service lives inside the bus. Note: The SSIM binding components are not shown so the diagram can remain simple.

Return the Person Data The process is reversed, returning the response to the requester. Return the Person Data The process is reversed, returning the response to the requester.

Defining the Message n n Web Services Description Language Open Standard for describing Interfaces Defining the Message n n Web Services Description Language Open Standard for describing Interfaces to Services (http: //www. w 3. org/TR/wsdl) Characteristics – Describes data expected to be sent and received – Describes what the service can do – Describes how to reach the service WSDL description is an XML document

Message-Exchange Patterns One-way. The endpoint receives a message. n Request-response. The endpoint receives a Message-Exchange Patterns One-way. The endpoint receives a message. n Request-response. The endpoint receives a message, and sends a correlated message. n Solicit-response. The endpoint sends a message, and receives a correlated message. n Notification. The endpoint sends a message. n

The Ingredients The XSD is the XML schema definition For variables` The Ingredients The XSD is the XML schema definition For variables`

outline n What is SOA. – – n Service-Oriented Architecture (SOA) Style – – outline n What is SOA. – – n Service-Oriented Architecture (SOA) Style – – n What is a service, service characteristics, service interface, and service types The Enterprise Service Bus ESB Business Processes Management – n Perspective, Evolution, SOA v/s Traditional Architecture Key Concepts Differences between SOA and UDDI (UDDI vs SOA) Elements of SOA, SOA ERD Model Business Processes Flow, Business Process Execution Language (BPEL), BPELJ, JBoss j. BPM, j. PDL The IBM Rational Software Development Platform

Business Processes Ø Ø Business processes are a set of activities, supported by services, Business Processes Ø Ø Business processes are a set of activities, supported by services, that support a particular business activity. Business processes are business services built using other business services. Business Process Execution Language (BPEL) is a specification for describing business processes in a portable XML format. BPEL is widely supported in both commercial and open source products. BPEL defines how services interact to form complex business process. It provides a unit of work context, fault handling, and compensation (transaction rollback).

Legacy Business Process Legacy Business Process

Example of a Business Process Example of a Business Process

The Shipping Workflow The Shipping Workflow

Grouping services Grouping services

SOA Business Process ESB: Search ESB: Stored Information SOA Business Process ESB: Search ESB: Stored Information

Business Processes span Organization and System Boundaries From Sequential and Divisional/Functional Division To Parallel Business Processes span Organization and System Boundaries From Sequential and Divisional/Functional Division To Parallel and Collaborative Customer Order Entry Customer Division Shared Service Supplier Outsourced Invoicing & Receivables Marketing Vendor Managed Inventory Shipping (UPS) Collections Need a flexible IT Infrastructure and Architecture

Business Process Management • What is a business process? • A business process is Business Process Management • What is a business process? • A business process is a set of coordinated tasks and activities, conducted by both people and equipment, that will lead to accomplishing a specific goal • Business process management (BPM) is a systematic approach to improving an organization's business processes

Business Process Management • BPM is a structured approach that models an enterprise's human Business Process Management • BPM is a structured approach that models an enterprise's human and machine tasks and the interactions between them as processes • Evolving from document management, workflow and enterprise application integration (EAI), a BPM system can monitor and analyze tasks

Business Process Modeling Notation • A standardized graphical notation for drawing business processes in Business Process Modeling Notation • A standardized graphical notation for drawing business processes in a workflow • Flow objects: • Event • Activity • Gateway • Connecting objects

Example: Business process 1 Example: Business process 1

Example: Business process 2 Example: Business process 2

BPEL • Business Process Execution Language BPEL is a business process modelling language that BPEL • Business Process Execution Language BPEL is a business process modelling language that is executable • BPEL is a language for specifying business process behavior based on Web Services • BPEL is serialized in XML and aims to enable programming in the large

What BPEL does … n n n BPEL binds services together to form larger What BPEL does … n n n BPEL binds services together to form larger complex business services Control Flow (branch, loop, parallel) Asynchronous correlation Transaction support, Units of Work Compensation

WS-BPEL: a brief introduction to some Language Constructs, WS-BPEL: a brief introduction to some Language Constructs,

WS-BPEL WS-BPEL

WS-BPEL WS-BPEL

WS-BPEL WS-BPEL

WS-BPEL WS-BPEL

WS-BPEL WS-BPEL

BPEL example: Withdrawing and depositing services of the banking system logic BPEL example: Withdrawing and depositing services of the banking system logic

BPEL and SOA Sample ESB • Custom Services • Transformation Services • Orchestration • BPEL and SOA Sample ESB • Custom Services • Transformation Services • Orchestration • Routing • Application Server

BPEL Reference Presentations OASIS BPEL Web page http: //www. oasis-open. org/committees/wsbpel/ • Technical overview BPEL Reference Presentations OASIS BPEL Web page http: //www. oasis-open. org/committees/wsbpel/ • Technical overview part 1 • Technical overview part 2 • Technical overview part 3

BPELJ • BPELJ is a combination of BPEL and Java allowing the two languages BPELJ • BPELJ is a combination of BPEL and Java allowing the two languages to be used together to build business process applications • BPEL programming in the large the logic of business processes • It is assumed that BPEL will be combined with other languages which are used to implement business functions (programming in the small) Java (J 2 EE)

BPELJ • BPELJ enables Java and BPEL to cooperate by allowing sections of Java BPELJ • BPELJ enables Java and BPEL to cooperate by allowing sections of Java code, called Java snippets, to be included in BPEL process definitions • BPELJ Web page: http: //www. ibm. com/developerworks/library/specifica tion/ws-bpelj/

j. BPM • JBoss j. BPM is a framework that delivers workflow, business process j. BPM • JBoss j. BPM is a framework that delivers workflow, business process management (BPM), and process orchestration • Enables enterprises to create and automate business processes that coordinate between people, applications, and services • Provides the tools and process execution engine to integrate services deployed in a SOA and automate workflows

j. BPM vision for BPM j. BPM vision for BPM

j. BPM components • The core workflow and BPM functionality is packaged as a j. BPM components • The core workflow and BPM functionality is packaged as a simple java library

Example: http: //it. toolbox. com/blogs/the-soa-blog/soa-diagram-16952 Example: http: //it. toolbox. com/blogs/the-soa-blog/soa-diagram-16952

j. BPM process language - j. PDL • j. PDL is a graph based j. BPM process language - j. PDL • j. PDL is a graph based process language that is build on top of common j. BPM framework

Overview of the j. PDL components http: //docs. jboss. com/jbpm/v 3. 2/userguide/html/introduction. html Overview of the j. PDL components http: //docs. jboss. com/jbpm/v 3. 2/userguide/html/introduction. html

The j. PDL graphical process designer j. PDL includes a graphical designer tool for The j. PDL graphical process designer j. PDL includes a graphical designer tool for authoring business processes. It's an eclipse plug-in. n It includes support for both the business analyst as well as the technical developer n Enables a smooth transition from business process modeling to the practical implementation. n

j. PDL vs BPEL n n Clients of a j. PDL definition are expected j. PDL vs BPEL n n Clients of a j. PDL definition are expected to start or resume process instances through the j. BPM API. Methods such as Process. Definition. create. Process. Instance and Token. signal allow client code to interact directly with an executing process. BPEL takes a different approach. Instead of defining its own APIs, it accommodates custom web service interfaces with which clients interact. These interfaces describe meaningful business operations and hide the fact that clients are actually "talking" to an orchestrator

j. PDL vs BPEL j. PDL specifies the execution flow of a process in j. PDL vs BPEL j. PDL specifies the execution flow of a process in terms of a directed graph of nodes. It includes a set of node types that intend to cover most routing scenarios, and allows extensions to includ custom routing logic n BPEL has a fixed set of structured activities represented by XML elements, nested together to model a particular execution path (such as, sequence, while, etc. ) n

BPEL support • j. BPM design and pluggable architecture makes it possible to support BPEL support • j. BPM design and pluggable architecture makes it possible to support different languages that can be shown as a graph and represent some sort of execution • j. BPM provides BPEL support: • JBoss j. BPM BPEL Extension, version 1. 1. Beta 3 • Download • http: //prdownloads. sourceforge. net/jbpm-bpel 1. 1. Beta 3. zip? download • Documentation • http: //docs. jboss. com/jbpm/bpel/

XPDL n n n The XML Process Definition Language (XPDL) is a format standardized XPDL n n n The XML Process Definition Language (XPDL) is a format standardized by the Workflow Management Coalition (Wf. MC) to interchange Business Process definitions between different workflow products, i. e. between different modeling tools and management suites. Defines an XML schema for specifying the declarative part of workflow / business process. Designed to exchange the process definition, both the graphics and the semantics of a workflow business process.

XPDL n n n XPDL is currently the best file format for exchange of XPDL n n n XPDL is currently the best file format for exchange of BPMN diagrams; In April 2008, the Wf. MC ratified XPDL 2. 1 as the fourth revision of this specification. XPDL 2. 1 includes extension to handle new BPMN 1. 1 constructs, as well as clarification of conformance criteria for implementations. In contrast, BPEL focuses exclusively on the executable aspects of the process, and does not contain elements to represent the graphical aspects of a process diagram, or human oriented processes.

References • ESB Best Practices Presentation http: //www. fiorano. com/whitepapers/ESB_Best_Practice s. htm • j. References • ESB Best Practices Presentation http: //www. fiorano. com/whitepapers/ESB_Best_Practice s. htm • j. BPM Documentation Library http: //labs. jboss. com/jbossjbpm/docs/index. html • j. BPM Presentations http: //wiki. jboss. org/wiki/Wiki. jsp? page=Jbpm. Presentations • XPDL http: //www. wfmc. org/xpdl. html

outline n What is SOA. – – n Service-Oriented Architecture (SOA) Style – – outline n What is SOA. – – n Service-Oriented Architecture (SOA) Style – – n n Perspective, Evolution, SOA v/s Traditional Architecture Key Concepts Differences between SOA and UDDI (UDDI vs SOA) Elements of SOA, SOA ERD Model What is a service, service characteristics, service interface, and service types The Enterprise Service Bus ESB Business Processes Management Conclusions

Conclusions This lectures introduced the concepts of SOA n We also discussed issues related Conclusions This lectures introduced the concepts of SOA n We also discussed issues related to SOA as an architecture style n We also discussed concepts of Business Process Management and supporting technologies n