A Guide to the SOA Galaxy: Strategy, Design and Best Practices


Published on

Published in: Technology, Business
  • Be the first to comment

No Downloads
Total views
On SlideShare
From Embeds
Number of Embeds
Embeds 0
No embeds

No notes for slide

A Guide to the SOA Galaxy: Strategy, Design and Best Practices

  1. 1. A Guide to the SOA Galaxy:Strategy, Design and Best Practices Dmitri Shiryaev Java Tools Sun Microsystems, Inc.
  2. 2. Guide to the SOA Galaxy 3. JBIYou are here 2. BPEL 4. ESB 1. Intro 5. Java CAPS 6. . The Answer To Everything
  3. 3. Business-IT Context for SOA• Creating an IT environment to support continuous business optimization• Structures your IT applications in line with your business processes – Speeds business change – Facilitates business connections – Enchances business control• Heavy focus on flexible interconnections with carefully managed qualities of service (QoS)
  4. 4. Why SOA? ChannelsPartners Customers Internal Users Suppliers • Inflexibility of IT Infrastructure • Complexity of Integration Projects $ $ $ $ $$ $ $ • Integration Costs $ $ $ • Time to Market $ • Limited Partnering Flexibility $ $ • Limitations of EDI $ $ $Inventory Provisioning Legacy CRM Billing Information Assets
  5. 5. SOA and Web Services• Web services are most peoples first and only exposure to SOA• Only one manner of service access – Message-oriented middleware (MOM) – CORBA, RMI, DCOM, raw sockets, Email etc.• SOA architectures tend to be best implemented using web services as the middleware technology
  6. 6. Why Services?• SOA = an architectural principle for structuring systems• SOA emphasizes the de-coupling of system components• New services are created from existing ones in a synergistic fashion• Strong service definitions are critical• Services can be subsequently re-composed in response to changing business requirements
  7. 7. What Are Services?• A function accessed using XML message exchange• Message exchanges have well known exchange patterns• Services are self-describing, using metadata (WSDL)
  8. 8. What Does a Service Do?• Transform data• Route messages• Query databases• Orchestrate conversations• Apply business logic• Apply business policy• Handle business exceptions• Solicit approvals• …
  9. 9. How Is a Service Implemented?• XSLT• Enterprise JavaBeans™ (EJB™) technology• BPEL• SQL• XQuery• Routing table• Business rules• EDI transform• …
  10. 10. Benefits of SOA• Flexible (Agile) IT – Adaptable to changing business needs• Faster time to market – Reuse existing code, minimize new development• Business and process-driven – New business opportunities• Greater ROI – Leverage existing IT asset
  11. 11. SOA Layers Access LayerProcess LayerService LayerResource Layer
  12. 12. The “Move” to SOA Non- Integrated Integrated and Shared
  13. 13. The Shift• SOA is a combined effort between IT and the business units er SOA Proc Lay ess e Defi Layer rvic viderSe ro ner P IT Biz Units
  14. 14. Pre-SOA Scenario Credit Mortgage Card Balance Fraud Credit Credit Balance Interest Check Detection Check Check Check Calc Back-End Partner Partner Back-EndCustomer Customer System Credit Data Credit System Data Data Data
  15. 15. SOA-Enabled Scenario Auto Mutual Loans Bill Pay Stocks Funds Credit Card Mortgage Reusable Services Payment Trade Credit Fraud Access Interest Balance Customer Management Execution Check Detection Service Calc Check Data Service Service ServiceInternet Increased Agility Partner Credit Back-End Back-End Customer Data Data System System
  16. 16. SOA Architectural Big Rules Coarse GrainedBusiness Services Document-based Mostly Async Conversational Reliable Secure/Identity Policy Driven Registered and Retrieved WSDL Described BPEL Orchestrated JBI-based
  17. 17. n esig ed SOA Architectural Big Rules D Focu sCoarse Grained Business Services XML Document-based Mostly Async Conversational
  18. 18. i es alit edSOA Architectural Big Rules Qu us Foc Reliable Secure/Identity Policy Driven Registered and Retrieved
  19. 19. ds n d ar dSOA Architectural Big Rules Sta cuse Fo WSDL Described BPEL Orchestrated JBI-based
  20. 20. Guide to the SOA Galaxy You are here 3. JBI 2. BPEL 4. ESB 1. Intro 5.Java CAPS 6. The Answer To Everything
  21. 21. Need for Business Process• Developing the web services and exposing the functionality is not sufficient• We also need a way to orchestrate these functionality in the right order• Example: – Concert ticket purchase Web service has 3 operations, which need to be performed in the following order • Getting a price quote • Purchase a ticket • Confirmation and cancellation
  22. 22. BPEL (Business Process Execution Language)• XML-based language used to specify business processes based on Web Services• BPEL processes describe – Long running, stateful, transactional, conversations between two or more partner web services• BPEL is key to implementing SOA Big Rules – Conversational – Mostly Async – XML Document-based – Orchestrated
  23. 23. BPEL “Fixes” WSDL• WSDL: unordered set of operations – Operations are message exchanges• Need rules for ordering• Support for sequencing• Support for concurrency• Choreography with external entities
  24. 24. BPEL Is a Web Service Sequencing Language• Process defines “conversation” flow chart – Conversation consists of only WSDL-described message exchanges – BPEL provides and consumes WSDL defined services• Process instance is a particular conversation following the chart – Execution systems can support multiple concurrent conversations
  25. 25. BPEL Works With WSDL• Web services are described in WSDL – Operations are message exchanges – Each operation represents an individual unit of action• We need a way to orchestrate these operations with multiple web services in the right order to perform a Business process – Sequencing, conditional behavior etc.• BPEL provides standard-based orchestration of these operations
  26. 26. BPEL: Relationship to Partners WSDL Inventory Checker Service Credit checker ServiceCustomer Service Orchestrating Process Another Partner (BPEL) Service
  27. 27. BPEL Document Structure<process> <!– Definition and roles of process participants --> <partnerLinks> ... </partnerLinks> <!- Data/state used within the process --> <variables> ... </variables> <!- Properties that enable conversations --> <correlationSets> ... </correlationSets> <!- Exception handling --> <faultHandlers> ... </faultHandlers> <!- Error recovery – undoing actions --> <compensationHandlers> ... </compensationHandlers> <!- Concurrent events with process itself --> <eventHandlers> ... </eventHandlers> <!- Business process flow --> (activities)*</process>
  28. 28. BPEL ActivitiesBasic Activities Structured Activities• <invoke> • <sequence>• <receive> • <while>• <reply> • <pick>• <assign> • <flow>• <throw> • <scope>• <wait> • <compensate>• <empty> • <switch> • <link>
  29. 29. BPEL: Basic Activities• <invoke> – To invoke a one-way or request/response operation on a portType offered by a partner• <receive> – To do a blocking wait for a matching message to arrive – Can be the instantiator of the business process• <reply> – To send a message in reply to a message that was received through a <receive> – The combination of a <receive> and a <reply> forms a request-response operation on the WSDL portType for the process
  30. 30. BPEL: Basic Activities• <assign> – Can be used to update the values of variables with new data• <throw> – Generates a fault from inside the business process• <wait> – Allows you to wait for a given time period or until a certain time has passed• <empty> – Allows you to insert a "no-op" instruction into a business process – This is useful for synchronization of concurrent activities, for instance
  31. 31. BPEL: Structured Activities• <sequence> – Perform activities in sequential order• <flow> – Perform activities in parallel• <switch> – Conditional choice of activities• <scope> – Enclose multiple activities in a single scope
  32. 32. Example Business Process Receive <PO> <sequence>Invoke <InventoryService> Invoke <CreditService> <flow> Reply <Invoice> </sequence>
  33. 33. Authoring BPEL?• BPEL is difficult to write – Programming in XML: arghhhh! – XML Schema • Real-world schemas are huge and complex • Run the other way if you can – WSDL extensions • As if WSDL weren’t confusing enough• BPEL is an execution language only – Not a modeling notation
  34. 34. BPMN (Business Process Modeling Notation)• Notation for business process diagrams – Based on flowcharting techniques – Has special considerations for Web Services – Readily understandable by... • Business users • Business analysts • Software developers• But, BPMN and BPEL are complimentary – BPEL: execution language without a notation – BPMN: notation with a comprehensive mapping to BPEL
  35. 35. Visual Service Orchestration
  36. 36. Guide to the SOA Galaxy 3. JBI 2. BPEL You are here 4. ESB 1. SOA 5. Java CAPS 6. The Answer To Everything
  37. 37. SOA – Decouples service consumers from providers – Separates business logic from services – Enables dynamic service discovery/use – Appealing to large enterprises (flexible/scalable)Business integration – Application to application (A2A) – Business to business (B2B) – Business process management (BPM) – Many architectures, technologies, vendors
  38. 38. What is JBI (JSR-208)?● One of the biggest motivation for SOA is to reduce the cost of application integration● Standard-based, pluggable infrastructure – Service Engines: Provides business logic and integration services – Binding Components: Provides communications protocols• Composite, event-driven services• Extensible administration• Loose coupling via WSDL message exchanges
  39. 39. JBI (JSR-208) – Standardizes: • A Java technology-based Extensible Meta-container • Installable components (binding components and service engines) • Packaging/deployment (service units and service assemblies) • Normalized message routing (WSDL-2.0 based) • Component/deployment management (Ant and JMX™ API) • And more
  40. 40. Runtime: Java EE Platform and Java Business Integration• Java Business Integration serves as messaging infrastructure – Java EE web services interact through Java Business Integration – Java Business Integration bindings allow remote consumers and providers – Add other service technologies as Java Business Integration components• Transparent to programmer using Java EE technology – Reuse without re-coding
  41. 41. JBI Architecture
  42. 42. JBI—Service Engine• Hosts business logic implementing services• Exposes service endpoints – Agnostic of protocol and transport• Engages in Message Exchange Patterns – Normalized messages—target remote service• Is a target for deployment—a container – Engine-specific artifacts – May cause endpoint activation
  43. 43. JBI—Binding Component• Handles protocol-specific message re- formatting – Deals with wire transport of messages – E.g. SOAP/HTTP, FTP, SMTP, JMS, ebMS, AS2, etc.• Should contain no business logic• Exposes proxy endpoints for remote services• Proxies JBI services to remote consumers• (Re)Used by multiple service engines
  44. 44. JBI Administration• Standard installation of components – Portable archive format• Service Assembly (SA) – Portable package of a composite service• Service Unit (SU) – Each deployed to one component type• Lifecycle Management – Start/stop/shutdown
  45. 45. JBI—Service Assembly DeploymentSA=Proxy Service BPEL Engine JBI.xml SU activity.xml 1 XSLT Engine transform.xslt SU 2 SOAP/HTTP endpoint.xml Binding SU 3
  46. 46. Guide to the SOA Galaxy 3. JBI You are here 2. BPEL 4. ESB 1. Intro 5. Java CAPS 6. The Answer to Everything
  47. 47. Enterprise Service Bus• Distributed services architecture• Enterprise-grade communications backbone for reliable messaging• Intelligent routing and content-based routing• Process coordination• Flexible security framework• XML transformation• Management
  48. 48. Project Open ESB• Open source, based on the JSR-208 RI• + Multiple JBI instances (+ synchronization)• + Distributed normalized message routing/proxying• + Central administration (+ CLI and Web Console)• And more
  49. 49. JBI and Project Open ESB• Java Business Integration – Service Unit – Component – Service Assembly – Standardized MBeans• Project Open ESB – Distributed JBI – Centralized Management
  50. 50. Guide to the SOA Galaxy 3. JBI 2. BPEL 4. ESB You are here 1. Intro 5 Java CAPS. 6. Answer to Everything
  51. 51. Composite Applications• A composite application is a collection of existing and independently developed applications and new business logic, orchestrated together into a brand new solution of a business problem that none alone can solve• Such an application looks to the user like a regular new interactive application, yet in reality it may be only 10 percent new and 90 percent an assembly of pre-existing components or data; the “glue” that brings a composite application together is integration technology
  52. 52. Suns Vision for the SOA Platform
  53. 53. Suns SOA Platform
  54. 54. Java ES and Suites Over 1 Million TM Java Enterprise System Java ES Subscribers Composite Communications Management Application Platform Availability Management Tools IdentityDeveloper Tools Application Platform B2B Web ESB Infrastructure Storage + STK
  55. 55. Java Composite Application Platform Suite
  56. 56. Positioning Java CAPSUnique Combination of: ● Unified ● Comprehensive ● AgileValue Proposition: The industrys most complete, secure, unified and scalable platform for the development, deployment and management of enterprise integration and composite applications
  57. 57. Open ESB and Java CAPS Open ESB Java CAPS SuitesEntry Level, Standards-Based ESB Fifth-generation, ESB-based JBI Architecture Integration Suite with full Available: 1H 2006 functionality Available NOW Use: For Use: Run Your Develop Enterprise on ers this.
  58. 58. Guide to the SOA Galaxy 3. JBI 2. BPEL 4. ESB 1. Intro 5 Java CAPS. You are here 6. The Answer (finally) To Everything
  59. 59. The Answer to Everything... Tools
  60. 60. SOA ToolNetBeans EnterprisePack 5.5Rapid Architecture and Design of Services
  61. 61. Overview• Will focus on higher level features that are important to building enterprise applications..for example.... – SOA • Composite Application Building • Business Process Orchestration • Integration • Rich Visual XML Tools – Application Lifecycle Management • UML Modeling • Project Management • Automatic Project Wiki Documentation
  62. 62. Enterprise Customer NeedDesign of Composite Services
  63. 63. Rapid Architecture and Design of Services SOA• Enterprise Platform J2EE 1.5 Sun Java System Application Server XML Data web Services Portability Application Sun Web Services Portability Developer Pack
  64. 64. Visual Service Orchestration• Service Orchestrations – Model Business process in the Orchestration Designer – Generate deployable BPEL based orchestrations – Round trip engineering between visual Web service model and BPEL process – Import and export BPEL
  65. 65. Visual Service Orchestration
  66. 66. Summary• SOA enables flexible and agile enterprise application architecture• JBI provides standard based SOA framework• BPEL enables standard based orchestration of services• NetBeans Enterprise Pack is the tool to use for building SOA-enabled enterprise applications
  67. 67. Call For Action• Try “free” Java Studio Enterprise for building industry strength Web services• Try Technology Preview version of NetBeans Enterprise Pack 5.5 for integrating SOA-enabled services• Join Sun Developer Network (SDN) for up- to-date SOA information
  68. 68. Resources• SDN (Sun Developer Network) SOA/WebServices – http://java.sun.com/reference/soawebservices/• Java Studio Enterprise – http://developers.sun.com/prodtech/javatools/j senterprise/• NetBeans Enterprise Pack 5.5 – http://enterprise.netbeans.org
  69. 69. Sun Developer NetworkEmpowering the DeveloperIncreasing developerproductivity with: Technical articles Tutorials and sample codes Monitored forum support Community involvement through user groups, events, and conferences And more... http://developer.sun.com