IntroducingSOA and Oracle SOA Suite 11g to Oracle Database ProfessionalsWebLogic Server 11gOracle Open World 2009Monday, 12th OctoberLucas Jellema AMIS, The NetherlandsSOA Suite 11g
AgendaIntroducing SOA – what, why, howQuick overview of SOA Suite 11gLeveraging the SOA Suite from the databaseAccessing the database from the SOA SuiteApplying SOA principles to database developmentWrap up
SOA = BAD
BusinessAgility throughDecouplingSOA =
Decoupling≈Managing Dependenciesminimize impact of change while maximizing reusability
Types of decouplingFunctional Interface - Encapsulation of implementationDesign by Contract, Implement by DesignTechnicalNo proprietary technology, protocol, message formatStandards based (XML, HTTP, RSS, WSDL…)TemporalAsynchronous communication (separate response)DevelopmentSeparate teams working in parallel based on mutually agreed interface definitions
ObjectivesBusiness Agility(Faster) responses to market demandsCreating new business from existing resourcesIT FlexibilityOptimize locally without impact ‘globally’Prepare for future developmentsLower costsThrough reuse, better integration, decoupling
Objectives(longer term) Higher Quality and Faster (traceable) Process executionAutomated data exchange cross boundariesWorkflow and task orientationintegrated, cross department, in a controlled way based on sound understanding of the business processesBusiness Event driven interactionManage risks and fear
Common Characteristics in SOACross BoundariesCross Technology - .Net, Uniface, Java, TibcoCross Channel – Back Office, Web, PDA, APICross User Group – Internal, Agents, Self ServiceCross Domain – Multiple departments & systemsCross Enterprise – Interact with external partnersData synchronization or consolidationManagement whim VisionFrom Database angle: providing services
What is a service?Standards based callable, reusable functionality according to an interaction contractIn terms of functionality (WSDL – compare Package Specification)What are the input parametersWhat are the output parameters (if any)What are the exceptionsHow (when, where) is the response deliveredImplementation is hidden!
What is a service (2)?In terms of operational QoS (Quality of Service) define in a Service Level Agreement (SLA)Availability Stability & Release scheduleResponse TimePeak load capacityPriceReliability, ConfidentialityAddress, protocol
Services in various shapesLibrary (dll, jar)Java Class (public methods) or an EJB (interface)URLRSS feedPortlet (UI Service)SOAP WebServiceDatabase View or Package Specification….If it exposes a clear, standardized interface
Example of a service call?Browser makes sendshttp request to a URLText based message with headers and body
What is a service call?Server returns a responseAnother text based message with headers and body
Calling a Web ServiceSend an XML document to a URL via HTTPRequest message contains headers and bodyService (server) returns another XML documentResponse message contains headers and bodyResponse can be a fault (a WebService exception)Headers are used for meta-dataSender (identity, address), Return addressEncryption, digitally signed, Type of content, type of compression
The SOA Suite 11gThe engine that runs applications that implement the WebServicesInside the WebLogic Server application serverWebLogic Server 11gWebServicesSOA Suite 11g
SOA Suite 11g Composite ApplicationsSOA Composite Applications consist of special components that process XML messages:Decision Logic (go left or right, discount is X)Human Workflow (end user must act)BPEL (service orchestration)Mediator (filter, transform and route messages)
SOA Suite 11g – calling out to external service and adaptersSOA Composite Applications can call out to external WebServices and AdaptersAdapters connect to various technologiesDatabase (SQL & PL/SQL)Advanced QueuingFile & FTPJMS, MQ Series, EBSTCP/IP SocketsAdapters can triggerapplication execution
Leveraging SOA Suite 11g from the databaseThe database can call out to the SOA Suite 11gWith UTL_HTTP or Stored Java (2-way, synchronous)Through Advanced Queuing or Database Adapter polling (one way)WebLogic Server 11gSOA Suite 11gAQAQ
Call the “getOilPrice Service”We need to know the oil price for some calculations…But that price is not constant, we need the current priceWe do not want the exact market price, we have our own contractsLet’s define a constant in a packageOh, well, let’s call a WebService – Yahoo?Ah, the Purchasing department publishes a WebService for such data
PurchasingPrices available via SOAPPurchasingPrices Service is available as a (SOAP based) WebService (implemented using BPEL)Service and WSDL are available (URLs are known)
PurchasingPrices available via SOAPSOAP call over HTTP can be made from PL/SQLUsing UTL_HTTPAssemble SOAP messageEnvelopePayload Name of productMake HTTP Post requestProcess ResponseRetrieve and Return the product price“re-Publish” service as PL/SQL functionWebLogic Server 11gSOA Suite 11g
PurchasingPrices available via SOAPWebLogic Server 11gSOA Suite 11g
The database can ask the middle tier for other services as wellGet information from (or to) services on the intranet or internet (‘please get us the NBA scores ’)Publish/Send information to the internet (RSS, email, chat)Can tell the middle tierInteresting events and data changesTrigger cache refresh!Alert about (im)pending issues,attempted rule violations, …The outcome of batch calculcationsWebLogic Server 11gSOA Suite 11gWeb AppAQ
Happy Chatting – IM from the DatabaseWebLogic Server 11gServiceServiceDatabase can call a middletier service using utl_httpPassing in the destinationand the message contentThis Service sends it onwards to the Google Talk ServerCHAT_MGR
Database actively informs on eventsWebLogic Server 11gServiceServiceCHAT_MGREMP
Publish Services from the DatabaseDescribe Services in WSDL and XSLSpecify operations, input and output parametersDescribe complex data structures ofparametersPublish Database-based ServicesPlain URL services through PL/SQL packagesbased on MOD_PLSQL, XML DB or DBMS_EPGFull blown SOAP WebServices11g Native WebService (publish PL/SQL package), use UTL_DBWS, JPublisher for Java proxy class in AppServerLeverage SOA Suite to expose Database functionalityThrough the database adapter in SOA Suite/WLS
Oracle DB 11g NativeWebServicesPublish a PL/SQL Package as externally available WebServiceWSDL is auto-generatedSOAP calls over http and https are supported
SOA: Loading file contents into tableSOA application can contain services that read from or write to the databaseDatabase is passive – undergoing SQL or PL/SQLPolling can also be against database
SOA: Loading file contents into table
Can you do SOA with only a …
Key SOA concepts and lessonsFunctional interface, hiding implementation detailsPackage specificationSimple View API (possibly with IOT) – with complex joins, analytical functions, advanced SQL and PL/SQL integrationReusable, standardized services as flexible building blocksAggregate and Combine into more valuable reusablesGovernance: security, management of services, SLAsAllow for configuration without development or deployment effortDecoupling in every aspect!
Coupling & Decoupling in Oracle RDBMSDecouplingCouplingPackage SpecificationViews (+ Instead of Trigger)Triggers in generalDBMS_JOBAdvanced QueuingPublish (intranet) XML & WebService%TYPE instead of hardcoded data typeCentrally managed “parameter service”instead of local constants instead of hard coded valuesUse generic (SOA) servicesDatabase LinkSYSDATE and USERApplication performing SQL against tablesSQL all over the placeAccess database from DMZ or even outside firewallPublish WebService or Web Application on InternetToo frequent use of dbms_output.put_lineCopy and paste of codePoorly documented codeUse of exotic features
Decoupling Applications & DataApplication(User Interface)Application(User Interface)DataData
Decoupling Applications & DataApplication(User Interface)Application(User Interface)Data
Decoupling Applications & DataApplication(User Interface)WorkflowEngineCMSEmailIMFax
Decoupling from Table to ESB+httpWEBDAVFTPWSRPcoupledhttpWS/SOAPWS*WS*WS*complex
Increasingly decoupledMore hiding of the implementationMore Formal Interface ContractLess (proprietary) technology & more standards for interactingLess exposure of (legacy) data modelMore support for asynchronous interactionMore reuse potentialPervasive throughout enterpriseMore suitable for external consumption
Comes at a cost…More run time overheadAdditional tiersXML serialization and deserializationMore infrastructureBurden of AdministrationLicense CostsHardwareBroader skills palette – more stuff to masterHarder to get started
SummarySOA is about decoupling, integration & reuseSOA Suite 11g runs service implementationsThat can access database and other technologies through adapters – either inbound or outboundDatabase can access services from utl_httpOr AQ, Database polling or File pollingSOA Suite hooks into database via SQL, PL/SQL, AQ or even XML DB file protocolsMany SOA concepts can be applied without the SOA Suite, using standard DB features
ResourcesPresentation and demos are on our bloghttp://technology.amis.nl/blogContact me at:lucas.jellema@amis.nl

Introducing SOA and Oracle SOA Suite 11g for Database Professionals

  • 1.
    IntroducingSOA and OracleSOA Suite 11g to Oracle Database ProfessionalsWebLogic Server 11gOracle Open World 2009Monday, 12th OctoberLucas Jellema AMIS, The NetherlandsSOA Suite 11g
  • 2.
    AgendaIntroducing SOA –what, why, howQuick overview of SOA Suite 11gLeveraging the SOA Suite from the databaseAccessing the database from the SOA SuiteApplying SOA principles to database developmentWrap up
  • 3.
  • 4.
  • 5.
    Decoupling≈Managing Dependenciesminimize impactof change while maximizing reusability
  • 6.
    Types of decouplingFunctionalInterface - Encapsulation of implementationDesign by Contract, Implement by DesignTechnicalNo proprietary technology, protocol, message formatStandards based (XML, HTTP, RSS, WSDL…)TemporalAsynchronous communication (separate response)DevelopmentSeparate teams working in parallel based on mutually agreed interface definitions
  • 7.
    ObjectivesBusiness Agility(Faster) responsesto market demandsCreating new business from existing resourcesIT FlexibilityOptimize locally without impact ‘globally’Prepare for future developmentsLower costsThrough reuse, better integration, decoupling
  • 8.
    Objectives(longer term) HigherQuality and Faster (traceable) Process executionAutomated data exchange cross boundariesWorkflow and task orientationintegrated, cross department, in a controlled way based on sound understanding of the business processesBusiness Event driven interactionManage risks and fear
  • 9.
    Common Characteristics inSOACross BoundariesCross Technology - .Net, Uniface, Java, TibcoCross Channel – Back Office, Web, PDA, APICross User Group – Internal, Agents, Self ServiceCross Domain – Multiple departments & systemsCross Enterprise – Interact with external partnersData synchronization or consolidationManagement whim VisionFrom Database angle: providing services
  • 10.
    What is aservice?Standards based callable, reusable functionality according to an interaction contractIn terms of functionality (WSDL – compare Package Specification)What are the input parametersWhat are the output parameters (if any)What are the exceptionsHow (when, where) is the response deliveredImplementation is hidden!
  • 11.
    What is aservice (2)?In terms of operational QoS (Quality of Service) define in a Service Level Agreement (SLA)Availability Stability & Release scheduleResponse TimePeak load capacityPriceReliability, ConfidentialityAddress, protocol
  • 12.
    Services in variousshapesLibrary (dll, jar)Java Class (public methods) or an EJB (interface)URLRSS feedPortlet (UI Service)SOAP WebServiceDatabase View or Package Specification….If it exposes a clear, standardized interface
  • 13.
    Example of aservice call?Browser makes sendshttp request to a URLText based message with headers and body
  • 14.
    What is aservice call?Server returns a responseAnother text based message with headers and body
  • 15.
    Calling a WebServiceSend an XML document to a URL via HTTPRequest message contains headers and bodyService (server) returns another XML documentResponse message contains headers and bodyResponse can be a fault (a WebService exception)Headers are used for meta-dataSender (identity, address), Return addressEncryption, digitally signed, Type of content, type of compression
  • 16.
    The SOA Suite11gThe engine that runs applications that implement the WebServicesInside the WebLogic Server application serverWebLogic Server 11gWebServicesSOA Suite 11g
  • 17.
    SOA Suite 11gComposite ApplicationsSOA Composite Applications consist of special components that process XML messages:Decision Logic (go left or right, discount is X)Human Workflow (end user must act)BPEL (service orchestration)Mediator (filter, transform and route messages)
  • 18.
    SOA Suite 11g– calling out to external service and adaptersSOA Composite Applications can call out to external WebServices and AdaptersAdapters connect to various technologiesDatabase (SQL & PL/SQL)Advanced QueuingFile & FTPJMS, MQ Series, EBSTCP/IP SocketsAdapters can triggerapplication execution
  • 19.
    Leveraging SOA Suite11g from the databaseThe database can call out to the SOA Suite 11gWith UTL_HTTP or Stored Java (2-way, synchronous)Through Advanced Queuing or Database Adapter polling (one way)WebLogic Server 11gSOA Suite 11gAQAQ
  • 20.
    Call the “getOilPriceService”We need to know the oil price for some calculations…But that price is not constant, we need the current priceWe do not want the exact market price, we have our own contractsLet’s define a constant in a packageOh, well, let’s call a WebService – Yahoo?Ah, the Purchasing department publishes a WebService for such data
  • 21.
    PurchasingPrices available viaSOAPPurchasingPrices Service is available as a (SOAP based) WebService (implemented using BPEL)Service and WSDL are available (URLs are known)
  • 22.
    PurchasingPrices available viaSOAPSOAP call over HTTP can be made from PL/SQLUsing UTL_HTTPAssemble SOAP messageEnvelopePayload Name of productMake HTTP Post requestProcess ResponseRetrieve and Return the product price“re-Publish” service as PL/SQL functionWebLogic Server 11gSOA Suite 11g
  • 23.
    PurchasingPrices available viaSOAPWebLogic Server 11gSOA Suite 11g
  • 24.
    The database canask the middle tier for other services as wellGet information from (or to) services on the intranet or internet (‘please get us the NBA scores ’)Publish/Send information to the internet (RSS, email, chat)Can tell the middle tierInteresting events and data changesTrigger cache refresh!Alert about (im)pending issues,attempted rule violations, …The outcome of batch calculcationsWebLogic Server 11gSOA Suite 11gWeb AppAQ
  • 25.
    Happy Chatting –IM from the DatabaseWebLogic Server 11gServiceServiceDatabase can call a middletier service using utl_httpPassing in the destinationand the message contentThis Service sends it onwards to the Google Talk ServerCHAT_MGR
  • 26.
    Database actively informson eventsWebLogic Server 11gServiceServiceCHAT_MGREMP
  • 27.
    Publish Services fromthe DatabaseDescribe Services in WSDL and XSLSpecify operations, input and output parametersDescribe complex data structures ofparametersPublish Database-based ServicesPlain URL services through PL/SQL packagesbased on MOD_PLSQL, XML DB or DBMS_EPGFull blown SOAP WebServices11g Native WebService (publish PL/SQL package), use UTL_DBWS, JPublisher for Java proxy class in AppServerLeverage SOA Suite to expose Database functionalityThrough the database adapter in SOA Suite/WLS
  • 28.
    Oracle DB 11gNativeWebServicesPublish a PL/SQL Package as externally available WebServiceWSDL is auto-generatedSOAP calls over http and https are supported
  • 29.
    SOA: Loading filecontents into tableSOA application can contain services that read from or write to the databaseDatabase is passive – undergoing SQL or PL/SQLPolling can also be against database
  • 30.
    SOA: Loading filecontents into table
  • 31.
    Can you doSOA with only a …
  • 32.
    Key SOA conceptsand lessonsFunctional interface, hiding implementation detailsPackage specificationSimple View API (possibly with IOT) – with complex joins, analytical functions, advanced SQL and PL/SQL integrationReusable, standardized services as flexible building blocksAggregate and Combine into more valuable reusablesGovernance: security, management of services, SLAsAllow for configuration without development or deployment effortDecoupling in every aspect!
  • 33.
    Coupling & Decouplingin Oracle RDBMSDecouplingCouplingPackage SpecificationViews (+ Instead of Trigger)Triggers in generalDBMS_JOBAdvanced QueuingPublish (intranet) XML & WebService%TYPE instead of hardcoded data typeCentrally managed “parameter service”instead of local constants instead of hard coded valuesUse generic (SOA) servicesDatabase LinkSYSDATE and USERApplication performing SQL against tablesSQL all over the placeAccess database from DMZ or even outside firewallPublish WebService or Web Application on InternetToo frequent use of dbms_output.put_lineCopy and paste of codePoorly documented codeUse of exotic features
  • 34.
    Decoupling Applications &DataApplication(User Interface)Application(User Interface)DataData
  • 35.
    Decoupling Applications &DataApplication(User Interface)Application(User Interface)Data
  • 36.
    Decoupling Applications &DataApplication(User Interface)WorkflowEngineCMSEmailIMFax
  • 37.
    Decoupling from Tableto ESB+httpWEBDAVFTPWSRPcoupledhttpWS/SOAPWS*WS*WS*complex
  • 38.
    Increasingly decoupledMore hidingof the implementationMore Formal Interface ContractLess (proprietary) technology & more standards for interactingLess exposure of (legacy) data modelMore support for asynchronous interactionMore reuse potentialPervasive throughout enterpriseMore suitable for external consumption
  • 39.
    Comes at acost…More run time overheadAdditional tiersXML serialization and deserializationMore infrastructureBurden of AdministrationLicense CostsHardwareBroader skills palette – more stuff to masterHarder to get started
  • 40.
    SummarySOA is aboutdecoupling, integration & reuseSOA Suite 11g runs service implementationsThat can access database and other technologies through adapters – either inbound or outboundDatabase can access services from utl_httpOr AQ, Database polling or File pollingSOA Suite hooks into database via SQL, PL/SQL, AQ or even XML DB file protocolsMany SOA concepts can be applied without the SOA Suite, using standard DB features
  • 41.
    ResourcesPresentation and demosare on our bloghttp://technology.amis.nl/blogContact me at:lucas.jellema@amis.nl

Editor's Notes

  • #21 Call BPEL: http://ora-rich.blogspot.com/2007/06/calling-bpel-process-from-plsql.html
  • #22 Call BPEL: http://ora-rich.blogspot.com/2007/06/calling-bpel-process-from-plsql.html
  • #23 Call BPEL: http://ora-rich.blogspot.com/2007/06/calling-bpel-process-from-plsql.html
  • #24 Call BPEL: http://ora-rich.blogspot.com/2007/06/calling-bpel-process-from-plsql.html
  • #29 http://www.liberidu.com/blog/?p=244http://tardate.blogspot.com/2007/08/first-tests-of-11g-native-web-services.htmlhttp://download.oracle.com/docs/cd/B28359_01/appdev.111/b28369/xdb_web_services.htm#ADXDB3900
  • #30 Alternative to:(merge from) External TablesUtl_fileSQL*LoaderJava based solutionsExcel & ODBCXML DB
  • #31 Alternative to:(merge from) External TablesUtl_fileSQL*LoaderJava based solutionsExcel & ODBCXML DB