Building a Service Oriented Architecture with the Apache ... · Bruce Snyder Ñ Building a Service...
Transcript of Building a Service Oriented Architecture with the Apache ... · Bruce Snyder Ñ Building a Service...
![Page 1: Building a Service Oriented Architecture with the Apache ... · Bruce Snyder Ñ Building a Service Oriented Architecture with the Apache ServiceMix ESB Slide 10 Java Business Integration](https://reader031.fdocuments.in/reader031/viewer/2022011903/5f135a60fd50066f7c4a0884/html5/thumbnails/1.jpg)
Bruce SnyderIONA Technologies
Building a Service Oriented Architecture with the Apache ServiceMix ESB
Colorado Software Summit: October 21 – 26, 2007 © Copyright 2007, IONA Technologies
Bruce Snyder — Building a Service Oriented Architecture with the Apache ServiceMix ESB Slide 1
![Page 2: Building a Service Oriented Architecture with the Apache ... · Bruce Snyder Ñ Building a Service Oriented Architecture with the Apache ServiceMix ESB Slide 10 Java Business Integration](https://reader031.fdocuments.in/reader031/viewer/2022011903/5f135a60fd50066f7c4a0884/html5/thumbnails/2.jpg)
How is SOA Like Cycling Up a Mountain?
- Break down large tasks into smaller ones! -- Bite size pieces are more realistic-- Many small goals instead of one big one
Colorado Software Summit: October 21 – 26, 2007 © Copyright 2007, IONA Technologies
Bruce Snyder — Building a Service Oriented Architecture with the Apache ServiceMix ESB Slide 2
![Page 3: Building a Service Oriented Architecture with the Apache ... · Bruce Snyder Ñ Building a Service Oriented Architecture with the Apache ServiceMix ESB Slide 10 Java Business Integration](https://reader031.fdocuments.in/reader031/viewer/2022011903/5f135a60fd50066f7c4a0884/html5/thumbnails/3.jpg)
Build on Many Small Successes to Reach Your Goal!
- Build on many small successes to reach your goal
Colorado Software Summit: October 21 – 26, 2007 © Copyright 2007, IONA Technologies
Bruce Snyder — Building a Service Oriented Architecture with the Apache ServiceMix ESB Slide 3
![Page 4: Building a Service Oriented Architecture with the Apache ... · Bruce Snyder Ñ Building a Service Oriented Architecture with the Apache ServiceMix ESB Slide 10 Java Business Integration](https://reader031.fdocuments.in/reader031/viewer/2022011903/5f135a60fd50066f7c4a0884/html5/thumbnails/4.jpg)
Breaking Down the Problem is Half the Battle...
- SOA is: -- An architectural paradigm - SOA is not: -- A product-- One size fits all
- Smaller, more distinct, distributed and reusable units of logic called services- Composite services - aggregate of - Designed to better withstand unpredictable change
Colorado Software Summit: October 21 – 26, 2007 © Copyright 2007, IONA Technologies
Bruce Snyder — Building a Service Oriented Architecture with the Apache ServiceMix ESB Slide 4
![Page 5: Building a Service Oriented Architecture with the Apache ... · Bruce Snyder Ñ Building a Service Oriented Architecture with the Apache ServiceMix ESB Slide 10 Java Business Integration](https://reader031.fdocuments.in/reader031/viewer/2022011903/5f135a60fd50066f7c4a0884/html5/thumbnails/5.jpg)
Service compositions are about a coordinated aggregate of services
- Loose coupling- Service contracts- Autonomy - Abstraction- Reusability - Composability- Statelessness- Discoverability
Colorado Software Summit: October 21 – 26, 2007 © Copyright 2007, IONA Technologies
Bruce Snyder — Building a Service Oriented Architecture with the Apache ServiceMix ESB Slide 5
![Page 6: Building a Service Oriented Architecture with the Apache ... · Bruce Snyder Ñ Building a Service Oriented Architecture with the Apache ServiceMix ESB Slide 10 Java Business Integration](https://reader031.fdocuments.in/reader031/viewer/2022011903/5f135a60fd50066f7c4a0884/html5/thumbnails/6.jpg)
Services Form Composite Applications
- SOA is all about composite applications -- Many reusable services aggregated into a service composition
Colorado Software Summit: October 21 – 26, 2007 © Copyright 2007, IONA Technologies
Bruce Snyder — Building a Service Oriented Architecture with the Apache ServiceMix ESB Slide 6
![Page 7: Building a Service Oriented Architecture with the Apache ... · Bruce Snyder Ñ Building a Service Oriented Architecture with the Apache ServiceMix ESB Slide 10 Java Business Integration](https://reader031.fdocuments.in/reader031/viewer/2022011903/5f135a60fd50066f7c4a0884/html5/thumbnails/7.jpg)
A Service Oriented Analogy
- Gated community in a home owners assoc.-- Provides services (grounds maintenance, cable TV, security, clubhouse w/ pool, etc.)-- Used by many people (consumers)-- HOA community is comprised of many owners-- Adherence to basic conventions--- HOA requirements --- Address on house--- Mailbox at end of driveway --- Pay dues!
Colorado Software Summit: October 21 – 26, 2007 © Copyright 2007, IONA Technologies
Bruce Snyder — Building a Service Oriented Architecture with the Apache ServiceMix ESB Slide 7
![Page 8: Building a Service Oriented Architecture with the Apache ... · Bruce Snyder Ñ Building a Service Oriented Architecture with the Apache ServiceMix ESB Slide 10 Java Business Integration](https://reader031.fdocuments.in/reader031/viewer/2022011903/5f135a60fd50066f7c4a0884/html5/thumbnails/8.jpg)
A story about skydiving...
- Michael Holmes - Top ten skydiver in the world- Member of the British skydiving team- Reigning New Zealand champion- 7,000+ jumps to his name- Aware of the risks of his career - Knows that panic-induced human error is to blame for almost all accidents
Colorado Software Summit: October 21 – 26, 2007 © Copyright 2007, IONA Technologies
Bruce Snyder — Building a Service Oriented Architecture with the Apache ServiceMix ESB Slide 8
![Page 9: Building a Service Oriented Architecture with the Apache ... · Bruce Snyder Ñ Building a Service Oriented Architecture with the Apache ServiceMix ESB Slide 10 Java Business Integration](https://reader031.fdocuments.in/reader031/viewer/2022011903/5f135a60fd50066f7c4a0884/html5/thumbnails/9.jpg)
“I didn’t have time to think about anything... really I was just angry that I’d done everything exactly as I should and it hadn’t worked.”
- Michael plummeted 12,000 ft. to a failed parachute
Colorado Software Summit: October 21 – 26, 2007 © Copyright 2007, IONA Technologies
Bruce Snyder — Building a Service Oriented Architecture with the Apache ServiceMix ESB Slide 9
![Page 10: Building a Service Oriented Architecture with the Apache ... · Bruce Snyder Ñ Building a Service Oriented Architecture with the Apache ServiceMix ESB Slide 10 Java Business Integration](https://reader031.fdocuments.in/reader031/viewer/2022011903/5f135a60fd50066f7c4a0884/html5/thumbnails/10.jpg)
There’s no substitute for experience and knowledge of human organizational behavior in terms of SOA
- People use their experience even if it doesn't apply to the current situation-- See Harwells Laws -- http://www.makingitclear.com/pages/harwellslaws.html
- Industry full of hope that is pinned on cookbook SOA methodologies -- There is no one-size-fits-all SOA recipe! --- Follow this recipe and you’ll be safe --- Go through the following 10 steps and your SOA will be a success.- You might end up being, “angry that you’d done everything exactly as you should and it still didn’t work!”
Colorado Software Summit: October 21 – 26, 2007 © Copyright 2007, IONA Technologies
Bruce Snyder — Building a Service Oriented Architecture with the Apache ServiceMix ESB Slide 10
![Page 11: Building a Service Oriented Architecture with the Apache ... · Bruce Snyder Ñ Building a Service Oriented Architecture with the Apache ServiceMix ESB Slide 10 Java Business Integration](https://reader031.fdocuments.in/reader031/viewer/2022011903/5f135a60fd50066f7c4a0884/html5/thumbnails/11.jpg)
Java Business Integration
- Standards based architecture for pluggable components in a reliable manner- Elimination of vendor lock-in - Provides a base for a service oriented architecture- JBI allows two types of plug-ins: -- Service Engines--- Provides functionality local to the NMR-- Binding Components--- Provides transports and protocols to communicate with services remote to the NMR --- Normalizes payload
Colorado Software Summit: October 21 – 26, 2007 © Copyright 2007, IONA Technologies
Bruce Snyder — Building a Service Oriented Architecture with the Apache ServiceMix ESB Slide 11
![Page 12: Building a Service Oriented Architecture with the Apache ... · Bruce Snyder Ñ Building a Service Oriented Architecture with the Apache ServiceMix ESB Slide 10 Java Business Integration](https://reader031.fdocuments.in/reader031/viewer/2022011903/5f135a60fd50066f7c4a0884/html5/thumbnails/12.jpg)
JBI Packaging
- Packaging for configurations of components-- Service Unit (SU)--- META-INF/jbi.xml-- Service Assembly (SA)--- META-INF/jbi.xml --Similar to WARs and EARs with Java EE - Each SU is like a little Spring application -- Including dependencies - Each SA is an outer package -- SUs listed as dependencies
Colorado Software Summit: October 21 – 26, 2007 © Copyright 2007, IONA Technologies
Bruce Snyder — Building a Service Oriented Architecture with the Apache ServiceMix ESB Slide 12
![Page 13: Building a Service Oriented Architecture with the Apache ... · Bruce Snyder Ñ Building a Service Oriented Architecture with the Apache ServiceMix ESB Slide 10 Java Business Integration](https://reader031.fdocuments.in/reader031/viewer/2022011903/5f135a60fd50066f7c4a0884/html5/thumbnails/13.jpg)
Apache ServiceMix
-- Apache License 2.0-- Combines SOA and Event Driven Architecture --- http://enterpriseintegrationpatterns.com/docs/EDA.pdf -- Built on Apache ActiveMQ-- Implements JBI and so much more! -- Connectivity centric-- Smart Routing capabilities-- It’s very flexible!
Colorado Software Summit: October 21 – 26, 2007 © Copyright 2007, IONA Technologies
Bruce Snyder — Building a Service Oriented Architecture with the Apache ServiceMix ESB Slide 13
![Page 14: Building a Service Oriented Architecture with the Apache ... · Bruce Snyder Ñ Building a Service Oriented Architecture with the Apache ServiceMix ESB Slide 10 Java Business Integration](https://reader031.fdocuments.in/reader031/viewer/2022011903/5f135a60fd50066f7c4a0884/html5/thumbnails/14.jpg)
Apache ServiceMix Architecture
Colorado Software Summit: October 21 – 26, 2007 © Copyright 2007, IONA Technologies
Bruce Snyder — Building a Service Oriented Architecture with the Apache ServiceMix ESB Slide 14
![Page 15: Building a Service Oriented Architecture with the Apache ... · Bruce Snyder Ñ Building a Service Oriented Architecture with the Apache ServiceMix ESB Slide 10 Java Business Integration](https://reader031.fdocuments.in/reader031/viewer/2022011903/5f135a60fd50066f7c4a0884/html5/thumbnails/15.jpg)
Configuration
(conf/servicemix.xml)
Colorado Software Summit: October 21 – 26, 2007 © Copyright 2007, IONA Technologies
Bruce Snyder — Building a Service Oriented Architecture with the Apache ServiceMix ESB Slide 15
![Page 16: Building a Service Oriented Architecture with the Apache ... · Bruce Snyder Ñ Building a Service Oriented Architecture with the Apache ServiceMix ESB Slide 10 Java Business Integration](https://reader031.fdocuments.in/reader031/viewer/2022011903/5f135a60fd50066f7c4a0884/html5/thumbnails/16.jpg)
Developing Integrations With ServiceMix Demo
Development demo using ServiceMix
Colorado Software Summit: October 21 – 26, 2007 © Copyright 2007, IONA Technologies
Bruce Snyder — Building a Service Oriented Architecture with the Apache ServiceMix ESB Slide 16
![Page 17: Building a Service Oriented Architecture with the Apache ... · Bruce Snyder Ñ Building a Service Oriented Architecture with the Apache ServiceMix ESB Slide 10 Java Business Integration](https://reader031.fdocuments.in/reader031/viewer/2022011903/5f135a60fd50066f7c4a0884/html5/thumbnails/17.jpg)
Visualization
Colorado Software Summit: October 21 – 26, 2007 © Copyright 2007, IONA Technologies
Bruce Snyder — Building a Service Oriented Architecture with the Apache ServiceMix ESB Slide 17
![Page 18: Building a Service Oriented Architecture with the Apache ... · Bruce Snyder Ñ Building a Service Oriented Architecture with the Apache ServiceMix ESB Slide 10 Java Business Integration](https://reader031.fdocuments.in/reader031/viewer/2022011903/5f135a60fd50066f7c4a0884/html5/thumbnails/18.jpg)
So What’s Coming in ServiceMix 4.0?
Framework: OSGi (Apache Felix)SOAP Support: Apache CXFMessage Broker: Apache ActiveMQRouting Engine: Apache Camel
Colorado Software Summit: October 21 – 26, 2007 © Copyright 2007, IONA Technologies
Bruce Snyder — Building a Service Oriented Architecture with the Apache ServiceMix ESB Slide 18
![Page 19: Building a Service Oriented Architecture with the Apache ... · Bruce Snyder Ñ Building a Service Oriented Architecture with the Apache ServiceMix ESB Slide 10 Java Business Integration](https://reader031.fdocuments.in/reader031/viewer/2022011903/5f135a60fd50066f7c4a0884/html5/thumbnails/19.jpg)
What is Apache Camel?
Colorado Software Summit: October 21 – 26, 2007 © Copyright 2007, IONA Technologies
Bruce Snyder — Building a Service Oriented Architecture with the Apache ServiceMix ESB Slide 19
![Page 20: Building a Service Oriented Architecture with the Apache ... · Bruce Snyder Ñ Building a Service Oriented Architecture with the Apache ServiceMix ESB Slide 10 Java Business Integration](https://reader031.fdocuments.in/reader031/viewer/2022011903/5f135a60fd50066f7c4a0884/html5/thumbnails/20.jpg)
What is EIP?
- The bible of integration patterns
Colorado Software Summit: October 21 – 26, 2007 © Copyright 2007, IONA Technologies
Bruce Snyder — Building a Service Oriented Architecture with the Apache ServiceMix ESB Slide 20
![Page 21: Building a Service Oriented Architecture with the Apache ... · Bruce Snyder Ñ Building a Service Oriented Architecture with the Apache ServiceMix ESB Slide 10 Java Business Integration](https://reader031.fdocuments.in/reader031/viewer/2022011903/5f135a60fd50066f7c4a0884/html5/thumbnails/21.jpg)
Example Pattern: Content Based Router
RouteBuilder builder = new RouteBuilder() { public void configure() { from("seda:a").choice().when(header("foo").isEqualTo("bar")).to("seda:b") .when(header("foo").isEqualTo("cheese")).to("seda:c").otherwise().to("seda:d"); }};
- The Java version of the Camel CBR
Colorado Software Summit: October 21 – 26, 2007 © Copyright 2007, IONA Technologies
Bruce Snyder — Building a Service Oriented Architecture with the Apache ServiceMix ESB Slide 21
![Page 22: Building a Service Oriented Architecture with the Apache ... · Bruce Snyder Ñ Building a Service Oriented Architecture with the Apache ServiceMix ESB Slide 10 Java Business Integration](https://reader031.fdocuments.in/reader031/viewer/2022011903/5f135a60fd50066f7c4a0884/html5/thumbnails/22.jpg)
Example Pattern: Content Based Router<camelContext id="buildSimpleRouteWithChoice" xmlns="http://activemq.apache.org/camel/schema/spring"> <route> <from uri="seda:a"/> <choice> <when> <predicate> <header name="foo"/> <isEqualTo value="bar"/> </predicate> <to uri="seda:b"/> </when> <when> <predicate> <header name="foo"/> <isEqualTo value="cheese"/> </predicate> <to uri="seda:c"/> </when> <otherwise><to uri="seda:d"/></otherwise> </choice> </route></camelContext>
- The XML version of the CBR
Colorado Software Summit: October 21 – 26, 2007 © Copyright 2007, IONA Technologies
Bruce Snyder — Building a Service Oriented Architecture with the Apache ServiceMix ESB Slide 22
![Page 23: Building a Service Oriented Architecture with the Apache ... · Bruce Snyder Ñ Building a Service Oriented Architecture with the Apache ServiceMix ESB Slide 10 Java Business Integration](https://reader031.fdocuments.in/reader031/viewer/2022011903/5f135a60fd50066f7c4a0884/html5/thumbnails/23.jpg)
Camel Makes Routing Much Easier!
from(“http://localhost:8080/requests/”). tryBlock(). to(“activemq:queue:requests”). setOutBody(constant(“<ack/>”)). handle(Throwable.class). setFaultBody(constant(“<nack/>”));
from((“activemq:queue:requests?transacted=true”). process(requestTransformer). to(“http://host:8080/Request”). filter(xpath(“//nack”)). process(nackTransformer). to(“jdbc:store”);
from(“http://localhost:8080/responses/”). tryBlock(). to(“activemq:queue:responses”). setOutBody(constant(“<ack/>”)). handle(Throwable.class). setFaultBody(constant(“<nack/>”));
from(“activemq:queue:responses?transacted=true”). process(responseTransformer). to(“jdbc:store”);
from(“http://localhost:8080/pull/”). to(“jdbc:load”);
- Message routing is much easier with Camel!
Colorado Software Summit: October 21 – 26, 2007 © Copyright 2007, IONA Technologies
Bruce Snyder — Building a Service Oriented Architecture with the Apache ServiceMix ESB Slide 23
![Page 24: Building a Service Oriented Architecture with the Apache ... · Bruce Snyder Ñ Building a Service Oriented Architecture with the Apache ServiceMix ESB Slide 10 Java Business Integration](https://reader031.fdocuments.in/reader031/viewer/2022011903/5f135a60fd50066f7c4a0884/html5/thumbnails/24.jpg)
Thank You for Attending
Please fill out your surveys
Colorado Software Summit: October 21 – 26, 2007 © Copyright 2007, IONA Technologies
Bruce Snyder — Building a Service Oriented Architecture with the Apache ServiceMix ESB Slide 24