SlideShare una empresa de Scribd logo
1 de 52
Integration of Apache Servicemix
               &Cxf
About Auther

   Fang Yue (Freeman Fang
    freeman.fang@gmail.com)
   Apache Cxf commiter and PMC member
   Apache Servicemix commiter and PMC
    member
useful link

   http://servicemix.apache.org
   http://cxf.apache.org
Agenda

   What is JBI?
   JBI 1.0 & Apache Servicemix 3.x
   CXF-BC & CXF-SE
   Apache Servicemix 4.0
What is JBI?

   JBI defines an architecture that allows the construction of integration systems
    from plug-in components, that interoperate through the method of mediated
    message exchange. (JBI 1.0 spec, JSR 208)
   Keywords: plugin, MEPS, NMR
What is JBI?
JBI 1.0: Architecture
JBI 1.0

   WSDL Messaging Model
   Component
   Normalized Message Router (NMR)
   Management
          Package
          Deployment
          Monitoring
JBI 1.0: WSDL messaging model


   Abstract model
   Concrete model

   Service providers
   Service consumers
JBI 1.0: WSDL messaging model


Message type
    Normal
    Faults
Operation
    Qualified name
    Message Exchange Pattern
    Message types
Interface
    Qualified name
    Operations
    Extended interfaces
JBI 1.0: WSDL messaging model


   Binding type
   Endpoint
     Endpoint name
     Binding type
   Service
     Qualified name
     Interface name
     Endpoints
a real wsdl-part 1
<wsdl:definitions name=quot;wsdl-firstquot;
    xmlns:wsdl=quot;http://schemas.xmlsoap.org/wsdl/quot;
    xmlns:soap=quot;http://schemas.xmlsoap.org/wsdl/soap/quot;
    xmlns:xsd=quot;http://www.w3.org/2001/XMLSchemaquot;
    xmlns:xsi=quot;http://www.w3.org/2001/XMLSchema-instancequot;
    xmlns:tns=quot;http://servicemix.apache.org/samples/wsdl-firstquot;
    xmlns:typens=quot;http://servicemix.apache.org/samples/wsdl-first/typesquot;
    targetNamespace=quot;http://servicemix.apache.org/samples/wsdl-firstquot;>

    <wsdl:types>
          <xsd:schema targetNamespace=quot;http://servicemix.apache.org/samples/wsdl-first/typesquot;
                  elementFormDefault=quot;qualifiedquot;>
               <xsd:element name=quot;GetPersonquot;>
                <xsd:complexType>
                          <xsd:sequence>
                               <xsd:element name=quot;personIdquot; type=quot;xsd:stringquot;/>
                          </xsd:sequence>
                     </xsd:complexType>
               </xsd:element>
               <xsd:element name=quot;GetPersonResponsequot;>
                <xsd:complexType>
                          <xsd:sequence>
                             <xsd:element name=quot;personIdquot; type=quot;xsd:stringquot;/>
                               <xsd:element name=quot;ssnquot; type=quot;xsd:stringquot;/>
                               <xsd:element name=quot;namequot; type=quot;xsd:stringquot;/>
                          </xsd:sequence>
                     </xsd:complexType>
               </xsd:element>
               <xsd:element name=quot;UnknownPersonFaultquot;>
                <xsd:complexType>
                          <xsd:sequence>
                             <xsd:element name=quot;personIdquot; type=quot;xsd:stringquot;/>
                          </xsd:sequence>
                     </xsd:complexType>
               </xsd:element>
          </xsd:schema>
 </wsdl:types>
a real wsdl – part 2

     <wsdl:message name=quot;GetPersonRequestquot;>
         <wsdl:part name=quot;payloadquot; element=quot;typens:GetPersonquot;/>
     </wsdl:message>
     <wsdl:message name=quot;GetPersonResponsequot;>
         <wsdl:part name=quot;payloadquot; element=quot;typens:GetPersonResponsequot;/>
     </wsdl:message>
     <wsdl:message name=quot;UnknownPersonFaultquot;>
         <wsdl:part name=quot;payloadquot; element=quot;typens:UnknownPersonFaultquot;/>
     </wsdl:message>

  <wsdl:portType name=quot;Personquot;>
         <wsdl:operation name=quot;GetPersonquot;>
              <wsdl:input message=quot;tns:GetPersonRequestquot;/>
              <wsdl:output message=quot;tns:GetPersonResponsequot;/>
              <wsdl:fault name=quot;UnknownPersonquot; message=quot;tns:UnknownPersonFaultquot;/>
         </wsdl:operation>
    </wsdl:portType>

 <wsdl:binding name=quot;PersonSOAPBindingquot; type=quot;tns:Personquot;>
    <soap:binding style=quot;documentquot; transport=quot;http://schemas.xmlsoap.org/soap/httpquot; />
         <wsdl:operation name=quot;GetPersonquot;>
              <wsdl:input>
                   <soap:body use=quot;literalquot; />
              </wsdl:input>
              <wsdl:output>
                   <soap:body use=quot;literalquot; />
              </wsdl:output>
              <wsdl:fault name=quot;UnknownPersonquot;>
                   <soap:fault use=quot;literalquot; name=quot;UnknownPersonquot; />
              </wsdl:fault>
   </wsdl:operation>
 </wsdl:binding>

    <wsdl:service name=quot;PersonServicequot;>
    <wsdl:port binding=quot;tns:PersonSOAPBindingquot; name=quot;soapquot;>
     <soap:address location=quot;http://localhost:8092/PersonService/quot; />
   </wsdl:port>
 </wsdl:service>

</wsdl:definitions>
Java interface


@WebService(targetNamespace = quot;http://servicemix.apache.org/samples/wsdl-firstquot;, name = quot;Personquot;)

public interface Person {

    @ResponseWrapper(localName = quot;GetPersonResponsequot;, targetNamespace = quot;http://servicemix.apache.org/samples/wsdl-
first/typesquot;, className = quot;org.apache.servicemix.samples.wsdl_first.types.GetPersonResponsequot;)
    @RequestWrapper(localName = quot;GetPersonquot;, targetNamespace = quot;http://servicemix.apache.org/samples/wsdl-first/typesquot;,
className = quot;org.apache.servicemix.samples.wsdl_first.types.GetPersonquot;)
    @WebMethod(operationName = quot;GetPersonquot;)
    public void getPerson(
       @WebParam(mode = WebParam.Mode.INOUT, name = quot;personIdquot;, targetNamespace = quot;http://servicemix.apache.org/samples/
wsdl-first/typesquot;)
       javax.xml.ws.Holder<java.lang.String> personId,
       @WebParam(mode = WebParam.Mode.OUT, name = quot;ssnquot;, targetNamespace = quot;http://servicemix.apache.org/samples/wsdl-
first/typesquot;)
       javax.xml.ws.Holder<java.lang.String> ssn,
       @WebParam(mode = WebParam.Mode.OUT, name = quot;namequot;, targetNamespace = quot;http://servicemix.apache.org/samples/wsdl-
first/typesquot;)
       javax.xml.ws.Holder<java.lang.String> name
    ) throws UnknownPersonFault;
}
Component
   Binding Component
            To communicate using remote protocols
            To normalize/denormalize messages it receives
            Examples:
                  servicemix-file
                  servicemix-ftp
                  servicemix-cxf-bc
   Service Engine
            A service engine (SE) provides some type of logic inside the JBI environment and only
             communicates with the NMR.
            Examples:
                  servicemix-bean
                  servicemix-camel
                  servicemix-cxf-se
Nomarlized Message Router

   Consumer & Provider
   Normalized Message
   Delivery Channel
   Message Exchange Pattern (MEP)
   Endpoints
   Run-time Endpoint Activation
Normalized Message Router

The Normalized Message Router (or NMR) receives message exchanges from JBI
components and routes them to the appropriate component for processing. This
decouples the service producers from consumers and enable additional processing.
Provider & Consumer

   WSDL Description
   Abstract Model
   Decoupled
Message Normalization

   Message normalization/denormalization is the act of converting a message from/
    to a protocol-specific format into a format for the JBI environment. This
    normalization is performed by BCs involves converting all messages into a
    NormalizedMessage.
   A Normalized Message consist of following:
             The “payload”, or bare message: an XML document that conforms to an
              abstract WSDL message type.
             Message properties (sometime called metadata). These hold extra data
              associated with the message, key-value
             Attachments: Extra (generally binary) attachments to the main message
              object.
what NMR looks like

id: ID:127.0.0.1-11761bd912f-8:0
  status: Active
  role: provider
  service: {http://apache.org/cxf/calculator}CalculatorService
  endpoint: CalculatorPort
  operation: {http://apache.org/cxf/calculator}add
  in: <?xml version=quot;1.0quot; encoding=quot;UTF-8quot;?><message
xmlns=quot;http://java.sun.com/xml/ns/jbi/wsdl-11-wrapperquot;> <part>      <add
xmlns=quot;http://apache.org/cxf/calculator/typesquot;>      <arg0>1</arg0>
<arg1>2</arg1>    </add> </part></message>
Delivery Channel

A Delivery Channel is a bidirectional asynchronous communication pipes between a
component and the NMR.
A service consumer uses its delivery channel to initiate a service invocation, while
the provider uses its delivery channel to receive such invocations.
Each component is provided with a single delivery channel, so the same channel is
used for both inbound and outbound communications.
Message Exchange Pattern
   In-Only: consumer issues a request to provider with no error (fault) path provided
   Robust In-Only: consumer issues a request to provider. Provider may respond with a
    fault if it fails to process request.
   In-Out: consumer issues a request to provider, with expectation of response. Provider
    may respond with a fault if it fails to process request.
   In-Optional-Out: consumer issues a request to provider, which may result in a
    response. Consumer and provider both have the option of generating a fault in
    response to a message received during the interaction
In-Only MEP
Robust In-Only MEP
In-Out MEP
In-Optional-Out MEP
Endpoints

JBI uses the same concept of endpoints as defined in WSDL 2.0.
Endpoints refers to a particular address, accessible by a particular protocol, used to
access a particular service.

Endpoints have two distinct types:

    External
               External endpoints are endpoints outside the JBI environment. They are endpoints
                exposed by binding component acting as service consumers to expose an internal
                endpoint for the use of external service consumers
    Internal
               Internal endpoints are exposed by service providers inside the JBI environment. They
                are accessed using the NMR APIs.
Addressing

In JBI, endpoints are referred to (or addressed) in three distinct ways:
  ●   Implicitly: the NMR selects the endpoint based on the service type required.
  ●   Explicitly: a consumer chooses the endpoint based on its own logic and
      configuration.
  ●   Dynamically: an endpoint reference (EPR) is used within a message exchange to
      provide a “ call-back” address that the service provider should use to send further
      message exchanges. EPRs are xml fragment created and resolved by JBI
      components.
JBI Management

It is JMX-based.
     JBI Package.
     Install & Deploy
     ClassLoader
JBI Package
   JBI defines a standard packaging for installing new components and deploying
    artifacts onto these components that can function as quot;containersquot;.All these artifacts
    contain a JBI descriptor in the META-INF directory called jbi.xml.
   There are four types of artifacts, all packaged as zip or jar files:
        Components installers contain the libraries and resources needed to run the component.
         Components can references Shared Libraries.
        Shared Libraries are collection of jars that can be shared by several components
        Service Units are artifacts meant to be deployed to a specific component. Aside from the
         JBI descriptor, the service unit packaging is specific to a component and can take various
         forms: a single XSLT style sheet, a BPEL process, or some java classes ...
        Service assemblies are collections of Service Units. Service units can not be deployed
         directly and must be packaged in a service assembly which contains the service units and
         associated metadata.
Shared Lib

<?xml version=quot;1.0quot; encoding=quot;UTF-8quot;?>
<jbi xmlns=quot;http://java.sun.com/xml/ns/jbiquot; version=quot;1.0quot;>
 <shared-library class-loader-delegation=quot;parent-firstquot; version=quot;3.2.4-SNAPSHOTquot;>
   <identification>
    <name>servicemix-shared</name>
    <description>ServiceMix :: Shared</description>
   </identification>
   <shared-library-class-path>
    <path-element>lib/servicemix-shared-3.2.4-SNAPSHOT.jar</path-element>
    <path-element>lib/servicemix-common-3.2.4-SNAPSHOT.jar</path-element>
    <path-element>lib/servicemix-soap-3.2.4-SNAPSHOT.jar</path-element>
    <path-element>lib/bcprov-jdk14-136.jar</path-element>
    <path-element>lib/opensaml-1.1.jar</path-element>
    <path-element>lib/xmlsec-1.3.0.jar</path-element>
    <path-element>lib/servicemix-soap2-3.2.4-SNAPSHOT.jar</path-element>
    <path-element>lib/wss4j-1.5.4.jar</path-element>
    <path-element>lib/commons-logging-1.1.jar</path-element>
    <path-element>lib/xmlsec-1.4.0.jar</path-element>
    <path-element>lib/opensaml-1.1.jar</path-element>
    <path-element>lib/axis-ant-1.4.jar</path-element>
    <path-element>lib/xml-apis-1.3.04.jar</path-element>
    <path-element>lib/xercesImpl-2.8.1.jar</path-element>
    <path-element>lib/bcprov-jdk15-132.jar</path-element>
    <path-element>lib/XmlSchema-1.3.2.jar</path-element>
    <path-element>lib/woden-1.0.0M6.jar</path-element>
   </shared-library-class-path>
 </shared-library>
</jbi>
component

<?xml version=quot;1.0quot; encoding=quot;UTF-8quot;?>
<jbi xmlns=quot;http://java.sun.com/xml/ns/jbiquot; version=quot;1.0quot;>
 <component type=quot;binding-componentquot; component-class-loader-delegation=quot;parent-firstquot; bootstrap-class-loader-delegation=quot;parent-firstquot;>
   <identification>
    <name>servicemix-file</name>
    <description>ServiceMix :: File</description>
   </identification>
   <component-class-name>org.apache.servicemix.file.FileComponent</component-class-name>
   <component-class-path>
    <path-element>lib/servicemix-file-3.2.4-SNAPSHOT.jar</path-element>
    <path-element>lib/commons-logging-1.1.jar</path-element>
    <path-element>lib/xercesImpl-2.8.1.jar</path-element>
    <path-element>lib/xml-apis-1.3.04.jar</path-element>
    <path-element>lib/log4j-1.2.13.jar</path-element>
   </component-class-path>
   <bootstrap-class-name>org.apache.servicemix.common.DefaultBootstrap</bootstrap-class-name>
   <bootstrap-class-path>
    <path-element>lib/servicemix-file-3.2.4-SNAPSHOT.jar</path-element>
    <path-element>lib/commons-logging-1.1.jar</path-element>
    <path-element>lib/xercesImpl-2.8.1.jar</path-element>
    <path-element>lib/xml-apis-1.3.04.jar</path-element>
    <path-element>lib/log4j-1.2.13.jar</path-element>
   </bootstrap-class-path>
   <shared-library version=quot;3.2.4-SNAPSHOTquot;>servicemix-shared</shared-library>
 </component>
</jbi>
service assembly

<?xml version=quot;1.0quot; encoding=quot;UTF-8quot;?>
<jbi xmlns=quot;http://java.sun.com/xml/ns/jbiquot; version=quot;1.0quot;>
 <service-assembly>
   <identification>
     <name>wsdl-first-cxf-sa</name>
     <description>ServiceMix :: Samples :: WSDL first :: SA</description>
   </identification>
   <service-unit>
     <identification>
      <name>wsdl-first-cxfse-su</name>
      <description>ServiceMix is an open source ESB based on the Java Business
   Integration framework - JSR-208</description>
     </identification>
     <target>
      <artifacts-zip>wsdl-first-cxfse-su-3.3.zip</artifacts-zip>
      <component-name>servicemix-cxf-se</component-name>
     </target>
   </service-unit>
   <service-unit>
     <identification>
      <name>wsdl-first-cxfbc-su</name>
      <description>ServiceMix is an open source ESB based on the Java Business
   Integration framework - JSR-208</description>
     </identification>
     <target>
      <artifacts-zip>wsdl-first-cxfbc-su-3.3.zip</artifacts-zip>
      <component-name>servicemix-cxf-bc</component-name>
     </target>
   </service-unit>
 </service-assembly>
</jbi>
Package Install & Deploy

   For the shared library & component, it is called installation
   For the service assembly, it is called deployment
   In general, Container Developer (like us) write the component, Application
    Developer write the serivce unit and service assembly.
ClassLoader
   There are several classloaders involved in ServiceMix:
        the container class loader.
        shared library class loader: the parent is the container class loader.
        component class loader: parents are container class loader + any referenced SL
         class loader.
        service unit class loader: parent is the component class loader.
   Two kinds of classloader algorithm.
        parent-first. (by default)
        self-first.
CXF-BC & CXF-SE

   why we integrate cxf into servicemix?
   what's the key components for this integration?
Cxf BC

   cxf bc consumer
   cxf bc provider
   http support
   https support
   jms support
   ws-* support
cxf bc endpoint configuration


<cxfbc:consumer wsdl=quot;/wsdl/calculator.wsdlquot;
            service=quot;calculator:CalculatorServicequot;
            endpoint=quot;CalculatorPortquot;
            targetEndpoint=quot;CalculatorPortProxyquot;
            targetService=quot;calculator:CalculatorServicequot;
            targetInterface=quot;calculator:CalculatorPortTypequot;>

   </cxfbc:consumer>
<cxfbc:provider wsdl=quot;/wsdl/calculator.wsdlquot;
             locationURI=quot;http://localhost:9001/bridgetestquot;
             service=quot;calculator:CalculatorServicequot;
             endpoint=quot;CalculatorPortProxyquot;
             interfaceName=quot;calculator:CalculatorPortTypequot;
             >
   </cxfbc:provider>
Cxf SE

   jax-ws frontend
   simple frontend
   jaxb databinding
   aegis databinding
   MTOM support
   client proxy
Cxf SE configuration

<cxfse:endpoint>
     <cxfse:pojo>
      <bean class=quot;org.apache.cxf.calculator.CalculatorImplquot;>
      </bean>

     </cxfse:pojo>
     <cxfse:inInterceptors>
      <bean class=quot;org.apache.cxf.interceptor.LoggingInInterceptorquot;/>
     </cxfse:inInterceptors>
     <cxfse:outInterceptors>
      <bean class=quot;org.apache.cxf.interceptor.LoggingOutInterceptorquot;/>
     </cxfse:outInterceptors>
</cxfse:endpoint>

<cxfse:endpoint>
 <cxfse:pojo>
   <bean class=quot;org.apache.servicemix.cxfse.GreeterImplForClientProxyquot;>
    <property name=quot;calculatorquot;>
      <cxfse:proxy service=quot;calculator:CalculatorServicequot; context=quot;#contextquot; type=quot;org.apache.cxf.calculator.CalculatorPortTypequot; />
    </property>
   </bean>
</cxfse:pojo>
</cxfse:endpoint>
typical scenario




    external client<==>cxf bc cosumer<==NMR==>cxf se endpoint
                                  or
client proxy in cxf se<==NMR==>cxf bc provider<===>external server
JBI binding & JBI transport

   src code is in cxf code base
   JBI binding is responsible for the
    Marshalling/Unmarshalling
   JBI transport is reponsible for receiving and
    sending message using JBI api
Soap Message VS JBI Message


<soap:Envelope xmlns:soap=quot;http://www.w3.org/2003/05/soap-envelopequot;>
   <soap:Body>
      <add xmlns=quot;http://apache.org/cxf/calculator/typesquot;>
        <arg0>1</arg0>
        <arg1>2</arg1>
      </add>
   </soap:Body>
</soap:Envelope>



<jbi:message xmlns:jbi=quot;http://java.sun.com/xml/ns/jbi/wsdl-11-wrapperquot; xmlns:msg=quot;http://apache.org/cxf/calculatorquot; name=quot;addquot;
type=quot;msg:addquot; version=quot;1.0quot;>
   <jbi:part>
      <add xmlns=quot;http://apache.org/cxf/calculator/typesquot;>
         <arg0>1</arg0>
         <arg1>2</arg1>
      </add>
   </jbi:part>
</jbi:message>
JBI 1.0: Lesson Learned

   Pros
          Normalized exchanges
          Normalized Message Router

   Cons
          Classloader architecture. (jar version conflict issue)
          JBI packaging. (too complicated)
          Writing components is complex.
Servicemix 4.0

   Goal
   runtime
   building blocks
Servicemix 4.0 : Goal

   Enterprise OSGi Container
   Lightweight
   ESB and SOA container
   Ease of use
SMX4.0: Ease of Use

   No more components.
            Deployment / Classloader is delegated to OSGi.
   Bundles as the packaging and extension mechanism.
            Leverage OSGi architecture.
            Leverage spring-osgi (optionally)
   Endpoints as first-class citizens
            Endpoint are activated when registered in the OSGi registry.
            Channel is now on the Endpoint.
            Endpoints use push delivery rather than pulling the channel.
SMX4.0: Runtime

   Hot deployment of OSGi bundles.
   Dynamic reloadable configuration.
   Extensible Shell console(Gshell).
   Remote access.
   Running multiple instances.
building blocks

   avoid reinventing the wheel
    Framework: OSGi (Apache Felix)
    SOAP support: Apache CXF
    JMS broker: Apache ActiveMQ
    Routing Engine: Apache Camel
Moreover




Any kind of contribution is welcome!!!
More on Camel??

   please refer to Willem's Ride on Camel
Questions?

Más contenido relacionado

La actualidad más candente

[DSBW Spring 2009] Unit 07: WebApp Design Patterns & Frameworks (3/3)
[DSBW Spring 2009] Unit 07: WebApp Design Patterns & Frameworks (3/3)[DSBW Spring 2009] Unit 07: WebApp Design Patterns & Frameworks (3/3)
[DSBW Spring 2009] Unit 07: WebApp Design Patterns & Frameworks (3/3)Carles Farré
 
Building an api using golang and postgre sql v1.0
Building an api using golang and postgre sql v1.0Building an api using golang and postgre sql v1.0
Building an api using golang and postgre sql v1.0Frost
 
SHARE & the Semantic Web — This Time it's Personal
SHARE & the Semantic Web — This Time it's PersonalSHARE & the Semantic Web — This Time it's Personal
SHARE & the Semantic Web — This Time it's PersonalLuke McCarthy
 
Introduction to AJAX and DWR
Introduction to AJAX and DWRIntroduction to AJAX and DWR
Introduction to AJAX and DWRSweNz FixEd
 
Stop the noise! - Introduction to the JSON:API specification in Drupal
Stop the noise! - Introduction to the JSON:API specification in DrupalStop the noise! - Introduction to the JSON:API specification in Drupal
Stop the noise! - Introduction to the JSON:API specification in DrupalBjörn Brala
 
Introduction to JavaScript Programming
Introduction to JavaScript ProgrammingIntroduction to JavaScript Programming
Introduction to JavaScript ProgrammingRaveendra R
 
[PyConZA 2017] Web Scraping: Unleash your Internet Viking
[PyConZA 2017] Web Scraping: Unleash your Internet Viking[PyConZA 2017] Web Scraping: Unleash your Internet Viking
[PyConZA 2017] Web Scraping: Unleash your Internet VikingAndrew Collier
 
Grails custom tag lib
Grails custom tag libGrails custom tag lib
Grails custom tag libVijay Shukla
 
JavaScript - Chapter 9 - TypeConversion and Regular Expressions
 JavaScript - Chapter 9 - TypeConversion and Regular Expressions  JavaScript - Chapter 9 - TypeConversion and Regular Expressions
JavaScript - Chapter 9 - TypeConversion and Regular Expressions WebStackAcademy
 
Javascript Templating
Javascript TemplatingJavascript Templating
Javascript Templatingbcruhl
 
JavaScript - Chapter 4 - Types and Statements
 JavaScript - Chapter 4 - Types and Statements JavaScript - Chapter 4 - Types and Statements
JavaScript - Chapter 4 - Types and StatementsWebStackAcademy
 
Internet and Web Technology (CLASS-9) [React.js] | NIC/NIELIT Web Technology
Internet and Web Technology (CLASS-9) [React.js] | NIC/NIELIT Web TechnologyInternet and Web Technology (CLASS-9) [React.js] | NIC/NIELIT Web Technology
Internet and Web Technology (CLASS-9) [React.js] | NIC/NIELIT Web TechnologyAyes Chinmay
 
JavaScript - Chapter 10 - Strings and Arrays
 JavaScript - Chapter 10 - Strings and Arrays JavaScript - Chapter 10 - Strings and Arrays
JavaScript - Chapter 10 - Strings and ArraysWebStackAcademy
 
Intro to Javascript
Intro to JavascriptIntro to Javascript
Intro to JavascriptAnjan Banda
 

La actualidad más candente (20)

[DSBW Spring 2009] Unit 07: WebApp Design Patterns & Frameworks (3/3)
[DSBW Spring 2009] Unit 07: WebApp Design Patterns & Frameworks (3/3)[DSBW Spring 2009] Unit 07: WebApp Design Patterns & Frameworks (3/3)
[DSBW Spring 2009] Unit 07: WebApp Design Patterns & Frameworks (3/3)
 
Java script
Java scriptJava script
Java script
 
Building an api using golang and postgre sql v1.0
Building an api using golang and postgre sql v1.0Building an api using golang and postgre sql v1.0
Building an api using golang and postgre sql v1.0
 
my test
my testmy test
my test
 
SHARE & the Semantic Web — This Time it's Personal
SHARE & the Semantic Web — This Time it's PersonalSHARE & the Semantic Web — This Time it's Personal
SHARE & the Semantic Web — This Time it's Personal
 
Introduction to AJAX and DWR
Introduction to AJAX and DWRIntroduction to AJAX and DWR
Introduction to AJAX and DWR
 
Javascript 101
Javascript 101Javascript 101
Javascript 101
 
Session 3 Java Script
Session 3 Java ScriptSession 3 Java Script
Session 3 Java Script
 
Stop the noise! - Introduction to the JSON:API specification in Drupal
Stop the noise! - Introduction to the JSON:API specification in DrupalStop the noise! - Introduction to the JSON:API specification in Drupal
Stop the noise! - Introduction to the JSON:API specification in Drupal
 
Introduction to JavaScript Programming
Introduction to JavaScript ProgrammingIntroduction to JavaScript Programming
Introduction to JavaScript Programming
 
[PyConZA 2017] Web Scraping: Unleash your Internet Viking
[PyConZA 2017] Web Scraping: Unleash your Internet Viking[PyConZA 2017] Web Scraping: Unleash your Internet Viking
[PyConZA 2017] Web Scraping: Unleash your Internet Viking
 
Grails custom tag lib
Grails custom tag libGrails custom tag lib
Grails custom tag lib
 
JavaScript - Chapter 9 - TypeConversion and Regular Expressions
 JavaScript - Chapter 9 - TypeConversion and Regular Expressions  JavaScript - Chapter 9 - TypeConversion and Regular Expressions
JavaScript - Chapter 9 - TypeConversion and Regular Expressions
 
Javascript Templating
Javascript TemplatingJavascript Templating
Javascript Templating
 
JavaScript - Chapter 4 - Types and Statements
 JavaScript - Chapter 4 - Types and Statements JavaScript - Chapter 4 - Types and Statements
JavaScript - Chapter 4 - Types and Statements
 
Internet and Web Technology (CLASS-9) [React.js] | NIC/NIELIT Web Technology
Internet and Web Technology (CLASS-9) [React.js] | NIC/NIELIT Web TechnologyInternet and Web Technology (CLASS-9) [React.js] | NIC/NIELIT Web Technology
Internet and Web Technology (CLASS-9) [React.js] | NIC/NIELIT Web Technology
 
Scripting The Dom
Scripting The DomScripting The Dom
Scripting The Dom
 
JavaScript - Chapter 10 - Strings and Arrays
 JavaScript - Chapter 10 - Strings and Arrays JavaScript - Chapter 10 - Strings and Arrays
JavaScript - Chapter 10 - Strings and Arrays
 
Intro to Javascript
Intro to JavascriptIntro to Javascript
Intro to Javascript
 
Client Side Technologies
Client Side TechnologiesClient Side Technologies
Client Side Technologies
 

Destacado

Destacado (9)

Annie leibovitz muneretti
Annie leibovitz  munerettiAnnie leibovitz  muneretti
Annie leibovitz muneretti
 
Apachemeetupbeijingintro
ApachemeetupbeijingintroApachemeetupbeijingintro
Apachemeetupbeijingintro
 
Performanta Retele
Performanta RetelePerformanta Retele
Performanta Retele
 
Open Solaris Apache
Open Solaris ApacheOpen Solaris Apache
Open Solaris Apache
 
P Point Henry Moore
P Point Henry MooreP Point Henry Moore
P Point Henry Moore
 
Henry Lartigue. Sheila Álvaro i Marina Gálvez
Henry Lartigue. Sheila Álvaro i Marina GálvezHenry Lartigue. Sheila Álvaro i Marina Gálvez
Henry Lartigue. Sheila Álvaro i Marina Gálvez
 
Formació Web 2.0
Formació Web 2.0Formació Web 2.0
Formació Web 2.0
 
Certamen de les arts 2010. 1r BAT
Certamen de les arts 2010. 1r BATCertamen de les arts 2010. 1r BAT
Certamen de les arts 2010. 1r BAT
 
ROBERT CAPA
ROBERT CAPAROBERT CAPA
ROBERT CAPA
 

Similar a Apache Servicemix & CXF Integration

Service Oriented Integration With ServiceMix
Service Oriented Integration With ServiceMixService Oriented Integration With ServiceMix
Service Oriented Integration With ServiceMixBruce Snyder
 
Devclub Servicemix Jevgeni Holodkov 23 04 09
Devclub Servicemix Jevgeni Holodkov 23 04 09Devclub Servicemix Jevgeni Holodkov 23 04 09
Devclub Servicemix Jevgeni Holodkov 23 04 09helggeist
 
Web Services Part 2
Web Services Part 2Web Services Part 2
Web Services Part 2patinijava
 
Zero One Or Many Namespaces
Zero One Or Many NamespacesZero One Or Many Namespaces
Zero One Or Many NamespacesLiquidHub
 
Improving Soap Message Serialization
Improving Soap Message SerializationImproving Soap Message Serialization
Improving Soap Message SerializationPrabath Siriwardena
 
Architecting Web Services
Architecting Web ServicesArchitecting Web Services
Architecting Web ServicesLorna Mitchell
 
Struts2
Struts2Struts2
Struts2yuvalb
 
Interoperable Web Services with JAX-WS
Interoperable Web Services with JAX-WSInteroperable Web Services with JAX-WS
Interoperable Web Services with JAX-WSCarol McDonald
 
Boston Computing Review - Java Server Pages
Boston Computing Review - Java Server PagesBoston Computing Review - Java Server Pages
Boston Computing Review - Java Server PagesJohn Brunswick
 
Orbitz and Spring Webflow Case Study
Orbitz and Spring Webflow Case StudyOrbitz and Spring Webflow Case Study
Orbitz and Spring Webflow Case StudyMark Meeker
 
Hide Versus Expose
Hide Versus ExposeHide Versus Expose
Hide Versus ExposeLiquidHub
 
IBM Lotus Notes Domino XPages and XPages for Mobile
IBM Lotus Notes Domino XPages and XPages for MobileIBM Lotus Notes Domino XPages and XPages for Mobile
IBM Lotus Notes Domino XPages and XPages for MobileChris Toohey
 
Javazone 2010-lift-framework-public
Javazone 2010-lift-framework-publicJavazone 2010-lift-framework-public
Javazone 2010-lift-framework-publicTimothy Perrett
 
IQPC Canada XML 2001: How to Use XML Parsing to Enhance Electronic Communication
IQPC Canada XML 2001: How to Use XML Parsing to Enhance Electronic CommunicationIQPC Canada XML 2001: How to Use XML Parsing to Enhance Electronic Communication
IQPC Canada XML 2001: How to Use XML Parsing to Enhance Electronic CommunicationTed Leung
 

Similar a Apache Servicemix & CXF Integration (20)

Service Oriented Integration With ServiceMix
Service Oriented Integration With ServiceMixService Oriented Integration With ServiceMix
Service Oriented Integration With ServiceMix
 
Devclub Servicemix Jevgeni Holodkov 23 04 09
Devclub Servicemix Jevgeni Holodkov 23 04 09Devclub Servicemix Jevgeni Holodkov 23 04 09
Devclub Servicemix Jevgeni Holodkov 23 04 09
 
Web Services Part 2
Web Services Part 2Web Services Part 2
Web Services Part 2
 
WordPress APIs
WordPress APIsWordPress APIs
WordPress APIs
 
Jsp
JspJsp
Jsp
 
Zero One Or Many Namespaces
Zero One Or Many NamespacesZero One Or Many Namespaces
Zero One Or Many Namespaces
 
Improving Soap Message Serialization
Improving Soap Message SerializationImproving Soap Message Serialization
Improving Soap Message Serialization
 
Architecting Web Services
Architecting Web ServicesArchitecting Web Services
Architecting Web Services
 
Struts2
Struts2Struts2
Struts2
 
Interoperable Web Services with JAX-WS
Interoperable Web Services with JAX-WSInteroperable Web Services with JAX-WS
Interoperable Web Services with JAX-WS
 
I Feel Pretty
I Feel PrettyI Feel Pretty
I Feel Pretty
 
Boston Computing Review - Java Server Pages
Boston Computing Review - Java Server PagesBoston Computing Review - Java Server Pages
Boston Computing Review - Java Server Pages
 
Orbitz and Spring Webflow Case Study
Orbitz and Spring Webflow Case StudyOrbitz and Spring Webflow Case Study
Orbitz and Spring Webflow Case Study
 
Riding Apache Camel
Riding Apache CamelRiding Apache Camel
Riding Apache Camel
 
Ajax ons2
Ajax ons2Ajax ons2
Ajax ons2
 
Hide Versus Expose
Hide Versus ExposeHide Versus Expose
Hide Versus Expose
 
REST dojo Comet
REST dojo CometREST dojo Comet
REST dojo Comet
 
IBM Lotus Notes Domino XPages and XPages for Mobile
IBM Lotus Notes Domino XPages and XPages for MobileIBM Lotus Notes Domino XPages and XPages for Mobile
IBM Lotus Notes Domino XPages and XPages for Mobile
 
Javazone 2010-lift-framework-public
Javazone 2010-lift-framework-publicJavazone 2010-lift-framework-public
Javazone 2010-lift-framework-public
 
IQPC Canada XML 2001: How to Use XML Parsing to Enhance Electronic Communication
IQPC Canada XML 2001: How to Use XML Parsing to Enhance Electronic CommunicationIQPC Canada XML 2001: How to Use XML Parsing to Enhance Electronic Communication
IQPC Canada XML 2001: How to Use XML Parsing to Enhance Electronic Communication
 

Último

Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 3652toLead Limited
 
The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024Rafal Los
 
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmaticsKotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmaticscarlostorres15106
 
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...Patryk Bandurski
 
Swan(sea) Song – personal research during my six years at Swansea ... and bey...
Swan(sea) Song – personal research during my six years at Swansea ... and bey...Swan(sea) Song – personal research during my six years at Swansea ... and bey...
Swan(sea) Song – personal research during my six years at Swansea ... and bey...Alan Dix
 
Breaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountBreaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountPuma Security, LLC
 
Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101Paola De la Torre
 
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptxHampshireHUG
 
How to Remove Document Management Hurdles with X-Docs?
How to Remove Document Management Hurdles with X-Docs?How to Remove Document Management Hurdles with X-Docs?
How to Remove Document Management Hurdles with X-Docs?XfilesPro
 
Pigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food ManufacturingPigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food ManufacturingPigging Solutions
 
Benefits Of Flutter Compared To Other Frameworks
Benefits Of Flutter Compared To Other FrameworksBenefits Of Flutter Compared To Other Frameworks
Benefits Of Flutter Compared To Other FrameworksSoftradix Technologies
 
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking MenDelhi Call girls
 
Key Features Of Token Development (1).pptx
Key  Features Of Token  Development (1).pptxKey  Features Of Token  Development (1).pptx
Key Features Of Token Development (1).pptxLBM Solutions
 
AI as an Interface for Commercial Buildings
AI as an Interface for Commercial BuildingsAI as an Interface for Commercial Buildings
AI as an Interface for Commercial BuildingsMemoori
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerThousandEyes
 
[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdfhans926745
 
Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)Allon Mureinik
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationRadu Cotescu
 
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure serviceWhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure servicePooja Nehwal
 
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...shyamraj55
 

Último (20)

Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
 
The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024
 
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmaticsKotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
 
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
 
Swan(sea) Song – personal research during my six years at Swansea ... and bey...
Swan(sea) Song – personal research during my six years at Swansea ... and bey...Swan(sea) Song – personal research during my six years at Swansea ... and bey...
Swan(sea) Song – personal research during my six years at Swansea ... and bey...
 
Breaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountBreaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path Mount
 
Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101
 
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
 
How to Remove Document Management Hurdles with X-Docs?
How to Remove Document Management Hurdles with X-Docs?How to Remove Document Management Hurdles with X-Docs?
How to Remove Document Management Hurdles with X-Docs?
 
Pigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food ManufacturingPigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food Manufacturing
 
Benefits Of Flutter Compared To Other Frameworks
Benefits Of Flutter Compared To Other FrameworksBenefits Of Flutter Compared To Other Frameworks
Benefits Of Flutter Compared To Other Frameworks
 
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
 
Key Features Of Token Development (1).pptx
Key  Features Of Token  Development (1).pptxKey  Features Of Token  Development (1).pptx
Key Features Of Token Development (1).pptx
 
AI as an Interface for Commercial Buildings
AI as an Interface for Commercial BuildingsAI as an Interface for Commercial Buildings
AI as an Interface for Commercial Buildings
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf
 
Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organization
 
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure serviceWhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
 
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
 

Apache Servicemix & CXF Integration

  • 1. Integration of Apache Servicemix &Cxf
  • 2. About Auther  Fang Yue (Freeman Fang freeman.fang@gmail.com)  Apache Cxf commiter and PMC member  Apache Servicemix commiter and PMC member
  • 3. useful link  http://servicemix.apache.org  http://cxf.apache.org
  • 4. Agenda  What is JBI?  JBI 1.0 & Apache Servicemix 3.x  CXF-BC & CXF-SE  Apache Servicemix 4.0
  • 5. What is JBI?  JBI defines an architecture that allows the construction of integration systems from plug-in components, that interoperate through the method of mediated message exchange. (JBI 1.0 spec, JSR 208)  Keywords: plugin, MEPS, NMR
  • 8. JBI 1.0  WSDL Messaging Model  Component  Normalized Message Router (NMR)  Management  Package  Deployment  Monitoring
  • 9. JBI 1.0: WSDL messaging model  Abstract model  Concrete model  Service providers  Service consumers
  • 10. JBI 1.0: WSDL messaging model Message type Normal Faults Operation Qualified name Message Exchange Pattern Message types Interface Qualified name Operations Extended interfaces
  • 11. JBI 1.0: WSDL messaging model  Binding type  Endpoint Endpoint name Binding type  Service Qualified name Interface name Endpoints
  • 12. a real wsdl-part 1 <wsdl:definitions name=quot;wsdl-firstquot; xmlns:wsdl=quot;http://schemas.xmlsoap.org/wsdl/quot; xmlns:soap=quot;http://schemas.xmlsoap.org/wsdl/soap/quot; xmlns:xsd=quot;http://www.w3.org/2001/XMLSchemaquot; xmlns:xsi=quot;http://www.w3.org/2001/XMLSchema-instancequot; xmlns:tns=quot;http://servicemix.apache.org/samples/wsdl-firstquot; xmlns:typens=quot;http://servicemix.apache.org/samples/wsdl-first/typesquot; targetNamespace=quot;http://servicemix.apache.org/samples/wsdl-firstquot;> <wsdl:types> <xsd:schema targetNamespace=quot;http://servicemix.apache.org/samples/wsdl-first/typesquot; elementFormDefault=quot;qualifiedquot;> <xsd:element name=quot;GetPersonquot;> <xsd:complexType> <xsd:sequence> <xsd:element name=quot;personIdquot; type=quot;xsd:stringquot;/> </xsd:sequence> </xsd:complexType> </xsd:element> <xsd:element name=quot;GetPersonResponsequot;> <xsd:complexType> <xsd:sequence> <xsd:element name=quot;personIdquot; type=quot;xsd:stringquot;/> <xsd:element name=quot;ssnquot; type=quot;xsd:stringquot;/> <xsd:element name=quot;namequot; type=quot;xsd:stringquot;/> </xsd:sequence> </xsd:complexType> </xsd:element> <xsd:element name=quot;UnknownPersonFaultquot;> <xsd:complexType> <xsd:sequence> <xsd:element name=quot;personIdquot; type=quot;xsd:stringquot;/> </xsd:sequence> </xsd:complexType> </xsd:element> </xsd:schema> </wsdl:types>
  • 13. a real wsdl – part 2 <wsdl:message name=quot;GetPersonRequestquot;> <wsdl:part name=quot;payloadquot; element=quot;typens:GetPersonquot;/> </wsdl:message> <wsdl:message name=quot;GetPersonResponsequot;> <wsdl:part name=quot;payloadquot; element=quot;typens:GetPersonResponsequot;/> </wsdl:message> <wsdl:message name=quot;UnknownPersonFaultquot;> <wsdl:part name=quot;payloadquot; element=quot;typens:UnknownPersonFaultquot;/> </wsdl:message> <wsdl:portType name=quot;Personquot;> <wsdl:operation name=quot;GetPersonquot;> <wsdl:input message=quot;tns:GetPersonRequestquot;/> <wsdl:output message=quot;tns:GetPersonResponsequot;/> <wsdl:fault name=quot;UnknownPersonquot; message=quot;tns:UnknownPersonFaultquot;/> </wsdl:operation> </wsdl:portType> <wsdl:binding name=quot;PersonSOAPBindingquot; type=quot;tns:Personquot;> <soap:binding style=quot;documentquot; transport=quot;http://schemas.xmlsoap.org/soap/httpquot; /> <wsdl:operation name=quot;GetPersonquot;> <wsdl:input> <soap:body use=quot;literalquot; /> </wsdl:input> <wsdl:output> <soap:body use=quot;literalquot; /> </wsdl:output> <wsdl:fault name=quot;UnknownPersonquot;> <soap:fault use=quot;literalquot; name=quot;UnknownPersonquot; /> </wsdl:fault> </wsdl:operation> </wsdl:binding> <wsdl:service name=quot;PersonServicequot;> <wsdl:port binding=quot;tns:PersonSOAPBindingquot; name=quot;soapquot;> <soap:address location=quot;http://localhost:8092/PersonService/quot; /> </wsdl:port> </wsdl:service> </wsdl:definitions>
  • 14. Java interface @WebService(targetNamespace = quot;http://servicemix.apache.org/samples/wsdl-firstquot;, name = quot;Personquot;) public interface Person { @ResponseWrapper(localName = quot;GetPersonResponsequot;, targetNamespace = quot;http://servicemix.apache.org/samples/wsdl- first/typesquot;, className = quot;org.apache.servicemix.samples.wsdl_first.types.GetPersonResponsequot;) @RequestWrapper(localName = quot;GetPersonquot;, targetNamespace = quot;http://servicemix.apache.org/samples/wsdl-first/typesquot;, className = quot;org.apache.servicemix.samples.wsdl_first.types.GetPersonquot;) @WebMethod(operationName = quot;GetPersonquot;) public void getPerson( @WebParam(mode = WebParam.Mode.INOUT, name = quot;personIdquot;, targetNamespace = quot;http://servicemix.apache.org/samples/ wsdl-first/typesquot;) javax.xml.ws.Holder<java.lang.String> personId, @WebParam(mode = WebParam.Mode.OUT, name = quot;ssnquot;, targetNamespace = quot;http://servicemix.apache.org/samples/wsdl- first/typesquot;) javax.xml.ws.Holder<java.lang.String> ssn, @WebParam(mode = WebParam.Mode.OUT, name = quot;namequot;, targetNamespace = quot;http://servicemix.apache.org/samples/wsdl- first/typesquot;) javax.xml.ws.Holder<java.lang.String> name ) throws UnknownPersonFault; }
  • 15. Component  Binding Component  To communicate using remote protocols  To normalize/denormalize messages it receives  Examples:  servicemix-file  servicemix-ftp  servicemix-cxf-bc  Service Engine  A service engine (SE) provides some type of logic inside the JBI environment and only communicates with the NMR.  Examples:  servicemix-bean  servicemix-camel  servicemix-cxf-se
  • 16. Nomarlized Message Router  Consumer & Provider  Normalized Message  Delivery Channel  Message Exchange Pattern (MEP)  Endpoints  Run-time Endpoint Activation
  • 17. Normalized Message Router The Normalized Message Router (or NMR) receives message exchanges from JBI components and routes them to the appropriate component for processing. This decouples the service producers from consumers and enable additional processing.
  • 18. Provider & Consumer  WSDL Description  Abstract Model  Decoupled
  • 19. Message Normalization  Message normalization/denormalization is the act of converting a message from/ to a protocol-specific format into a format for the JBI environment. This normalization is performed by BCs involves converting all messages into a NormalizedMessage.  A Normalized Message consist of following:  The “payload”, or bare message: an XML document that conforms to an abstract WSDL message type.  Message properties (sometime called metadata). These hold extra data associated with the message, key-value  Attachments: Extra (generally binary) attachments to the main message object.
  • 20. what NMR looks like id: ID:127.0.0.1-11761bd912f-8:0 status: Active role: provider service: {http://apache.org/cxf/calculator}CalculatorService endpoint: CalculatorPort operation: {http://apache.org/cxf/calculator}add in: <?xml version=quot;1.0quot; encoding=quot;UTF-8quot;?><message xmlns=quot;http://java.sun.com/xml/ns/jbi/wsdl-11-wrapperquot;> <part> <add xmlns=quot;http://apache.org/cxf/calculator/typesquot;> <arg0>1</arg0> <arg1>2</arg1> </add> </part></message>
  • 21. Delivery Channel A Delivery Channel is a bidirectional asynchronous communication pipes between a component and the NMR. A service consumer uses its delivery channel to initiate a service invocation, while the provider uses its delivery channel to receive such invocations. Each component is provided with a single delivery channel, so the same channel is used for both inbound and outbound communications.
  • 22. Message Exchange Pattern  In-Only: consumer issues a request to provider with no error (fault) path provided  Robust In-Only: consumer issues a request to provider. Provider may respond with a fault if it fails to process request.  In-Out: consumer issues a request to provider, with expectation of response. Provider may respond with a fault if it fails to process request.  In-Optional-Out: consumer issues a request to provider, which may result in a response. Consumer and provider both have the option of generating a fault in response to a message received during the interaction
  • 27. Endpoints JBI uses the same concept of endpoints as defined in WSDL 2.0. Endpoints refers to a particular address, accessible by a particular protocol, used to access a particular service. Endpoints have two distinct types:  External  External endpoints are endpoints outside the JBI environment. They are endpoints exposed by binding component acting as service consumers to expose an internal endpoint for the use of external service consumers  Internal  Internal endpoints are exposed by service providers inside the JBI environment. They are accessed using the NMR APIs.
  • 28. Addressing In JBI, endpoints are referred to (or addressed) in three distinct ways: ● Implicitly: the NMR selects the endpoint based on the service type required. ● Explicitly: a consumer chooses the endpoint based on its own logic and configuration. ● Dynamically: an endpoint reference (EPR) is used within a message exchange to provide a “ call-back” address that the service provider should use to send further message exchanges. EPRs are xml fragment created and resolved by JBI components.
  • 29. JBI Management It is JMX-based.  JBI Package.  Install & Deploy  ClassLoader
  • 30. JBI Package  JBI defines a standard packaging for installing new components and deploying artifacts onto these components that can function as quot;containersquot;.All these artifacts contain a JBI descriptor in the META-INF directory called jbi.xml.  There are four types of artifacts, all packaged as zip or jar files:  Components installers contain the libraries and resources needed to run the component. Components can references Shared Libraries.  Shared Libraries are collection of jars that can be shared by several components  Service Units are artifacts meant to be deployed to a specific component. Aside from the JBI descriptor, the service unit packaging is specific to a component and can take various forms: a single XSLT style sheet, a BPEL process, or some java classes ...  Service assemblies are collections of Service Units. Service units can not be deployed directly and must be packaged in a service assembly which contains the service units and associated metadata.
  • 31. Shared Lib <?xml version=quot;1.0quot; encoding=quot;UTF-8quot;?> <jbi xmlns=quot;http://java.sun.com/xml/ns/jbiquot; version=quot;1.0quot;> <shared-library class-loader-delegation=quot;parent-firstquot; version=quot;3.2.4-SNAPSHOTquot;> <identification> <name>servicemix-shared</name> <description>ServiceMix :: Shared</description> </identification> <shared-library-class-path> <path-element>lib/servicemix-shared-3.2.4-SNAPSHOT.jar</path-element> <path-element>lib/servicemix-common-3.2.4-SNAPSHOT.jar</path-element> <path-element>lib/servicemix-soap-3.2.4-SNAPSHOT.jar</path-element> <path-element>lib/bcprov-jdk14-136.jar</path-element> <path-element>lib/opensaml-1.1.jar</path-element> <path-element>lib/xmlsec-1.3.0.jar</path-element> <path-element>lib/servicemix-soap2-3.2.4-SNAPSHOT.jar</path-element> <path-element>lib/wss4j-1.5.4.jar</path-element> <path-element>lib/commons-logging-1.1.jar</path-element> <path-element>lib/xmlsec-1.4.0.jar</path-element> <path-element>lib/opensaml-1.1.jar</path-element> <path-element>lib/axis-ant-1.4.jar</path-element> <path-element>lib/xml-apis-1.3.04.jar</path-element> <path-element>lib/xercesImpl-2.8.1.jar</path-element> <path-element>lib/bcprov-jdk15-132.jar</path-element> <path-element>lib/XmlSchema-1.3.2.jar</path-element> <path-element>lib/woden-1.0.0M6.jar</path-element> </shared-library-class-path> </shared-library> </jbi>
  • 32. component <?xml version=quot;1.0quot; encoding=quot;UTF-8quot;?> <jbi xmlns=quot;http://java.sun.com/xml/ns/jbiquot; version=quot;1.0quot;> <component type=quot;binding-componentquot; component-class-loader-delegation=quot;parent-firstquot; bootstrap-class-loader-delegation=quot;parent-firstquot;> <identification> <name>servicemix-file</name> <description>ServiceMix :: File</description> </identification> <component-class-name>org.apache.servicemix.file.FileComponent</component-class-name> <component-class-path> <path-element>lib/servicemix-file-3.2.4-SNAPSHOT.jar</path-element> <path-element>lib/commons-logging-1.1.jar</path-element> <path-element>lib/xercesImpl-2.8.1.jar</path-element> <path-element>lib/xml-apis-1.3.04.jar</path-element> <path-element>lib/log4j-1.2.13.jar</path-element> </component-class-path> <bootstrap-class-name>org.apache.servicemix.common.DefaultBootstrap</bootstrap-class-name> <bootstrap-class-path> <path-element>lib/servicemix-file-3.2.4-SNAPSHOT.jar</path-element> <path-element>lib/commons-logging-1.1.jar</path-element> <path-element>lib/xercesImpl-2.8.1.jar</path-element> <path-element>lib/xml-apis-1.3.04.jar</path-element> <path-element>lib/log4j-1.2.13.jar</path-element> </bootstrap-class-path> <shared-library version=quot;3.2.4-SNAPSHOTquot;>servicemix-shared</shared-library> </component> </jbi>
  • 33. service assembly <?xml version=quot;1.0quot; encoding=quot;UTF-8quot;?> <jbi xmlns=quot;http://java.sun.com/xml/ns/jbiquot; version=quot;1.0quot;> <service-assembly> <identification> <name>wsdl-first-cxf-sa</name> <description>ServiceMix :: Samples :: WSDL first :: SA</description> </identification> <service-unit> <identification> <name>wsdl-first-cxfse-su</name> <description>ServiceMix is an open source ESB based on the Java Business Integration framework - JSR-208</description> </identification> <target> <artifacts-zip>wsdl-first-cxfse-su-3.3.zip</artifacts-zip> <component-name>servicemix-cxf-se</component-name> </target> </service-unit> <service-unit> <identification> <name>wsdl-first-cxfbc-su</name> <description>ServiceMix is an open source ESB based on the Java Business Integration framework - JSR-208</description> </identification> <target> <artifacts-zip>wsdl-first-cxfbc-su-3.3.zip</artifacts-zip> <component-name>servicemix-cxf-bc</component-name> </target> </service-unit> </service-assembly> </jbi>
  • 34. Package Install & Deploy  For the shared library & component, it is called installation  For the service assembly, it is called deployment  In general, Container Developer (like us) write the component, Application Developer write the serivce unit and service assembly.
  • 35. ClassLoader  There are several classloaders involved in ServiceMix:  the container class loader.  shared library class loader: the parent is the container class loader.  component class loader: parents are container class loader + any referenced SL class loader.  service unit class loader: parent is the component class loader.  Two kinds of classloader algorithm.  parent-first. (by default)  self-first.
  • 36. CXF-BC & CXF-SE  why we integrate cxf into servicemix?  what's the key components for this integration?
  • 37. Cxf BC  cxf bc consumer  cxf bc provider  http support  https support  jms support  ws-* support
  • 38. cxf bc endpoint configuration <cxfbc:consumer wsdl=quot;/wsdl/calculator.wsdlquot; service=quot;calculator:CalculatorServicequot; endpoint=quot;CalculatorPortquot; targetEndpoint=quot;CalculatorPortProxyquot; targetService=quot;calculator:CalculatorServicequot; targetInterface=quot;calculator:CalculatorPortTypequot;> </cxfbc:consumer> <cxfbc:provider wsdl=quot;/wsdl/calculator.wsdlquot; locationURI=quot;http://localhost:9001/bridgetestquot; service=quot;calculator:CalculatorServicequot; endpoint=quot;CalculatorPortProxyquot; interfaceName=quot;calculator:CalculatorPortTypequot; > </cxfbc:provider>
  • 39. Cxf SE  jax-ws frontend  simple frontend  jaxb databinding  aegis databinding  MTOM support  client proxy
  • 40. Cxf SE configuration <cxfse:endpoint> <cxfse:pojo> <bean class=quot;org.apache.cxf.calculator.CalculatorImplquot;> </bean> </cxfse:pojo> <cxfse:inInterceptors> <bean class=quot;org.apache.cxf.interceptor.LoggingInInterceptorquot;/> </cxfse:inInterceptors> <cxfse:outInterceptors> <bean class=quot;org.apache.cxf.interceptor.LoggingOutInterceptorquot;/> </cxfse:outInterceptors> </cxfse:endpoint> <cxfse:endpoint> <cxfse:pojo> <bean class=quot;org.apache.servicemix.cxfse.GreeterImplForClientProxyquot;> <property name=quot;calculatorquot;> <cxfse:proxy service=quot;calculator:CalculatorServicequot; context=quot;#contextquot; type=quot;org.apache.cxf.calculator.CalculatorPortTypequot; /> </property> </bean> </cxfse:pojo> </cxfse:endpoint>
  • 41. typical scenario external client<==>cxf bc cosumer<==NMR==>cxf se endpoint or client proxy in cxf se<==NMR==>cxf bc provider<===>external server
  • 42. JBI binding & JBI transport  src code is in cxf code base  JBI binding is responsible for the Marshalling/Unmarshalling  JBI transport is reponsible for receiving and sending message using JBI api
  • 43. Soap Message VS JBI Message <soap:Envelope xmlns:soap=quot;http://www.w3.org/2003/05/soap-envelopequot;> <soap:Body> <add xmlns=quot;http://apache.org/cxf/calculator/typesquot;> <arg0>1</arg0> <arg1>2</arg1> </add> </soap:Body> </soap:Envelope> <jbi:message xmlns:jbi=quot;http://java.sun.com/xml/ns/jbi/wsdl-11-wrapperquot; xmlns:msg=quot;http://apache.org/cxf/calculatorquot; name=quot;addquot; type=quot;msg:addquot; version=quot;1.0quot;> <jbi:part> <add xmlns=quot;http://apache.org/cxf/calculator/typesquot;> <arg0>1</arg0> <arg1>2</arg1> </add> </jbi:part> </jbi:message>
  • 44. JBI 1.0: Lesson Learned  Pros  Normalized exchanges  Normalized Message Router  Cons  Classloader architecture. (jar version conflict issue)  JBI packaging. (too complicated)  Writing components is complex.
  • 45. Servicemix 4.0  Goal  runtime  building blocks
  • 46. Servicemix 4.0 : Goal  Enterprise OSGi Container  Lightweight  ESB and SOA container  Ease of use
  • 47. SMX4.0: Ease of Use  No more components.  Deployment / Classloader is delegated to OSGi.  Bundles as the packaging and extension mechanism.  Leverage OSGi architecture.  Leverage spring-osgi (optionally)  Endpoints as first-class citizens  Endpoint are activated when registered in the OSGi registry.  Channel is now on the Endpoint.  Endpoints use push delivery rather than pulling the channel.
  • 48. SMX4.0: Runtime  Hot deployment of OSGi bundles.  Dynamic reloadable configuration.  Extensible Shell console(Gshell).  Remote access.  Running multiple instances.
  • 49. building blocks  avoid reinventing the wheel Framework: OSGi (Apache Felix) SOAP support: Apache CXF JMS broker: Apache ActiveMQ Routing Engine: Apache Camel
  • 50. Moreover Any kind of contribution is welcome!!!
  • 51. More on Camel??  please refer to Willem's Ride on Camel