• Have any questions?
  • info.zbook.org@gmail.com

Service ModellingService Modelling With SoaML

7m ago
26 Views
0 Downloads
1.23 MB
76 Pages
Last View : 21d ago
Last Download : n/a
Upload by : Roy Essex
Share:
Transcription

Service-oriented Heterogeneous Architecture and Platforms EngineeringService Modellingwith SoaMLBrian Elvesæter, SINTEF ICTbrian.elvesater@sintef.no

Tutorial outline PART I:I IntroductionI t d ti– SoaML language– UML modelling tool: Modelio– Case study:y Travel Agencygy PART II: Hands-on– Business process modelling (BPMN)– BusinessB iarchitecturehit tmodellingd lli (S(SoaML)ML)– System architecture modelling (SoaML)SoaML Tutorial, Software 20112

Online material SoaML specification– http://sisas.modelbased.net/ 20Oslo.zipSoaML Tutorial, Software 2011 en.sourceforge.net/SoaML Engine modulemod le downloaddo nloadhttp://rd.softeam.com/demos/soamlT t i l modelTutoriald l downloaddl d (updated)( d t .htmlSoaML modules for Modelio (open source)––SHAPE hands-on tutorial given at ECMFA 2010(extra material)– downloadeu/downloadarea/SHAPEMethodology OnlineLibrary oad/downloahttp://wwwmodeliosoft com/en/download/downloads.htmlModelio Free Edition 1.2.1–SiSaS Methodology (in progress)– http://www.modeliosoft.comModelio Enterprise Edition 1.2.1 (10 dayevaluation)–SHAPE Methodology– ape-project.eu/Modelio Modelling Tools–SHAPE project website:– http://www.omg.org/spec/SoaML/SoaML wiki– SoaMLEngines/1.0.00/SoaMLEngines%5Bbin%5D 1.0.00.zip/downloadSoaML Designer module n%5D 1.0.00.zip/download3

SoaML languageg gSoaML Tutorial, Software 20114

What is SoaML? Service oriented architecture ModelingLanguage (SoaML)– Extensions to UML2 to support service concepts.– Focuses on basic service modelling concepts.– A foundation for further extensions andi tintegrationti withith BPMN,BPMN BMM andd otherthmetamodels.SoaML Tutorial, Software 20115

SoaML – Concepts Agent Participant Attachment Port CCapabilitybilit PPropertyt Consumer Provider C ll b tiCollaboration RRequestt CollaborationUse ServiceChannel Expose ServiceContract MessageType ServiceInterface Milestone Service ServicesArchitectureSoaML Tutorial, Software 20116

Marketplace ServicesExampleAcme IndustriesMechanics Are UsManufacturerConsuumerD nsumerSoaML Tutorial, Software hereGtItThFreight ShipperShip ReqShippedDelivered7

Business process overview: DealerPlace order: OrderHandlerr:O rderReceive orderReceive order confirmationReceive shipping confirmation:O rderC onfirmation:ShipmentStatusC onfirm order[no]Forward shipping confirmationReceive delivery confirmation: ShipperInvoice customerEnd event[yes]Inventory low?: ProductionsShip orderOrder productionReceive shipping confirmationInitiate production: Invoicing: Manuf actuurerEnd eventStart eventSend invoice:ShippingReques t:ShipmentStatusShi itemShipitSend shipping confirmationSoaML Tutorial, Software 2011:D eliveryC onfirmationSend delivery confirmationEnd event8

Services architecture(Community-level) ServicesArchitecture Dealer NetDealeNetworko k ArchitectureA chitect ePlPlaceOOrderd serviceiconsumerorde r:Place O rde rde a le r:De a le rprovidera cm e :Ma nufacture rconsumerShip StatusserviceCommunity-levelservices architecturefor the Dealer Networkconsumerstatus:Ship Sta tusprovidership:Shipping R e que stshippe r:Shippe rproviderShippingRequestserviceServices architecture: High level description of how participants work together for a purpose byprovidingpg and usingg services expressedpas service contracts. UML collaboration stereotyped «ServicesArchitecture».SoaML Tutorial, Software 20119

ServicesArchitecture Dealer Network Architectureconsumerorded r:PlaPl ce O rded rde a le r:De a le racm e :Manufacture rconsumersta tus:Ship ntspand servicecontractsproviderpshippe r:Shippe rconsumership:Shipping R e que stprovider ServiceC ontract Place Orderconsum e r:O rde rPla ce rrolebindingpro vide r:O rde rTak e rService contract: Service specifications that definethe roles each participant plays inthe service and the interfacesthey implement to play that rolerole. UML collaboration stereotyped«ServiceContract».SoaML Tutorial, Software 2011ttype Participant ManufacturerParticipant:p Represent logical or real people ororganizational units thatparticipate in servicesarchitectures and/or businessprocesses. UML class stereotyped«Participant».10

Services nformationInvoicingShippedProductionsShip ReqShipped ServicesArchitecture Manufacturer Architecturei:Invoicingde ale r:De ale rproviderconsumerDeliveredorde r:Pla ce O rderconsumerprovideric:Invoice C ustom eroh:O rderHa ndle rParticipant-levelservices architecturefor the Manufacturerconsumership:Shipping R e que stprovidershipper:ShipperSoaML Tutorial, Software 2011consumerpo:P roduction O rderproviderp:Productions11

ServicesArchitecture Dealer Network Architectureconsumerorded r:PlaPl ce O rded rde a le r:De a le rproviderpCommunity andparticipantarchitecturesacm e :Manufacture rconsumerconsumersta tus:Ship Statusprovidership:Shipping R e que stshippe r:Shippe rprovider ServicesArchitecture Manufacturer ArchitectureCommunity-levelservices architecturef theforth DealerD l NNetworktki:Invoicingde a le r:De a le rproviderconsumerorde r:Pla ce O rde rconsumerprovideric:Invoice C ustom eroh:O rde rHandle rParticipant-levelservices architecturefor the Manufacturerconsumership:Shipping R e que stprovidershippe r:Shippe rSoaML Tutorial, Software 2011consumerpo:Production O rde rproviderp:Productions12

Service contract: Place order(Structure)Consumerrole withinservicecontractServicechannel ServiceC ontract Place Orderconsum e r:O rde rPla ce r interface, Consumer OrderPlacerquote ()orde rC onfirm ation() typetypeConsumerinterface provide r:O rde rTa k e r interface, Provider OrderTakerProviderrole withinservicecontractProviderinterfacequote R e que st()orde r()The service contract representspan agreementgbetween the involvedparticipants for how the service is to be provided and consumed.The agreement includes the interfaces, choreography and any otherterms and conditions.SoaML Tutorial, Software 201113

Service interface: Place order(Structure)ConjugateCjtservice interface interface, Consumer OrderPlacer ServiceInterface PlaceOrderInterface use use quote ()orde rC onfirm a tion() interface, Provider OrderTakerServiceinterface ServiceInterface PlaceOrderInterfacequote R e que st()orde r()Service interface: Refines the service contract. Defines the provided and required interfaces for a service. A service interface is the type of a service port on a participant orcomponent.– UML class stereotyped «ServiceInterface». A conjugate service interface is the type of a request port on aparticipant or component.– UML class stereotypedyp «ServiceInterface» and the names starts with a ‘ ’SoaML Tutorial, Software 201114

Choreography: Place order(Service(Si contracttt behaviour)b h i)(Service interface behaviour)consum e r:O rde rPla ce rService choreographycan be specified usingany UML behaviour, e.g,interaction or activityprovide r:O rde rTa k e roptquote R e que stquoteconsumer : OrrderPlacer[]quoteorderorderC onfirmationprovider : OrderTakkerorde rC onfirm a tionSoaML Tutorial, Software 2011quoteRequestorder15

Interfaces and message types:Place orderConsumerProvider interface,interface, Provider ProviderOrderTaker interface,interface, Consumer ConsumerOrderPlacer signal quote R e que st(in m e ssage : Q uote R e que st) signal orde r(in m e ssa ge : O rde r) signa l quote (in m e ssa ge : Q uote ) signa l orde rC onfirm a tion(in m e ssage : O rde rC onfirm a tion) MessageType Q t RQuoteRequesttEURUSD MessageType O dOrder MessageType Q tQuotecustom e rID : stringquote Date : da tecustom e rID : stringcustom e rO rde rID : stringre que st : Q uote R e que stprice : floatcustom e rO rde rID : stringprovide rO rde rID : stringC o nfirm e dShippe dproductID : stringquantity : inte ge rorde rDa te : da teproductID : stringcurre ncy : C urre ncyTypeconfirm ation : C onfirm a tionTypeconfirm ationDate : dateC a nce lle dO utO fStockquantityqy : inte geg r MessageType O d C fiOrderConfirmationti enumeration C urrencyType enumeration C onfirmationTypeshipmp e ntID : stringgProvider: Specifies the interface provided by the provider of a service. UML interface stereotyped «Provider».MessagetypeConsumer: Specifies the interface provided by the consumer of a service. UML interface stereotypedyp «Consumer».Message type: Specifies the information exchanged between service consumers and providers.yp «MessageType».g yp UML class stereotypedSoaML Tutorial, Software 201116

Service and request ports:Place order interface, Consumer OrderPlacer ServiceInterface PlaceOrderInterfaceRequestport Participant pDealer use ServiceInterface PlaceOrderInterface interface, Provider OrderTakerquo te R e que st()orde r()typeOrderTaker use quo te ()orde rC onfirm ation()typeOrderTaker Participant pManufacturer Se rvice s:Place O rde rInte rface R e que st r: Place O rde rInte rfa ceOrderPlacerOrderPlacerServiceportService: Specifiespa feature of a pparticipantpthat is the offer of a service byy oneparticipant to others using well defined terms, conditions and interfaces. UML port stereotyped «Service» on a participant or component.Request: Specifies a feature of a participant that represents a service the participantneeds and consumes from other participants. UML pport stereotypedyp «Request»qon a pparticipantpor component.pSoaML Tutorial, Software 201117

ServicesArchitecture Dealer Network Architectureconsumerorded r:PlaPl ce O rded rde a le r:De a le rproviderpacm e :Manufacture rconsumerconsumersta tus:Ship Statusprovidership:Shipping R e que stshippe r:Shippe rproviderLogical systemcomponents:Dealer NetworkArchitectureOrderTaker Participant Dealer R e que st r: P la ce O rde rInte rfaceR e que st tssi: ShipStai Shi St tusIntet I t rfacef ROrderTakerOrderPlacer Se rvice s:P lal ce O rded rInte rfaf ceOrderPlacerShipper R e que st sri: ShippingR e que stInte rfa ce Participant ShipperppShipper Se rvice ssi:ShipSta tusInte rface Se rvice sri:ShippingR e que stInte rfa ce Participant ManufacturerShippingProviderShippingConsumer ShippingProviderShippingConsumerComponents implement the service interfaces providing the link tosystems. Participants and services may be used in multiplearchitectures.SoaML Tutorial, Software 201118

ServicesArchitecture Manufacturer Architectureproviderconsumerorder:Pla ce O rde icingde ale r:De ale rconsumerprovideric:Invoice C ustom eroh:O rde rHa ndle rconsumerconsumership:Shipping R e questprovidershipper:Shippe rpo:Production O rde rproviderp:ProductionsMapped to software components Participant D lDealer R e que st r: Place O rde rInte rfa ce Participant Manufacturer Se rvice s:Place O rde rInte rfa ce Se rvice s:P la ce O rde rInte rfacei:Invoicingoh:O rde rHandle r Se rvice ici:Invoice C ustom e rInte rfa ce R e que st ici: Invoice C ustom e rInte rfa ce Participant Shipper R e que st poi: ProductionO rde rInte rfa ce R e que st sri: ShippingR e que stInte rface Se rvice sri:ShippingR e que stInte rfa ceSoaML Tutorial, Software 2011p:Productions Se rvice poi:ProductionO rde rInte rface R e que st sri: ShippingR e que stInte rface19

UML modellingg tool:ModelioSoaML Tutorial, Software 201120

Tool support for SoaML SoaML Wiki– IBM Rational SoftwareArchitect– IBM Rational SOMA– ModelDriven.org ModelPro– NoMagic MagicDrawUML– Softeam Modelio– SparxSSystemsS tEnterpriseE tiArchitecthttp://www.omgwiki.org/SoaML/doku.php Softeam Modelio– BPMN– SoaML oaML Tutorial, Software 20112121

Case study:y Travel agencygySoaML Tutorial, Software 201122

Case study:y Travel agencygy(Discount Voyage) A Travel Agency has somecontact with Partner Agencieswhich provide reservation forFlights HotelsFlights,Hotels, CarsCars, etcetc.ClientReseervePayCancel A Client can interact with theTravel Agency to:Haands onPartnerAgencyInsurance PurchasePSoaML Tutorial, Software 2011VisaTravel resservation facilitiees The Travel Agency needs tobe in contact with a Visapayment center in order to bepaid by the Client, and pay thePartner Agencies.Payment faacilities– Reserve a Travel:– Cancel a Travel– Pay the TravelTravel AgencyInsuranceCompany23

Scenario Travel Agency needs to purchase ap ycancellation insurance at 3rd partyInsurance company. The case study model will be updated with– BPMN: Pool, Tasks, Dataobject– BAM: Service Contract, Service Architecture– SAM: Service Interfaces, Participant, BPMNSoaML Tutorial, Software 201124

Business processpmodelling (BPMN)SoaML Tutorial, Software 201125

Business Rules, OrganizationSoaML e Contracts and ChoreographiesUse casesBusiness to System lInterfacesand MessagesService InterfacesServiceO h t tiOrchestrationsServiceChoreographiesSoftware ComponentsModel to Text (M2T)PlatformPlatformSpecificModel (PSM)Modelio BBusiness peerspective oon SOA IT perspective on SOAABusiness GoalsEARefined ureModel((BAM))TransformationUICloud, Web Services, JEE, MAS, P2P/Grid, SWSCIMPIMPSMModelioEnnterrprisse MMethoddoloogyEnterprise Business Processes, Domain model,BusinessModel (CIM)26

Business ArchitectureModel (BAM)BusinessArchitectureModel(BAM)Business turesService Contracts and Choreographies Represents the business perspective of an SOA. Captures business requirements and identifies services:– Business goals– Business processes– Capabilities Specifies the business community and its services:– Services architectures of the business community.– ServiceSi contractstt betweenb ttheth businessb ientitiestiti participatingti i ti iin ththecommunity.SoaML Tutorial, Software 201127

BusinessArchitectureM d ProcessesBusiness GoalsServicesArchitecturesCapabilitiesService Contracts and ChoreographiesModel to Model (M2M)SystemArchitectureModel(SAM)Interfacesand MessagesTransformationService nsSoftware ComponentsModel to Text (M2T)PlatformSpecificModel (PSM)SoaML Tutorial, Software 2011TransformationCloud, Web Services, JEE, MAS, P2P/Grid, SWS28

Refine business processes(1/2) Id if relevantIdentifylbbusinessiprocesses:– Focus on business processes that enable the business goals to be met.– Public and collaborative business processes between different businessorganizations. Map to community-level services architectures in SoaML– Private business processes within a business organization. MapM tot participant-levelti itll servicesiarchitectureshit ti SinSoaML.ML Refine the business processes:– Identify business entities and model them as pools or swimlanes.swimlanes Map to participants in SoaML– Focus on tasks that describe the interaction points between the business entities. Mapp to service contracts in SoaML– Identify the control and data flows between these tasks. Map to message types in SoaMLSoaML Tutorial, Software 201129

Refine business processes(2/2)ClientCasestudyexampleStartEventc : Client[ye s][cance l]C ancel Travel[no ]browse travelsdes tination:s tringSelectTravelt:T ravelPlaceOrderconfirmInterestC ancel?c :C lientProvide C redit C ard Detailsp:C ardD etailsEndEvento:O rder[no ]ta : TravelAgencytravels [* ]:T ravelC ancelOrdero:O rder4 8 hoursinitOrderFilecheckSolvencyC lientSolvable?pa : PartnerAgencyyb:B illingt:T ravelC heckAvailabilityo:O rderavailabilityvpc : VisaPaymentCenterdes tination:s tring[ye s]Indicate PricePlacesAvailableoc :O rdercancelTravelReservePlaceWithdraw From C redit C ardor:O rderSendInvoiceb:B illingEndEventTravelAgencygyi:I nvoic ePartnerAgencygyreserveTravelwithdrawsolvencyc :C lientVisaPaymentCenteryp:C ardD etailso:O rder[no]ta : TravelAgencytravels [* ]:T ravelC ancelOrdero:O rder4 8 hours[ye s]Indicate PriceinitOrderFileSoaML Tutorial, Software 2011checkSolvencyb:BillingC lientSolvable?C heckAvailabilityo:O rderPlacesAvailableoc :O rderReservePlaceor:O rder30With

Hands on exercise #1Hands-onHandson withModelio GoalG l– Revise the BPMN diagram Modelling– CreateC t a pooll– Create tasks– Crate a dataobject Walkthrough– Step by stepSoaML Tutorial, Software 201131

Walkthrough: BPMNdiagramHandson withModelio1. Open the BPMN diagram in “Business Architecture BusinessProcesses TravelReservationProcess”SoaML Tutorial, Software 201132

Walkthrough: BPMN poolHandson withModelio1. Create a pool “IC” in the BPMN diagramSoaML Tutorial, Software 201133

Walkthrough: BPMN tasksand flows11.2.Handson withModelioCreate a taskCk “P“PurchasehIInsurance”” iin theh TTravelAgencylApooll andda task “Process Insurance Request” in the IC poolModifyy the flow in the TravelAgencygyppool,, connectingg“ReservePlace” to “Purchase Insurance” and create a new flowfrom “Purchase Insurance to “Withdraw From Credit Card”.SoaML Tutorial, Software 201134

Walkthrough: BPMNdataobject and message flow11.2.3.Handson withModelioCreate a dCdataobjectbj“IR” iinthe TravelAgency pool.Connect the “PurchaseInsurance” to the “IR”dataobject with anassociation.associationConnect the “IR” dataobjectto the “Process InsuranceRRequest”t” iin ththe IC pooll withith amessage flow.SoaML Tutorial, Software 201135

Business architecturemodelling (SoaML)SoaML Tutorial, Software 201136

Specify services architectures(1/3) Services architectures– UML collaborations stereotyped «ServicesArchitecture».– Identified from the BPMN processes.p Participants– UML classes stereotyped «Participant».«Participant»– Identified from pools, participants and lanes in the BPMNprocesses. Service contracts.– UML collaborations stereotyped «ServiceContract».– Identified from possible interactions between participantsin the BPMN processes.SoaML Tutorial, Software 201137

Specify services [ye s]c : Client[cance l]des tination:s tringEachh PoolEP l canbe mapped to aParticipantParticipantSelectTravelt:T ravelPlaceOrderconfirmInterestC ancel?c :C lientp:C ardD etailsEndEvento:O rderta : TravelAgencyC ancelOrdero:O rder4 8 hours[ye s]Indicate PriceinitOrderFilecheckSolvencyC lientSolvable?b:B illingpa : PartnerAgencyyt:T ravelProvide C redit C ard Details[no ]travels [* ]:T ravelC heckAvailabilityo:O rderavailabilityvpc : VisaPaymentCenterdes tination:s tringC ancel Travel[no ]browse travelsPlacesAvailableoc :O rdercancelTravelReservePlaceWithdraw From C redit C ardor:O rderSendInvoiceb:B illingEndEventTravelAgencygyi:I nvoic ePartnerAgencygyreserveTravelwithdrawsolvencyc :C lientVisaPaymentCenteryp:C ardD etailso:O rder[no]ta : TravelAgencytravels [* ]:T ravelC ancelOrdero:O rder4 8 hours[ye s]Indicate PriceinitOrderFileInteractions between Poolsare categorizedas L Tutorial, Software 2011checkSolvencyb:BillingC lientSolvable?C heckAvailabilityo:O rderPlacesAvailableoc :O rderReservePlaceor:O rder38With

Specify services architectures(3/3)1. CreateCaSServices ArchitectureCasestudyexample2. Identifyf Participants Services

Travel Agency to: Travel Agency rve cel Travel Agency to: – Reserve a Travel: – Cancel a Travel Pay the Travel Payment f a Travel re s Insurance P H – Pay the Travel a The Travel Agency needs to be in contact with a Visa cilities ervation faciliti e urchase nds on be in contact with a Visa payment center in order to be paid by the .