• Share
  • Email
  • Embed
  • Like
  • Save
  • Private Content
Building Service- Building Service- Oriented Architectures ...
 

Building Service- Building Service- Oriented Architectures ...

on

  • 905 views

 

Statistics

Views

Total Views
905
Views on SlideShare
901
Embed Views
4

Actions

Likes
1
Downloads
38
Comments
0

1 Embed 4

http://www.slideshare.net 4

Accessibility

Categories

Upload Details

Uploaded via as Adobe PDF

Usage Rights

© All Rights Reserved

Report content

Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
  • Full Name Full Name Comment goes here.
    Are you sure you want to
    Your message goes here
    Processing…
Post Comment
Edit your comment

    Building Service- Building Service- Oriented Architectures ... Building Service- Building Service- Oriented Architectures ... Presentation Transcript

    • Building Service- Oriented Architectures with Java Technology December 5 - 6, 2007 Portland & Seattle Tom Barrett SOA/BI Technical Specialist SCJP, SCJD, SCWCD, SCEA Sun Microsystems – Dallas thomas.barrett@sun.com
    • Agenda • Registration/Appetizer - Beverage Buffet (4:00 - 4:15) • SOA Defined (4:15 - 4:30) • SOA Technologies (4:30 – 5:30) • Integration Framework: Java Business Integration (JBI) (5:30 – 6:15) • Open Source Implementation: Open ESB (6:15 – 6:45) • Wrap-up / Resources (6:45 - 7:00) 2
    • Agenda • Registration/Appetizer - Beverage Buffet (4:00 - 4:15) • SOA Defined (4:15 – 4:30) > What's the problem? > What is SOA? > How is it being implemented? • SOA Technologies (4:30 – 5:30) • Integration Framework: Java Business Integration (JBI) (5:30 – 6:15) • Open Source Implementation: Open ESB (6:15 – 6:45) • Wrap-up / Resources (6:45 - 7:00) 3
    • What's the Problem? Accidental Architecture Credit Card Mortgage Balance Fraud Credit Credit Balance Interest Check Detection Check Check Check Calc Customer Back- Partner Partner Back- Customer Data End Credit Credit End Data System Data Data System 4
    • What's the Problem? Services-Oriented Architecture Auto Mutual Loans Bill Pay Stocks Funds Composite Applications Credit Card Mortgage Reusable Services Payment Credit Fraud Customer Trade Access Interest Balance Execution Management Check Detection Service Calc Check Data Service Service Service Internet Increased Agility Partner Credit Data Back-End System Back-End System Customer Data 5
    • What's the Problem? IT is Limiting the Business • Inflexibility of IT Infrastructure • Complexity of Integration Projects • Integration Costs • Time to Market • Limited Partnering Flexibility 6
    • Agenda • Registration/Appetizer - Beverage Buffet (4:00 - 4:15) • SOA Defined (4:15 – 4:30) > What's the problem? > What is SOA? > How is it being implemented? • SOA Technologies (4:30 – 5:30) • Integration Framework: Java Business Integration (JBI) (5:30 – 6:15) • Open Source Implementation: Open ESB (6:15 – 6:45) • Wrap-up / Resources (6:45 - 7:00) 7
    • What is SOA? Wikipedia Definition • Evolution of distributed computing and modular programming • Build applications out of software services that are: > Relatively large-grained (like: Fraud Detection, Payment Management, Trade Execution) > Intrinsically unassociated units of functionality (no embedded calls to other services) • Protocols are defined which describe how services can “talk” to each other • Relies on a business process expert to sequence services (orchestrate) to meet business needs http://en.wikipedia.org/wiki/Service-oriented_architecture 8
    • What is SOA? Sun Definition • Track-tested architectural style for building applications using services available in a network (“The Network is the Computer”) • Promotes loose-coupling between software components • Service implements a well-defined business functionality • Implementation is shielded by a public interface definition (signature / contract) • Services form building blocks of SOA applications • Composite applications can be built by aggregating services • Open standards have emerged to support web services implementation http://java.sun.com/developer/technicalArticles/WebServices/soa/ 9
    • What's is SOA? Catalyst • Business: “SOA is a catalyst for business transformation enabling your business to thrive on change ... SOA is a technology-based embodiment of your business” • IT: “IT must change its primary operating mode from delivering applications to a mode of delivering strategic business flexibility...” 10
    • Agenda • Registration/Appetizer - Beverage Buffet (4:00 - 4:15) • SOA Defined (4:15 – 4:30) > What's the problem? > What is SOA? > How is it being implemented? • SOA Technologies (4:30 – 5:30) • Integration Framework: Java Business Integration (JBI) (5:30 – 6:15) • Open Source Implementation: Open ESB (6:15 – 6:45) • Wrap-up / Resources (6:45 - 7:00) 11
    • How is SOA Being Implemented? Enterprise Service Bus (ESB) “An ESB is a Web-services-capable middleware infrastructure that supports intelligent program-to-program communication and mediates the relationships among loosely-coupled (SOA) and uncoupled (event-driven) business components.” - Roy Schulte Service-Oriented Architecture Event-Driven Architecture 12
    • How is SOA Being Implemented? ESB Characteristics • Typically implemented within one enterprise • Serves as an enterprise architecture where business services are developed with SOA in mind • Supports web services standards • Scales to enterprise-class performance • Fosters service and protocol pluggability • Provides development, deployment and management tools • Provides value-added technical services 13
    • How is SOA Being Implemented? ESB Value-Added Services Resource Channel Adapters Adapters Security Synchronization Service Consumers Logging Correlation Service Providers Monitoring Messaging Alerting Communication Transactions Transformation Routing BPM Load Balancing BAM 14
    • How is SOA Being Implemented? Gartner Perspective User Vendor Extensible Assemblies Suites Suites (Best of Breed) (Application Platform Suites) (Modules) 1990 2000 2010 Source: Gartner Inc., " The Battle for Platform Domination: Application Servers, SOA and Platforms Suites", Y. Natis, December 2006 15
    • How is SOA Being Implemented? Slowly and Cautiously Accidental Layered Rigid Extensible Silo-Oriented Service-Oriented Access Process Service Resource • Old approaches are deeply entrenched • SOA demands better linkages between IT and business units • Standards are still evolving • New technologies can be daunting 16
    • Agenda • Registration/Appetizer - Beverage Buffet (4:00 - 4:15) • SOA Defined (4:15 – 4:30) • SOA Technologies (4:30 – 5:30) > Web Services for service delivery > Business Process Execution Language (BPEL) for orchestration • Integration Framework: Java Business Integration (JBI) (5:30 – 6:15) • Open Source Implementation: Open ESB (6:15 – 6:45) • Wrap-up / Resources (6:45 - 7:00) 17
    • SOA Technologies Web Services: Definition • "A software system designed to support interoperable machine to machine interaction over a network." (W3C) • Clients and servers communicate using XML messages formatted SOAP (Simple Object Access Protocol): per the SOAP standard ● XML-based, message envelope format • WSDL description of the supported ● WSDL (Web Services Description Language): operations is available to the client XML format for describing service interfaces. Typically used to generate server and client code, and for configuration ● UDDI (Universal Description Discovery and Integration): protocol for publishing and discovering metadata about Web services http://en.wikipedia.org/wiki/Web_services 18
    • SOA Technologies Web Services: WSDL – Interface Definition Language > WSDL (Web Service Description Language) is a cornerstone for web services- based SOA implementations > W3C recommended standard way of defining an interface for web services > XML document describing network services as a set of endpoints > Endpoints are gateways for messages containing either document-oriented or procedure-oriented information > Endpoints described in abstract terms as operations which are bound to a concrete network protocol and message format 19
    • SOA Technologies Web Services: WSDL (Abstract vs. Concrete) Abstract Concrete 20
    • SOA Technologies Web Services: XSD Example XML Schema Definition (XSD) 21
    • SOA Technologies Web Services: WSDL Example - Messages ● Describes messages used by the web service ● Provides the data elements used by operations 22
    • SOA Technologies Web Services: WSDL Example - Operations ● Describes operations that can be performed and the messages passed ● Specifies multiple message elements to define a one-way or round-trip operation 23
    • SOA Technologies Web Services: WSDL Example – On the Wire ● Shows concrete specifics of how the service is implemented on the wire ● Defines message format and protocol details for each operation ● Transport declares how SOAP message will be sent ● Style specifies format of SOAP message 24
    • SOA Technologies Web Services: WSDL Example - Location ● Declares the address for invoking the service ● Usually provides a URL for invoking via SOAP 25
    • SOA Technologies Web Services: SOAP Example SOAP Messages 26
    • SOA Technologies Web Services: WSDL for Interface Design • Point my IDE at the service endpoint (http://localhost:8080/CalculateLoanPayment/CalculatePaymentServiceService?wsdl) • Tool automatically generates required client code to send and receive a SOAP message using the endpoint • Use the generated client component: > Provide it the inputs that the WSDL specified > Execute it > Use the delivered output specified in the WSDL 27
    • SOA Technologies Web Services: Interoperability WS-I Basic Profile • Specification from the Web Services Interoperability industry consortium (WS-I) • Provides interoperability guidance for SOAP, WSDL and UDDI • Version 1.0 appeared in 2004, 1.1 finalized in 2006 • Sample guidelines: > R1141 A MESSAGE MUST be sent using either HTTP/1.1 or HTTP/1.0. > R1140 A MESSAGE SHOULD be sent using HTTP/1.1. > R1132 A HTTP request MESSAGE MUST use the HTTP POST method. > R9980 An ENVELOPE MUST conform to the structure specified in SOAP 1.1 Section 4, "SOAP Envelope" > R1015 A RECEIVER MUST generate a fault if they encounter an envelope whose document element is not soap:Envelope. 28
    • SOA Technologies Web Services: Interoperability Web Services Interoperability Technologies (WSIT) • Web services interoperability effort to develop Java clients and service providers that interoperate with Microsoft .NET clients and service providers • Focuses on selected facets of WS-* to help customers that have large investments in both Java an .NET • Now offered as “Metro”: > JAX-WS reference implementation > WSIT https://wsit-docs.dev.java.net/releases/m5/WSITTutorial.pdf 29
    • SOA Technologies Web Services: Demonstration Scenario • Build two web services: > DetermineRateService (EJB module) > CalculatePaymentService (web module) • Deploy modules to application server • View generated schema definitions and WSDLs • Test web services loanType (String) interestRate (String) DetermineRate Service interestRate (double) loanAmount (double) periodInYears (int) monthlyPayment (double) CalculatePayment Service 30
    • REST Definition • REpresentational State Transfer "Representational State Transfer is intended to evoke an image of how a well-designed Web application behaves: • Architectural style defining rules for - A network of web pages (a virtual defining and addressing resources state-machine) • Each resource is uniquely - Where the user progresses through an application by selecting links (state addressable as a URI transitions) - Resulting in the next page (next state • Client/server, stateless and of the application) being transferred to cacheable the user and rendered for their use." - Roy Fielding • No protocol is assumed, but HTTP (REST inventor) is usually involved http://en.wikipedia.org/wiki/REST http://www.ics.uci.edu/~fielding/pubs/dissertation/top.htm 31
    • REST Definition: Example - Parts Depot • Get Parts List > Sends: http://www.parts-depot.com/parts > Receives: <?xml version="1.0"?> <p:Parts xmlns:p="http://www.parts-depot.com" xmlns:xlink="http://www.w3.org/1999/xlink"> <Part id="00345" xlink:href="http://www.parts-depot.com/parts/00345"/> <Part id="00346" xlink:href="http://www.parts-depot.com/parts/00346"/> <Part id="00347" xlink:href="http://www.parts-depot.com/parts/00347"/> <Part id="00348" xlink:href="http://www.parts-depot.com/parts/00348"/> Each hyperlink traversal </p:Parts> puts the application into a different state • Get Detailed Parts Data > Sends: http://www.parts-depot.com/parts/00345 > Receives: <?xml version="1.0"?> <p:Part xmlns:p="http://www.parts-depot.com" xmlns:xlink="http://www.w3.org/1999/xlink"> <Part-ID>00345</Part-ID> <Name>Widget-A</Name> <Description>This part is used within the frap assembly</Description> <Specification xlink:href="http://www.parts-depot.com/parts/00345/specification"/> <UnitCost currency="USD">0.10</UnitCost> <Quantity>10</Quantity> </p:Part> Building Web Services the REST Way Roger L.Costello -- http://www.xfront.com/REST-Web-Services.html 32
    • REST Definition: Benefits • Improves response times and server loading due to caching • Improves server scalability by reducing need to maintain state • Requires less client-side software because a browser can access any application and any resource • Doesn't depend on additional messaging frameworks atop HTTP • Provides equivalent functionality to alternatives (SOAP) • Does not utilize a separate resource discovery mechanism due to the use of hyperlinks in content http://en.wikipedia.org/wiki/REST 33
    • SOA Technologies Web Services: REST Adoption • “Over the past 2.5 years, the REST/SOAP call ratio to AWS (Amazon Web Services) has held pretty constant at 80/20.” http://www.jeff-barr.com/?p=96 (November 2004) • “Q: Does Yahoo! plan to support SOAP? A: Not at this time. We may provide SOAP interfaces in the future, if there is significant demand. We believe REST has a lower barrier to entry, is easier to use than SOAP, and is entirely sufficient for these services.” http://developer.yahoo.com/faq/ 34
    • SOA Technologies Web Services: Tim Bray on REST Adoption http://www.tbray.org/ongoing/When/200x/2006/04/17/SOA-or-not • What do you think we should do about SOA? > “Don't do anything. 'SOA' may have meant something once but it's just vendor b!ul#h%t now.” > Architects thought “web” made “web services” sound lightweight and too easy to set up > So, they got uncomfortable and made web services more “Enterprisey” > “Web” part is more important than “services” part so “SOA isn't the future, Web style is” 35
    • SOA Technologies Rest Tooling: A Little Awkward from Java public class Artist extends HttpServlet { public enum SupportedOutputFormat {XML, JSON}; protected void doGet(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException { String accept = request.getHeader("accept").toLowerCase(); See if accept header String acceptableTypes[] = accept.split(","); should be processed SupportedOutputFormat outputType = null; as XML or JSON for (String acceptableType: acceptableTypes) { (JavaScript Object if (acceptableType.contains("*/*") || acceptableType.contains("application/*") || acceptableType.contains("application/xml")) { outputType=SupportedOutputFormat.XML; Notation) break; } else if (acceptableType.contains("application/json")) { outputType=SupportedOutputFormat.JSON; break; } } if (outputType==null) response.sendError(415); Unsupported Media Type String path = request.getPathInfo(); String pathSegments[] = path.split("/"); Parse the pathInfo String artist = pathSegments[1]; if (pathSegments.length < 2 && pathSegments.length > 3) response.sendError(404); Not Found else if (pathSegments.length == 3 && pathSegments[2].equals("recordings")) { URL specifies “recordings” so if (outputType == SupportedOutputFormat.XML) writeRecordingsForArtistAsXml(response, artist); deliver recordings in response else writeRecordingsForArtistAsJson(response, artist); } else { if (outputType == SupportedOutputFormat.XML) writeArtistAsXml(response, artist); If not “recordings”, then deliver else writeArtistAsJson(response, artist); artist information is response } } private void writeRecordingsForArtistAsXml(HttpServletResponse response, String artist) { ... } private void writeRecordingsForArtistAsJson(HttpServletResponse response, String artist) { ... } private void writeArtistAsXml(HttpServletResponse response, String artist) { ... } private void writeArtistAsJson(HttpServletResponse response, String artist) { ... } } JSR 311:JAX-RS: The Java™ API forRESTful Web Services (TS-6411) Marc Hadley, Paul Sandoz, Roderico Cruz Java One 2007 http://blogs.sun.com/sandoz/resource/TS-6411.pdf 36
    • SOA Technologies Rest Tooling: A Better Way • Goals > High level expression > Declarative > Clear mapping to REST concepts > Generates the boilerplate code • Approach > JAX-RS: Java API for RESTful Web Services > JSR 311 (Draft April 2007) > Jersey is open source reference implementation JSR 311:JAX-RS: The Java™ API forRESTful Web Services (TS-6411) Marc Hadley, Paul Sandoz, Roderico Cruz Java One 2007 http://blogs.sun.com/sandoz/resource/TS-6411.pdf 37
    • SOA Technologies Rest Tooling: Early Look at JAX-RS @UriTemplate("/artists/{id}") @ProduceMime("application/xml") public class Artist { @HttpMethod InputStream getXml(@UriParam("id") String artist) { ... } @HttpMethod @ProduceMime("application/json") InputStream getJson(@UriParam("id") String artist) { ... } @HttpMethod @UriTemplate("recordings") InputStream getRecordingsXml(@UriParam("id") String artist) { ... } @HttpMethod @ProduceMime("application/json") @UriTemplate("recordings") InputStream getRecordingsJson(@UriParam("id") String artist) { ... } } JSR 311:JAX-RS: The Java™ API forRESTful Web Services (TS-6411) Marc Hadley, Paul Sandoz, Roderico Cruz Java One 2007 http://blogs.sun.com/sandoz/resource/TS-6411.pdf 38
    • Agenda • Registration/Appetizer - Beverage Buffet (4:00 - 4:15) • SOA Defined (4:15 – 4:30) • SOA Technologies (4:30 – 5:30) > Web Services for service delivery > Business Process Execution Language (BPEL) for orchestration • Integration Framework: Java Business Integration (JBI) (5:30 – 6:15) • Open Source Implementation: Open ESB (6:15 – 6:45) • Wrap-up / Resources (6:45 - 7:00) 39
    • Agenda • Registration/Appetizer - Beverage Buffet (4:00 - 4:15) • SOA Defined (4:15 – 4:30) • SOA Technologies (4:30 – 5:30) > Web Services for service delivery > Business Process Execution Language (BPEL) for orchestration • Integration Framework: Java Business Integration (JBI) (5:30 – 6:15) • Open Source Implementation: Open ESB (6:15 – 6:45) • Wrap-up / Resources (6:45 - 7:00) 40
    • SOA Technologies BPEL: Definition • XML-based language for formally describing business processes and business integration • Extends web service interactions to support orchestration and long- running business transactions • History: > Inspired by IBM’s Web Services Flow Language (WSFL) and Microsoft’s XLANG > BPEL4WS (Business Process Execution Language for Web Services) was first conceived in July 2002 with the release of the BPEL4WS 1.0 specification, a joint effort by IBM, Microsoft and BEA > Evolved into WS-BPEL 2.0 in April 2007, as a standard now managed by OASIS (Organization for the Advancement of Structured Information Standards) • Prerequisites for personal success: > XML > WSDL > Programming experience 41
    • SOA Technologies BPEL: Example Oh my, sorta scary https://blueprints.dev.java.net/bpcatalog/ee5/soa/index.html 42
    • SOA Technologies BPEL: Example Code folding makes this a little more approachable, still scary though 43
    • SOA Technologies BPEL: Example When the purchase order service receives the client request, the following activities are performed: 1 Purchase order service provider assigns the price for the request 2 Purchase order service provider invokes the inventory service to check inventory status 3 Inventory service provider checks availability of an item 4 If the incoming purchase order's orderDescription value starts with OrderVal, then the order's status is available in the inventory Based on Business 5 Based on the result from the inventory Process Modeling service, the purchase order service Notation (BPMN) provider responds with the fulfilled purchase order Now we're talkin' ! 44
    • SOA Technologies BPEL: Example Receive When the purchase order service receives the client request, the following activities are performed: 1 Purchase order service provider assigns the price for the request 2 Purchase order service provider invokes the inventory service to check inventory status 3 Inventory service provider checks availability of an item 4 If the incoming purchase order's orderDescription value starts with OrderVal, then the order's status is <receive name="sendPurchaseOrder" partnerLink="POServicePLink" available in the inventory portType="pos:purchaseOrderPT" operation="sendPurchaseOrder" 5 Based on the result from the variable="purchaseOrderRequest" inventory service, the purchase createInstance="yes"> </receive> order service provider responds with the fulfilled purchase order 45
    • SOA Technologies BPEL: Example Assign When the purchase order service receives the client request, the following activities are performed: 1 Purchase order service provider assigns the price for the request <assign name="Assign"> <copy> 2 Purchase order service provider <from>49.98</from> invokes the inventory service to <to>$purchaseOrderRequest.purchaseOrder/po:price</to> </copy> check inventory status <copy> <from>$purchaseOrderRequest.purchaseOrder/po:orderId</from> 3 Inventory service provider checks <to>$inventoryServiceRequest.purchaseOrder/po:orderId</to> </copy> availability of an item <copy> <from>$purchaseOrderRequest.purchaseOrder/po:customerId</from> 4 If the incoming purchase order's <to>$inventoryServiceRequest.purchaseOrder/po:customerId</to> </copy> orderDescription value starts with <copy> OrderVal, then the order's status is <from>$purchaseOrderRequest.purchaseOrder/po:orderDescription</from> <to>$inventoryServiceRequest.purchaseOrder/po:orderDescription</to> available in the inventory </copy> <copy> 5 Based on the result from the <from>$purchaseOrderRequest.purchaseOrder/po:price</from> <to>$inventoryServiceRequest.purchaseOrder/po:price</to> inventory service, the purchase </copy> order service provider responds </assign> with the fulfilled purchase order BPEL: Now we're talkin' 46
    • SOA Technologies BPEL: Example When the purchase order Invoke service receives the client request, the following activities are performed: 1 Purchase order service provider assigns the price for the request 2 Purchase order service provider invokes the inventory service to check inventory status 3 Inventory service provider checks availability of an item 4 If the incoming purchase order's <invoke name="inventoryService" partnerLink="requestInventoryPLink" orderDescription value starts with portType="invs:inventoryPortType" OrderVal, then the order's status is operation="inventoryService" inputVariable="inventoryServiceRequest" available in the inventory outputVariable="inventoryServiceReply"> 5 Based on the result from the </invoke> inventory service, the purchase order service provider responds with the fulfilled purchase order 47
    • SOA Technologies BPEL: Example <if name="Decision"> <condition>$inventoryServiceReply.inventoryP art/inv:inventoryStatus</condition> Decision <sequence name="Case2"> When the purchase order <assign name="Assign1"> ... service receives the client </assign> <reply name="sendPurchaseOrder.Reply1" request, the following activities partnerLink="POServicePLink" operation="sendPurchaseOrder" are performed: portType="pos:purchaseOrderPT" variable="purchaseOrderRequest"/> 1 Purchase order service provider </sequence> <else> assigns the price for the request <sequence name="Case1"> <assign name="Assign2"> 2 Purchase order service provider ... </assign> invokes the inventory service to <reply name="sendPurchaseOrder.Reply" check inventory status partnerLink="POServicePLink" portType="pos:purchaseOrderPT" operation="sendPurchaseOrder" 3 Inventory service provider checks variable="purchaseOrderFault" availability of an item faultName="pos:cannotCompleteOrder /> </sequence> 4 If the incoming purchase order's </else> </if> orderDescription value starts with OrderVal, then the order's status is available in the inventory 5 Based on the result from the inventory service, the purchase order service provider responds with the fulfilled purchase order Reply 48
    • SOA Technologies BPEL: Advanced Topics Fault Handler May contain multiple catch elements, each of which provides activities that perform exception handling for a specific type of error condition. Faults can be generated by: ● Receipt of a WSDL-defined fault message ● Explicitly triggered through the use of the throw element. 49
    • SOA Technologies Flow BPEL: Advanced Topics Pick Pick / onMessage Pick / onAlarm ● Flow: a series of activities that can occur concurrently and are required to complete after all have finished executing ● Pick: enables a process to respond to events; can contain onMessage and onAlarm child elements that trigger process activity upon the arrival of specific types of messages (after a predefined period of time, or at a specific date and time) 50
    • SOA Technologies BPEL: Example • Build a BPEL process to orchestrate the two web services we created earlier: > DetermineRateService > CalculatePaymentService • Build a composite application containing our: > BPEL process > Two web services • Deploy application to application server • Test application loanAmount (double) loanAmount (double) periodInYears (int) concat periodInYears (int) description (String) loanType (String) loanType (String) interestRate (String) interestRate (double) monthlyPayment (double) monthlyPayment DetermineRate CalculatePayment Service Service 51
    • Agenda • Registration/Appetizer - Beverage Buffet (4:00 - 4:15) • SOA Defined (4:15 – 4:30) • SOA Technologies (4:30 – 5:30) • Integration Framework: Java Business Integration (JBI) (5:30 – 6:15) > Specification and Concepts > JBI and Service Component Architecture (SCA) • Open Source Implementation: Open ESB (6:15 – 6:45) • Wrap-up / Resources (6:45 - 7:00) 52
    • Java Business Integration (JBI) Integration Landscape • Current Integration Industry > Proprietary approaches > Converging on a service-based approach > Agreeing on standard messaging model • Time is Right for a Standard > Java Community Process unveiled JSR 208 in June 2005 > Goal: Allow developers to provide more sophisticated applications and achieve better integration with other Java platform technologies > Standard “meta-container” for integrated services > Provides for plug-in components of two types: > Engines supporting business logic and functions > Bindings providing communications protocols 53
    • Java Business Integration (JBI) 1.0 Specification Focus • Extends Java EE and Java SE with business integration service provider interfaces (SPIs) • SPIs enable the creation of a Java business integration environment hosting composite applications involving technologies like: > BPEL > Rules > XSLT > Existing Java implementations • Defines a static model of services with no control over: > Sequencing or timing conditions placed on the use of services > Interactions of components acting as consumers and providers • Doesn't comprehend: > Coordination of services across multiple processes > Services distributed across different domains of control 54
    • Java Business Introduction (JBI) Vision • Sun's foundation for Service-Oriented Architecture (SOA) • Component standard for service providers and service consumers • Foster ecosystem of portable, manageable and interoperable components • Composite applications (service assemblies) provide glue to orchestrate services • Bottom Line: > JBI pluggability: an open, extensible, pluggable platform that enables the collaboration of integration technology (like business process engines, document transform engines, B2B management and business rules) with Web services > JBI service assembly: a single standard document describing the routing, artifacts, and services that make up an SOA “application.” Think of it as an SOA “super .jar.” JBI is to do for integration what J2EE did for application development 55
    • Java Business Integration (JBI) Pre-SOA 56
    • Java Business Integration (JBI) With SOA 57
    • Java Business Integration (JBI) Foundation for SOA: With SOA Service Engines: “containers” that provide business logic or transformation services. ● Service Engines and They may provide unique Binding Components programming models. can function as service providers, consumers or both ● Separation of business logic from communication logic reduces implementation complexity and increases flexibility Binding Components: enable communication protocols to allow to and from remote access 58
    • Java Business Integration Components: Service Engines & Binding Components Orchestration Transformation J2EE Platform (BPEL) (XSLT) Management JBI System • The “JBI Bus”: a fast, reliable, in- memory messaging bus Normalized Message Router Core Services message exchanges Mediates all • between consumers and providers • Acts as a discovery service to help consumers find providers • Message payloads are opaque data sent along to the receiver (no canonicalization) WS-I Basic AS2 JMS • Normalization not performed when SOAP consumer and provider in same JBI container J2EE™ Platform 59
    • Java Business Integration (JBI) Real World Scenario • Online travel agency website • Users can book flights and hotel rooms • Workflow engine: > Connects to airline to book flight > Connects to hotel to book room > Sends email confirmations to customers “Build an SOA application from existing services” http://www.javaworld.com/javaworld/jw-10-2006/jw-1011-jbi.html By Adrien Louis, JavaWorld.com, 10/11/2006 60
    • Java Business Integration (JBI) 2.0 Specification Kickoff • JSR 312 started in May 2007 and led by Sun • Goal: Enable a Java business integration environment for the creation of composite applications. JSR 312 augments 1.0 to address open areas and new requirements • Initial Expert Group > Apache > Pramati > Brian O'Neil > Adobe > Sun > TIBCO > DPWN SOP Group > WebMethods > TmaxSoft > Red Hat > EBM Websourcing > James Strachan > Eric Smith • Road Map > Early Draft Review: Q3/2007 > Public Review Draft: Q4/2007 > Final Specification: late Q2/2008 > Reference Implementation (RI) to be made available through the Open ESB project 61
    • Java Business Integration (JBI) 2.0 Specification: Under Discussion • Administration of JBI in clustered or distributed environments • Clarify and enhance JBI's role in creation, deployment and runtime JBI could form support of composite applications an optional or profile extension to the Java EE platform at some stage in the future. • Support requirements stemming from WS-Policy • Support Web 2.0 technologies and usage models • Facilitate performance optimizations by component and container implementers • Improve alignment with Java EE (e.g. use of transactions) • Explore message exchange handler/interceptor model • Address recoverability of message exchanges • Align with the Service Component Architecture (SCA) specifications with the goal of making JBI 2.0 a standard Java runtime for SCA • Provide full compatibility with OSGi Java-based service platform • Explore JBI 1.0 technical topics like: component life cycle, error handling, threading and NIO use • Explore WS-CDL (Choreography Definition Language) for designing (composing) applications, modifying (recomposing) them and permitting run-time discovery and enforcement of dynamic interaction rules 62
    • Agenda • Registration/Appetizer - Beverage Buffet (4:00 - 4:15) • SOA Defined (4:15 – 4:30) • SOA Technologies (4:30 – 5:30) • Integration Framework: Java Business Integration (JBI) (5:30 – 6:15) > Specification and Concepts > JBI and Service Component Architecture (SCA) • Open Source Implementation: Open ESB (6:15 – 6:45) • Wrap-up / Resources (6:45 - 7:00) 63
    • JBI and SCA What is SCA? • Specification describing a model for building applications based upon SOA • Led by IBM and BEA outside the Java Community Process • Approach: > Implementation: develop components (in multiple languages) that offer capabilities (services) that are consumed via an interface (reference) > Assembly: build applications by aggregating components by wiring references to services • Specifications recently submitted to OASIS http://www.osoa.org/pages/viewpage.action?pageId=46 64
    • JBI and SCA What is SCA? • Composite assembled using a set of components • Components can be composites in their own right http://www.osoa.org/download/attachments/35/SCA_AssemblyModel_V100.pdf?version=1 65
    • JBI and SCA Coexistence and Synergy • SCA sees JBI as helpful in implementing SCA on the Java platform • JBI appreciates SCA service metadata as helpful in standardizing service composition in general • SCA and JBI are not competitors as they focus on different aspects of service composition • SCA and JBI have different target audiences: > SCA: Developers, assemblers and deployers who build composite applications > JBI: Middleware and service providers who need to build containers and need to know how to introduce new implementation types and bindings into the runtime • SCA can be used with or without JBI and visa versa • JBI may be inappropriate if composite application includes lots of components that don't run in a JVM • SCA may be inappropriate if the application is pure Java and is served well by the metadata and assembly unit composition that JBI provides “Relationship of SCA and JBI” - March 2007 http://www.osoa.org/display/Main/Relationship+of+SCA+and+JBI 66
    • JBI and SCA Coexistence and Synergy • SCA sees JBI as helpful in implementing SCA on the Java platform • JBI appreciates SCA service metadata as helpful in standardizing service composition in general • SCA and JBI are not competitors as they focus on different aspects of service composition • SCA and JBI have different target audiences: > SCA: Developers, assemblers and deployers who build composite applications > JBI: Middleware and service providers who need to build containers and need to know how to introduce new implementation types and bindings into the runtime • SCA can be used with or without JBI and visa versa • JBI may be inappropriate if composite application includes lots of components that don't run in a JVM • SCA may be inappropriate if the application is pure Java and is served well by the metadata and assembly unit composition that JBI provides “Relationship of SCA and JBI” - March 2007 http://www.osoa.org/display/Main/Relationship+of+SCA+and+JBI 67
    • Agenda • Registration/Appetizer - Beverage Buffet (4:00 - 4:15) • SOA Defined (4:15 – 4:30) • SOA Technologies (4:30 – 5:30) • Integration Framework: Java Business Integration (JBI) (5:30 – 6:15) • Open Source Implementation: Open ESB (6:15 – 6:45) > Project introduction/Components > Road Map • Wrap-up / Resources (6:45 - 7:00) 68
    • Open ESB • Enterprise Service Bus runtime implemented atop the Java Business Integration (JBI) foundation • Open Source-Based (https://open-esb.dev.java.net/) • Runs atop Glassfish/Sun Application Server • Open ESB Starter Kit available today in: > Java Application Platform SDK > Java EE 5 SDK > Glassfish (Sun Application Server) > NetBeans 6.0 (includes tooling like BPEL, XSD, WSDL editors) • Components: > Service Engines (BPEL, JMS, Java EE, ...) > Binding Components (HTTP/SOAP, FTP, JDBC ...) 69
    • Open ESB The Ecosystem: Componentry https://open-esb.dev.java.net/Components.html 70
    • Agenda • Registration/Appetizer - Beverage Buffet (4:00 - 4:15) • SOA Defined (4:15 – 4:30) • SOA Technologies (4:30 – 5:30) • Integration Framework: Java Business Integration (JBI) (5:30 – 6:15) • Open Source Implementation: Open ESB (6:15 – 6:45) > Project introduction/Components > Road Map • Wrap-up / Resources (6:45 - 7:00) 71
    • Road Map Java Composite Application Platform Suite (Java CAPS) is Sun's commercial delivery vehicle for Open ESB technology Java CAPS Evolution Partners Validation Engines Business Rules Enterprise Information Integration Java CAPS Ecosystem enabler, Event Stream Processing Improved standards support Common Tooling for Java EE, SOA, Integration, etc. NetBeans Open ESB GlassFish JAX-WS JBI NetBeans Tango BPEL v2 V6 72
    • Road Map Java CAPS Evolution Composite Application Platform Suite CAPS 5.1.3 CAPS 5.2.1 CAPS 5.3 Productivity & CAPS 5.2 Platform Refresh Semantic Mapping, Stability OSS Re-Platform, Add. Community Comp Aspects for SOA, Complex Event Dynamically-Typed Processing Languages B2B 5.1.0 X12, HIPAA B2B 5.1.1 B2B 5.2 (Healthcare) AS2, ebXML Aligns w/ CAPS 5.2 OSS: Open ESB Open ESB V2 Open ESB V2 Open ESB V2 Open ESB V3 Open ESB V3 Open ESB V3 (preview 1) (preview 2) (final) (preview 1) (preview 2) (final) Binary Distrib. Binary Distrib. Binary Distrib. Binary Distrib. Binary Distrib. Binary Distrib. Mural Open Source Data Management Project Q1 Q2 Q3 Q4 Q1 Q2 Q3 Q4 Q1 Q2 Q3 Q4 2007 2008 2009 2010 2010 Dates are Calendar All future dates subject to change. 73
    • Open ESB and Java CAPS Phased Technology Availability Java One 2006 (NetBeans 5.5 Preview) (NetBeans 5.0) Java One 2007 (NetBeans 6 Preview) CH1 2008 (Java CAPS 5.2) 74
    • Agenda • Registration/Appetizer - Beverage Buffet (4:00 - 4:15) • SOA Defined (4:15 – 4:30) • SOA Technologies (4:30 – 5:30) • Integration Framework: Java Business Integration (JBI) (5:30 – 6:15) • Open Source Implementation: Open ESB (6:15 – 6:45) • Wrap-up / Resources (6:45 - 7:00) 75
    • References • Service-Oriented Architecture (SOA) > “Service-Oriented Architecture (SOA) and Web Services: The Road to Enterprise Application Integration” http://java.sun.com/developer/technicalArticles/WebServices/soa/ > “Service-oriented architecture” http://en.wikipedia.org/wiki/Service-oriented_architecture 76
    • References • Web Services > “Web service” http://en.wikipedia.org/wiki/Web_services > “Web Services Description Language (WSDL) Version 2.0 Part 0: Primer” http://www.w3.org/TR/wsdl20-primer/ > “WS-I Basic Profile” http://en.wikipedia.org/wiki/WS-I_Basic_Profile > “Building Web Services the REST Way” http://www.xfront.com/REST-Web-Services.html > “Representational State Transfer” http://en.wikipedia.org/wiki/REST > “JSR 311: JAX-RS: “The Java API for RESTful Web Services” TS-6411 JavaOne 2007 http://blogs.sun.com/sandoz/resource/TS-6411.pdf 77
    • References • Business Process Execution Language (BPEL) > “Web Services Business Process Execution Language Version 2.0 Primer” http://www.oasis-open.org/committees/download.php/23964/wsbpel-v2.0- primer.htm > “Business Process Execution Language, Part 1: An Introduction” http://developers.sun.com/jsenterprise/nb_enterprise_pack/reference/techart/bp el.html > “Business Process Execution Language, Part 2: partnerLinkType and partnerLink” http://developers.sun.com/jsenterprise/nb_enterprise_pack/reference/techart/bp el2.html > “Web Services Orchestration Using BPEL” https://blueprints.dev.java.net/bpcatalog/ee5/soa/index.html 78
    • References • Java Business Integration (JBI) > “Relationship of SCA and JBI” http://www.osoa.org/display/Main/Relationship+of+SCA+and+JBI > “SCA Service Component Architecture: Assembly Model Specification” http://www.osoa.org/download/attachments/35/SCA_AssemblyModel_V100.pdf ?version=1 > “Build an SOA application from existing services” http://www.javaworld.com/javaworld/jw-10-2006/jw-1011-jbi.html • Open ESB > “About Open ESB” https://open-esb.dev.java.net/AboutOpenEsb.html > “Open ESB FAQs” https://open-esb.dev.java.net/FAQs.html > “Open ESB Components” https://open-esb.dev.java.net/Components.html 79
    • Take Aways (in a nutshell) • SOA is an architectural style that embodies good design principles. It's not new. • SOA is all about crafting a reusable services layer that addresses siloed applications and point-to-point interfaces • SOA can get us closer to the business. • Open standards have made SOA possible in heterogeneous environments • SOA is being implemented on ESB infrastructure using extensible suites from vendors like Sun • Web services and BPEL are the key technologies that we need to master as SOA practitioners • Web services use XML, WSDL, XSD and SOAP to provide interoperability • BPEL provides orchestration for composite applications that use web services • JBI provides a middleware standard for integration in the Java community • SCA is focusing on the assembly model for building composite applications • There are great future synergies with the combination of JBI and SCA • Open ESB is the reference implementation for JBI and is the basis for the next generation of Sun's Java CAPS product 80
    • Special Offer • Access step-by-step tutorial for my two demo segments • Utilize Online Lab Community to work through the demos without installing an software on your machine 81
    • Special Offer • Send me an email: thomas.barrett@sun.com • I'll send you an email with login instructions • Any catch? No! We just want your feedback on the online lab environment 82
    • Agenda Revisited • Registration/Appetizer - Beverage Buffet (4:00 - 4:15) • SOA Defined (4:15 - 4:30) • SOA Technologies (4:30 – 5:30) • Integration Framework: Java Business Integration (JBI) (5:30 – 6:15) • Open Source Implementation: Open ESB (6:15 – 6:45) • Wrap-up / Resources (6:45 - 7:00) 83
    • Building Service- Oriented Architectures with Java Technology December 5 - 6, 2007 Portland & Seattle Tom Barrett SOA/BI Technical Specialist SCJP, SCJD, SCWCD, SCEA Sun Microsystems – Dallas thomas.barrett@sun.com