Introducing SOA and Oracle SOA Suite 11g for Database Professionals


Published on

This session introduces SOA and the new Oracle SOA Suite 11g to the realm of database professionals from which it sometimes seems so far removed. What are the key SOA concepts and objectives? What is at the heart of Oracle SOA Suite 11g: composite applications, BPEL PM, and the mediator. The session shows how SOA services can be leveraged from the database, from triggers, PL/SQL units, or even SQL and how the database can publish events to the event delivery network. It covers how the SOA infrastructure can access the database, primarily using Oracle Database and Oracle Advanced Queueing adapter and how database developers can help in doing so efficiently. It ends with hints for applying SOA concepts to "normal" database development.

Published in: Technology
No Downloads
Total views
On SlideShare
From Embeds
Number of Embeds
Embeds 0
No embeds

No notes for slide
  • Call BPEL:
  • Call BPEL:
  • Call BPEL:
  • Call BPEL:
  • Alternative to:(merge from) External TablesUtl_fileSQL*LoaderJava based solutionsExcel & ODBCXML DB
  • Alternative to:(merge from) External TablesUtl_fileSQL*LoaderJava based solutionsExcel & ODBCXML DB
  • Introducing SOA and Oracle SOA Suite 11g for Database Professionals

    1. 1. IntroducingSOA and Oracle SOA Suite 11g to Oracle Database Professionals<br />WebLogic Server 11g<br />Oracle Open World 2009<br />Monday, 12th October<br />Lucas Jellema <br />AMIS, The Netherlands<br />SOA Suite 11g<br />
    2. 2. Agenda<br />Introducing SOA – what, why, how<br />Quick overview of SOA Suite 11g<br />Leveraging the SOA Suite from the database<br />Accessing the database from the SOA Suite<br />Applying SOA principles to database development<br />Wrap up<br />
    3. 3. SOA = BAD<br />
    4. 4. Business<br />Agility through<br />Decoupling<br />SOA =<br />
    5. 5. Decoupling≈Managing Dependencies<br />minimize impact of change while maximizing reusability<br />
    6. 6. Types of decoupling<br />Functional <br />Interface - Encapsulation of implementation<br />Design by Contract, Implement by Design<br />Technical<br />No proprietary technology, protocol, message format<br />Standards based (XML, HTTP, RSS, WSDL…)<br />Temporal<br />Asynchronous communication (separate response)<br />Development<br />Separate teams working in parallel based on mutually agreed interface definitions<br />
    7. 7. Objectives<br />Business Agility<br />(Faster) responses to market demands<br />Creating new business from existing resources<br />IT Flexibility<br />Optimize locally without impact ‘globally’<br />Prepare for future developments<br />Lower costs<br />Through reuse, better integration, decoupling<br />
    8. 8. Objectives<br />(longer term) Higher Quality and Faster (traceable) Process execution<br />Automated data exchange cross boundaries<br />Workflow and task orientation<br />integrated, cross department, in a controlled way based on sound understanding of the business processes<br />Business Event driven interaction<br />Manage risks and fear<br />
    9. 9. Common Characteristics in SOA<br />Cross Boundaries<br />Cross Technology - .Net, Uniface, Java, Tibco<br />Cross Channel – Back Office, Web, PDA, API<br />Cross User Group – Internal, Agents, Self Service<br />Cross Domain – Multiple departments & systems<br />Cross Enterprise – Interact with external partners<br />Data synchronization or consolidation<br />Management whim Vision<br />From Database angle: providing services<br />
    10. 10. What is a service?<br />Standards based callable, reusable functionality according to an interaction contract<br />In terms of functionality (WSDL – compare Package Specification)<br />What are the input parameters<br />What are the output parameters (if any)<br />What are the exceptions<br />How (when, where) is the response delivered<br />Implementation is hidden!<br />
    11. 11. What is a service (2)?<br />In terms of operational QoS (Quality of Service) define in a Service Level Agreement (SLA)<br />Availability <br />Stability & Release schedule<br />Response Time<br />Peak load capacity<br />Price<br />Reliability, Confidentiality<br />Address, protocol<br />
    12. 12. Services in various shapes<br />Library (dll, jar)<br />Java Class (public methods) or an EJB (interface)<br />URL<br />RSS feed<br />Portlet (UI Service)<br />SOAP WebService<br />Database View or Package Specification<br />….<br />If it exposes a clear, standardized interface<br />
    13. 13. Example of a service call?<br />Browser makes sendshttp request to a URL<br />Text based message with headers and body<br />
    14. 14. What is a service call?<br />Server returns a response<br />Another text based message with headers and body<br />
    15. 15. Calling a Web Service<br />Send an XML document to a URL via HTTP<br />Request message contains headers and body<br />Service (server) returns another XML document<br />Response message contains headers and body<br />Response can be a fault (a WebService exception)<br />Headers are used for meta-data<br />Sender (identity, address), Return address<br />Encryption, digitally signed, <br />Type of content, type of compression<br />
    16. 16. The SOA Suite 11g<br />The engine that runs applications that implement the WebServices<br />Inside the WebLogic Server application server<br />WebLogic Server 11g<br />WebServices<br />SOA Suite 11g<br />
    17. 17. SOA Suite 11g Composite Applications<br />SOA Composite Applications consist of special components that process XML messages:<br />Decision Logic (go left or right, discount is X)<br />Human Workflow (end user must act)<br />BPEL (service orchestration)<br />Mediator (filter, transform and route messages)<br />
    18. 18. SOA Suite 11g – calling out to external service and adapters<br />SOA Composite Applications can call out to external WebServices and Adapters<br />Adapters connect to various technologies<br />Database (SQL & PL/SQL)<br />Advanced Queuing<br />File & FTP<br />JMS, MQ Series, EBSTCP/IP Sockets<br />Adapters can triggerapplication execution<br />
    19. 19. Leveraging SOA Suite 11g from the database<br />The database can call out to the SOA Suite 11g<br />With UTL_HTTP or Stored Java (2-way, synchronous)<br />Through Advanced Queuing or Database Adapter polling (one way)<br />WebLogic Server 11g<br />SOA Suite 11g<br />AQ<br />AQ<br />
    20. 20. Call the “getOilPrice Service”<br />We need to know the oil price for some calculations…<br />But that price is not constant, we need the current price<br />We do not want the exact market price, we have our own contracts<br />Let’s define a constant in a package<br />Oh, well, let’s call a WebService – Yahoo?<br />Ah, the Purchasing department publishes a WebService for such data<br />
    21. 21. PurchasingPrices available via SOAP<br />PurchasingPrices Service is available as a (SOAP based) WebService (implemented using BPEL)<br />Service and WSDL are available (URLs are known)<br />
    22. 22. PurchasingPrices available via SOAP<br />SOAP call over HTTP can be made from PL/SQL<br />Using UTL_HTTP<br />Assemble SOAP message<br />Envelope<br />Payload <br />Name of product<br />Make HTTP Post request<br />Process Response<br />Retrieve and Return the product price<br />“re-Publish” service as PL/SQL function<br />WebLogic Server 11g<br />SOA Suite 11g<br />
    23. 23. PurchasingPrices available via SOAP<br />WebLogic Server 11g<br />SOA Suite 11g<br />
    24. 24. The database can ask the middle tier for other services as well<br />Get information from (or to) services on the intranet or internet (‘please get us the NBA scores ’)<br />Publish/Send information to the internet (RSS, email, chat)<br />Can tell the middle tier<br />Interesting events and data changes<br />Trigger cache refresh!<br />Alert about (im)pending issues,attempted rule violations, …<br />The outcome of batch calculcations<br />WebLogic Server 11g<br />SOA Suite 11g<br />Web App<br />AQ<br />
    25. 25. Happy Chatting – IM from the Database<br />WebLogic Server 11g<br />Service<br />Service<br />Database can call a middletier service using utl_http<br />Passing in the destinationand the message content<br />This Service sends it onwards to the Google Talk Server<br />CHAT_MGR<br />
    26. 26. Database actively informs on events<br />WebLogic Server 11g<br />Service<br />Service<br />CHAT_MGR<br />EMP<br />
    27. 27. Publish Services from the Database<br />Describe Services in WSDL and XSL<br />Specify operations, input and output parameters<br />Describe complex data structures ofparameters<br />Publish Database-based Services<br />Plain URL services through PL/SQL packages<br />based on MOD_PLSQL, XML DB or DBMS_EPG<br />Full blown SOAP WebServices<br />11g Native WebService (publish PL/SQL package), use UTL_DBWS, JPublisher for Java proxy class in AppServer<br />Leverage SOA Suite to expose Database functionality<br />Through the database adapter in SOA Suite/WLS<br />
    28. 28. Oracle DB 11g NativeWebServices<br />Publish a PL/SQL Package as externally available WebService<br />WSDL is auto-generated<br />SOAP calls over http and https are supported<br />
    29. 29. SOA: Loading file contents into table<br />SOA application can contain services that read from or write to the database<br />Database is passive – undergoing SQL or PL/SQL<br />Polling can also be against database<br />
    30. 30. SOA: Loading file contents into table<br />
    31. 31. Can you do SOA with only a …<br />
    32. 32. Key SOA concepts and lessons<br />Functional interface, hiding implementation details<br />Package specification<br />Simple View API (possibly with IOT) – with complex joins, analytical functions, advanced SQL and PL/SQL integration<br />Reusable, standardized services as flexible building blocks<br />Aggregate and Combine into more valuable reusables<br />Governance: security, management of services, SLAs<br />Allow for configuration without development or deployment effort<br />Decoupling in every aspect!<br />
    33. 33. Coupling & Decoupling in Oracle RDBMS<br />Decoupling<br />Coupling<br />Package Specification<br />Views (+ Instead of Trigger)<br />Triggers in general<br />DBMS_JOB<br />Advanced Queuing<br />Publish (intranet) XML & WebService<br />%TYPE instead of hardcoded data type<br />Centrally managed “parameter service”<br />instead of local constants <br />instead of hard coded values<br />Use generic (SOA) services<br />Database Link<br />SYSDATE and USER<br />Application performing SQL against tables<br />SQL all over the place<br />Access database from DMZ or even outside firewall<br />Publish WebService or Web Application on Internet<br />Too frequent use of dbms_output.put_line<br />Copy and paste of code<br />Poorly documented code<br />Use of exotic features<br />
    34. 34. Decoupling Applications & Data<br />Application(User Interface)<br />Application(User Interface)<br />Data<br />Data<br />
    35. 35. Decoupling Applications & Data<br />Application(User Interface)<br />Application(User Interface)<br />Data<br />
    36. 36. Decoupling Applications & Data<br />Application<br />(User Interface)<br />WorkflowEngine<br />CMS<br />Email<br />IM<br />Fax<br />
    37. 37. Decoupling from Table to ESB+<br />http<br />WEBDAV<br />FTP<br />WSRP<br />coupled<br />http<br />WS/SOAP<br />WS*<br />WS*<br />WS*<br />complex<br />
    38. 38. Increasingly decoupled<br />More hiding of the implementation<br />More Formal Interface Contract<br />Less (proprietary) technology & more standards for interacting<br />Less exposure of (legacy) data model<br />More support for asynchronous interaction<br />More reuse potential<br />Pervasive throughout enterprise<br />More suitable for external consumption<br />
    39. 39. Comes at a cost…<br />More run time overhead<br />Additional tiers<br />XML serialization and deserialization<br />More infrastructure<br />Burden of Administration<br />License Costs<br />Hardware<br />Broader skills palette – more stuff to master<br />Harder to get started<br />
    40. 40. Summary<br />SOA is about decoupling, integration & reuse<br />SOA Suite 11g runs service implementations<br />That can access database and other technologies through adapters – either inbound or outbound<br />Database can access services from utl_http<br />Or AQ, Database polling or File polling<br />SOA Suite hooks into database via SQL, PL/SQL, AQ or even XML DB file protocols<br />Many SOA concepts can be applied without the SOA Suite, using standard DB features<br />
    41. 41. Resources<br />Presentation and demos are on our blog<br /><br />Contact me at:<br /><br />