SlideShare uma empresa Scribd logo
1 de 19
Baixar para ler offline
JBoss Web Services
    Alessio Soldano
 alessio.soldano@jboss.com

  Principal Software Eng.
      JBoss - Red Hat

      April 28th, 2010
Who is Alessio?

●   JBoss WS[1] committer since early 2007
●   JBoss / Red Hat employee since end of 2007
●   JBoss Web Service Lead, 2008
●   JBoss AS[2], JBoss Wise[3] contributor
●   Current Red Hat representative at JSR-224 EG
    and W3C WS-ResourceAccess WG
●   Apache CXF[4] committer since 2009

    [1] http://www.jboss.org/jbossws   [2] http://www.jboss.org/jbossas

    [3] http://www.jboss.org/wise      [4] http://cxf.apache.org
What is JBoss WS?

●   “Just” a feature-rich JAX-WS compatible ws stack
    till early 2008...



●   a web services framework providing
    integration layers for 3rd party ws stacks on top
    of multiple JBoss AS versions
        –   CXF, Native and Metro stack
        –   AS 5.x, AS 6.x target containers
The benefits of standards / specs
            W3C standards allow for interoperability
●   WS-Security           <s:Envelope...>

                            <s:Header>
●   WS-Policy                 <o:Security...>

●   WS-Addressing                <u:Timestamp u:Id="..">...</u:Timestamp>

                                 <o:BinarySecurityToken...>...</o:BinarySecurityToken>
●   ...
                                 <e:EncryptedKey...>...</e:EncryptedKey>

                                 <e:ReferenceList...>...</e:ReferenceList>

                                 <Signature xmlns="http://www.w3.org/2000/09/xmldsig#">

Defined way to:                    ...

                                 </Signature>
●   format messages
                              </o:Security>
●   advertise services      </s:Header>

●   ...                     <s:Body>...</s:Body>

                          </s:Envelope>
The benefits of standards / specs
                              JCP specs give us common dev API
          ●   JSR-224 / JSR-181 (JAX-WS)
          ●   JSR-109 (WS for JavaEE)
                                                                    EndpointService service = new EndpointService(
          ●   JSR-101 (JAX-RPC)
                                                                      wsdlURL, serviceQName);
          ●   JSR-261* (JAX-WSA)                                    Endpoint port = service.getEndpointPort();

          ●   ...                                                   String retObj = port.echo(“Hello World”);



@WebService(name = "Endpoint", serviceName = "EndpointService", targetNamespace = "http://org.jboss.ws/wsref")

@SOAPBinding(style = Style.DOCUMENT, use = Use.LITERAL)

public class EndpointImpl {

    @WebMethod(action = “echo”)

    public String echo(String input) {

        return input;

    }

}
Reasons for integrating

●   really good open source implementations
    already available - NIH syndrome
●   focus on added value
●   open choice (features, performance, ...)
●   ... a lot of Web Services specifications!
Reasons for integrating
Who benefits from this move?

●   The JBoss community:
        –   different choices depending on needs
        –   greater joint community support
        –   core devs can work on added value
●   The integrated ws projects and their community:
        –   additional tests
        –   bugs detection and fix
        –   ...
JBoss WSF: high level overview
Web Service Framework
●   Management                   ●   Tooling
       –   console                       –   common JAXWS tools
       –   endpoint registry             –   project generator
       –   records system                –   Eclipse integration
●   Configuration                ●   AS integration
       –   address rewrite               –   authentication
●   Features                             –   authorization

       –   JAXBIntroductions
                                 ●   Common deploy
       –   Common JAX-WSA JSR-   ●   Common testsuite
             261 API
Do I really need your integration
                  layer?
●   Home-brew solutions for running CXF / Metro on
    JBossAS might work for specific usecases, but
    you...
        –   need to embed the stack in your apps
        –   will suffer from classloading issues
        –   can just use pojo endpoints
        –   have no webserviceref injection in ejb3
        –   loose additional WSF features ;-)
        –   ...
How it works - deployment

●   POJO endpoint
                                   <web-app ...>
    @WebService(...)
                                    <servlet>
    public class MyEndpoint {
                                     <servlet-name>TestService</servlet-name>
      public String sayHello() {
                                     <servlet-class>org.jboss.test.ws.jaxws.samples.MyEndpoint</servlet-class>
        return "Hello World!";
                                    </servlet>
      }
                                    <servlet-mapping>
    }
                                     <servlet-name>TestService</servlet-name>
                                     <url-pattern>/*</url-pattern>
                                    </servlet-mapping>
                                   </web-app>


●   EJB3 endpoint
    @WebService(...)
    @Stateless
    public class MyEndpoint {                                             Create metadata to
      public String sayHello() {
        return "Hello World!";                                            deploy jboss-web app
      }
    }
How it works - deployment

●   Parse or generate proprietary descriptor
       –   jboss-cxf.xml for CXF stack (Spring conf)
       –   sun-jaxws.xml for Metro stack
●   Setup different endpoint servlets for each
    stack
       –   extending CXFServlet for CXF stack
How it works - runtime

●   Request handlers: called by enpdoint servlet
    to serve GET / POST requests; delegate to
       –   CXF ServletController
       –   Metro ServletAdapter
●   Invokers: route invocation to JBossAS (JBoss
    EJB3 layer for ejb3 endpoints)
       –   configured during proprietary descriptor
            processing / creation
How it works - runtime
                                     Request
Endpoint servlet



                    RequestHandler

                                       WS-*            ...




                                                              Invoker
                                               CXF                      JBoss
                                                or                       AS
                                               Metro
                                                   JAX-WS
                                        ...        handlers




                                     Response
More on deployers...

JBoss AS 5 deployers gives high flexibility
●   multiple webservice deployers generated
        –   stack agnostic deployment aspects
        –   stack specific deployment aspects
        –   extensibility, separation of concerns, ...
●   two webservice stacks at the same time
        –   JAX-RPC support with CXF / Metro
CXF: additional integration hooks

●   Bus configuration: CXF runtime behaviour is
    controlled by the current Bus; we can set:
       –   custom resource resolvers
       –   custom transport factories
       –   custom CXF Configurer bean
       –   ...
●   Spring Namespace Handlers: we can change
    configuration namespace to default bean
    mapping
       –   override / extend core CXF beans
Some links...

●   http://www.jboss.org/jbossws
●   http://community.jboss.org/wiki/JBossWS
●   http://jbossws.blogspot.com/
Q&A

Mais conteúdo relacionado

Mais procurados

8b. Column Oriented Databases Lab
8b. Column Oriented Databases Lab8b. Column Oriented Databases Lab
8b. Column Oriented Databases LabFabio Fumarola
 
Alternatives of JPA/Hibernate
Alternatives of JPA/HibernateAlternatives of JPA/Hibernate
Alternatives of JPA/HibernateSunghyouk Bae
 
Cassandra 3.0 - JSON at scale - StampedeCon 2015
Cassandra 3.0 - JSON at scale - StampedeCon 2015Cassandra 3.0 - JSON at scale - StampedeCon 2015
Cassandra 3.0 - JSON at scale - StampedeCon 2015StampedeCon
 
Cloudera Impala, updated for v1.0
Cloudera Impala, updated for v1.0Cloudera Impala, updated for v1.0
Cloudera Impala, updated for v1.0Scott Leberknight
 
Building .NET Apps using Couchbase Lite
Building .NET Apps using Couchbase LiteBuilding .NET Apps using Couchbase Lite
Building .NET Apps using Couchbase Litegramana
 
Building node.js applications with Database Jones
Building node.js applications with Database JonesBuilding node.js applications with Database Jones
Building node.js applications with Database JonesJohn David Duncan
 
Practicing Continuous Deployment
Practicing Continuous DeploymentPracticing Continuous Deployment
Practicing Continuous Deploymentzeeg
 
Omnisearch in AEM 6.2 - Search All the Things
Omnisearch in AEM 6.2 - Search All the ThingsOmnisearch in AEM 6.2 - Search All the Things
Omnisearch in AEM 6.2 - Search All the ThingsJustin Edelson
 
Scalable XQuery Processing with Zorba on top of MongoDB
Scalable XQuery Processing with Zorba on top of MongoDBScalable XQuery Processing with Zorba on top of MongoDB
Scalable XQuery Processing with Zorba on top of MongoDBWilliam Candillon
 
Designing a JavaFX Mobile application
Designing a JavaFX Mobile applicationDesigning a JavaFX Mobile application
Designing a JavaFX Mobile applicationFabrizio Giudici
 
Cassandra and materialized views
Cassandra and materialized viewsCassandra and materialized views
Cassandra and materialized viewsGrzegorz Duda
 
ElasticSearch for .NET Developers
ElasticSearch for .NET DevelopersElasticSearch for .NET Developers
ElasticSearch for .NET DevelopersBen van Mol
 
Pragmatische Plone Projekte
Pragmatische Plone ProjektePragmatische Plone Projekte
Pragmatische Plone ProjekteAndreas Jung
 
Kotlin @ Coupang Backend 2017
Kotlin @ Coupang Backend 2017Kotlin @ Coupang Backend 2017
Kotlin @ Coupang Backend 2017Sunghyouk Bae
 
NoSQL and JavaScript: a Love Story
NoSQL and JavaScript: a Love StoryNoSQL and JavaScript: a Love Story
NoSQL and JavaScript: a Love StoryAlexandre Morgaut
 

Mais procurados (20)

Requery overview
Requery overviewRequery overview
Requery overview
 
8b. Column Oriented Databases Lab
8b. Column Oriented Databases Lab8b. Column Oriented Databases Lab
8b. Column Oriented Databases Lab
 
Spring data requery
Spring data requerySpring data requery
Spring data requery
 
Alternatives of JPA/Hibernate
Alternatives of JPA/HibernateAlternatives of JPA/Hibernate
Alternatives of JPA/Hibernate
 
Cassandra 3.0 - JSON at scale - StampedeCon 2015
Cassandra 3.0 - JSON at scale - StampedeCon 2015Cassandra 3.0 - JSON at scale - StampedeCon 2015
Cassandra 3.0 - JSON at scale - StampedeCon 2015
 
Cloudera Impala, updated for v1.0
Cloudera Impala, updated for v1.0Cloudera Impala, updated for v1.0
Cloudera Impala, updated for v1.0
 
Building .NET Apps using Couchbase Lite
Building .NET Apps using Couchbase LiteBuilding .NET Apps using Couchbase Lite
Building .NET Apps using Couchbase Lite
 
Building node.js applications with Database Jones
Building node.js applications with Database JonesBuilding node.js applications with Database Jones
Building node.js applications with Database Jones
 
Practicing Continuous Deployment
Practicing Continuous DeploymentPracticing Continuous Deployment
Practicing Continuous Deployment
 
Oak Lucene Indexes
Oak Lucene IndexesOak Lucene Indexes
Oak Lucene Indexes
 
My sql tutorial-oscon-2012
My sql tutorial-oscon-2012My sql tutorial-oscon-2012
My sql tutorial-oscon-2012
 
Omnisearch in AEM 6.2 - Search All the Things
Omnisearch in AEM 6.2 - Search All the ThingsOmnisearch in AEM 6.2 - Search All the Things
Omnisearch in AEM 6.2 - Search All the Things
 
Scalable XQuery Processing with Zorba on top of MongoDB
Scalable XQuery Processing with Zorba on top of MongoDBScalable XQuery Processing with Zorba on top of MongoDB
Scalable XQuery Processing with Zorba on top of MongoDB
 
Designing a JavaFX Mobile application
Designing a JavaFX Mobile applicationDesigning a JavaFX Mobile application
Designing a JavaFX Mobile application
 
JCR and ModeShape
JCR and ModeShapeJCR and ModeShape
JCR and ModeShape
 
Cassandra and materialized views
Cassandra and materialized viewsCassandra and materialized views
Cassandra and materialized views
 
ElasticSearch for .NET Developers
ElasticSearch for .NET DevelopersElasticSearch for .NET Developers
ElasticSearch for .NET Developers
 
Pragmatische Plone Projekte
Pragmatische Plone ProjektePragmatische Plone Projekte
Pragmatische Plone Projekte
 
Kotlin @ Coupang Backend 2017
Kotlin @ Coupang Backend 2017Kotlin @ Coupang Backend 2017
Kotlin @ Coupang Backend 2017
 
NoSQL and JavaScript: a Love Story
NoSQL and JavaScript: a Love StoryNoSQL and JavaScript: a Love Story
NoSQL and JavaScript: a Love Story
 

Destaque

October 2009 - Open Meeting
October 2009 - Open MeetingOctober 2009 - Open Meeting
October 2009 - Open MeetingJBug Italy
 
Intro JBug Milano - January 2012
Intro JBug Milano - January 2012Intro JBug Milano - January 2012
Intro JBug Milano - January 2012JBug Italy
 
October 2009 - JBoss Cloud
October 2009 - JBoss CloudOctober 2009 - JBoss Cloud
October 2009 - JBoss CloudJBug Italy
 
November 2009 - JSR-299 Context & Dependency Injection
November 2009 - JSR-299 Context & Dependency InjectionNovember 2009 - JSR-299 Context & Dependency Injection
November 2009 - JSR-299 Context & Dependency InjectionJBug Italy
 
Intro jbug milano_26_set2012
Intro jbug milano_26_set2012Intro jbug milano_26_set2012
Intro jbug milano_26_set2012JBug Italy
 
September 2010 - Arquillian
September 2010 - ArquillianSeptember 2010 - Arquillian
September 2010 - ArquillianJBug Italy
 
All the cool stuff of JBoss BRMS
All the cool stuff of JBoss BRMSAll the cool stuff of JBoss BRMS
All the cool stuff of JBoss BRMSJBug Italy
 

Destaque (7)

October 2009 - Open Meeting
October 2009 - Open MeetingOctober 2009 - Open Meeting
October 2009 - Open Meeting
 
Intro JBug Milano - January 2012
Intro JBug Milano - January 2012Intro JBug Milano - January 2012
Intro JBug Milano - January 2012
 
October 2009 - JBoss Cloud
October 2009 - JBoss CloudOctober 2009 - JBoss Cloud
October 2009 - JBoss Cloud
 
November 2009 - JSR-299 Context & Dependency Injection
November 2009 - JSR-299 Context & Dependency InjectionNovember 2009 - JSR-299 Context & Dependency Injection
November 2009 - JSR-299 Context & Dependency Injection
 
Intro jbug milano_26_set2012
Intro jbug milano_26_set2012Intro jbug milano_26_set2012
Intro jbug milano_26_set2012
 
September 2010 - Arquillian
September 2010 - ArquillianSeptember 2010 - Arquillian
September 2010 - Arquillian
 
All the cool stuff of JBoss BRMS
All the cool stuff of JBoss BRMSAll the cool stuff of JBoss BRMS
All the cool stuff of JBoss BRMS
 

Semelhante a April 2010 - JBoss Web Services

As7 web services - JUG Milan April 2012
As7 web services - JUG Milan April 2012As7 web services - JUG Milan April 2012
As7 web services - JUG Milan April 2012alepalin
 
JBoss AS7 Webservices
JBoss AS7 WebservicesJBoss AS7 Webservices
JBoss AS7 WebservicesJBug Italy
 
JBoss AS7 web services
JBoss AS7 web servicesJBoss AS7 web services
JBoss AS7 web servicesalepalin
 
JBoss AS Upgrade
JBoss AS UpgradeJBoss AS Upgrade
JBoss AS Upgradesharmami
 
WildFly AppServer - State of the Union
WildFly AppServer - State of the UnionWildFly AppServer - State of the Union
WildFly AppServer - State of the UnionDimitris Andreadis
 
MSc Enterprise Systems Development Guest Lecture at UniS (2/12/09)
MSc Enterprise Systems Development Guest Lecture at UniS (2/12/09)MSc Enterprise Systems Development Guest Lecture at UniS (2/12/09)
MSc Enterprise Systems Development Guest Lecture at UniS (2/12/09)Daniel Bryant
 
Integrating SAP the Java EE Way - JBoss One Day talk 2012
Integrating SAP the Java EE Way - JBoss One Day talk 2012Integrating SAP the Java EE Way - JBoss One Day talk 2012
Integrating SAP the Java EE Way - JBoss One Day talk 2012hwilming
 
Better Enterprise Integration With the WSO2 ESB 4.5.1
Better Enterprise Integration With the WSO2 ESB 4.5.1Better Enterprise Integration With the WSO2 ESB 4.5.1
Better Enterprise Integration With the WSO2 ESB 4.5.1WSO2
 
Real world #microservices with Apache Camel, Fabric8, and OpenShift
Real world #microservices with Apache Camel, Fabric8, and OpenShiftReal world #microservices with Apache Camel, Fabric8, and OpenShift
Real world #microservices with Apache Camel, Fabric8, and OpenShiftChristian Posta
 
Real-world #microservices with Apache Camel, Fabric8, and OpenShift
Real-world #microservices with Apache Camel, Fabric8, and OpenShiftReal-world #microservices with Apache Camel, Fabric8, and OpenShift
Real-world #microservices with Apache Camel, Fabric8, and OpenShiftChristian Posta
 
Advance Java Topics (J2EE)
Advance Java Topics (J2EE)Advance Java Topics (J2EE)
Advance Java Topics (J2EE)slire
 
Schema Evolution for Resilient Data microservices
Schema Evolution for Resilient Data microservicesSchema Evolution for Resilient Data microservices
Schema Evolution for Resilient Data microservicesVinícius Carvalho
 
Java web services using JAX-WS
Java web services using JAX-WSJava web services using JAX-WS
Java web services using JAX-WSIndicThreads
 
Building WebLogic Domains With WLST
Building WebLogic Domains With WLSTBuilding WebLogic Domains With WLST
Building WebLogic Domains With WLSTC2B2 Consulting
 
Groovy & Grails eXchange 2012 vert.x presentation
Groovy & Grails eXchange 2012 vert.x presentationGroovy & Grails eXchange 2012 vert.x presentation
Groovy & Grails eXchange 2012 vert.x presentationStuart (Pid) Williams
 
Red Hat Agile integration Workshop Labs
Red Hat Agile integration Workshop LabsRed Hat Agile integration Workshop Labs
Red Hat Agile integration Workshop LabsJudy Breedlove
 
CloudConnect 2011 - Building Highly Scalable Java Applications on Windows Azure
CloudConnect 2011 - Building Highly Scalable Java Applications on Windows AzureCloudConnect 2011 - Building Highly Scalable Java Applications on Windows Azure
CloudConnect 2011 - Building Highly Scalable Java Applications on Windows AzureDavid Chou
 

Semelhante a April 2010 - JBoss Web Services (20)

As7 web services - JUG Milan April 2012
As7 web services - JUG Milan April 2012As7 web services - JUG Milan April 2012
As7 web services - JUG Milan April 2012
 
JBoss AS7 Webservices
JBoss AS7 WebservicesJBoss AS7 Webservices
JBoss AS7 Webservices
 
JBoss AS7 web services
JBoss AS7 web servicesJBoss AS7 web services
JBoss AS7 web services
 
JBoss AS Upgrade
JBoss AS UpgradeJBoss AS Upgrade
JBoss AS Upgrade
 
Play framework
Play frameworkPlay framework
Play framework
 
WildFly AppServer - State of the Union
WildFly AppServer - State of the UnionWildFly AppServer - State of the Union
WildFly AppServer - State of the Union
 
MSc Enterprise Systems Development Guest Lecture at UniS (2/12/09)
MSc Enterprise Systems Development Guest Lecture at UniS (2/12/09)MSc Enterprise Systems Development Guest Lecture at UniS (2/12/09)
MSc Enterprise Systems Development Guest Lecture at UniS (2/12/09)
 
Integrating SAP the Java EE Way - JBoss One Day talk 2012
Integrating SAP the Java EE Way - JBoss One Day talk 2012Integrating SAP the Java EE Way - JBoss One Day talk 2012
Integrating SAP the Java EE Way - JBoss One Day talk 2012
 
Better Enterprise Integration With the WSO2 ESB 4.5.1
Better Enterprise Integration With the WSO2 ESB 4.5.1Better Enterprise Integration With the WSO2 ESB 4.5.1
Better Enterprise Integration With the WSO2 ESB 4.5.1
 
Real world #microservices with Apache Camel, Fabric8, and OpenShift
Real world #microservices with Apache Camel, Fabric8, and OpenShiftReal world #microservices with Apache Camel, Fabric8, and OpenShift
Real world #microservices with Apache Camel, Fabric8, and OpenShift
 
Real-world #microservices with Apache Camel, Fabric8, and OpenShift
Real-world #microservices with Apache Camel, Fabric8, and OpenShiftReal-world #microservices with Apache Camel, Fabric8, and OpenShift
Real-world #microservices with Apache Camel, Fabric8, and OpenShift
 
Advance Java Topics (J2EE)
Advance Java Topics (J2EE)Advance Java Topics (J2EE)
Advance Java Topics (J2EE)
 
Schema Evolution for Resilient Data microservices
Schema Evolution for Resilient Data microservicesSchema Evolution for Resilient Data microservices
Schema Evolution for Resilient Data microservices
 
AJppt.pptx
AJppt.pptxAJppt.pptx
AJppt.pptx
 
Java web services using JAX-WS
Java web services using JAX-WSJava web services using JAX-WS
Java web services using JAX-WS
 
Building WebLogic Domains With WLST
Building WebLogic Domains With WLSTBuilding WebLogic Domains With WLST
Building WebLogic Domains With WLST
 
Groovy & Grails eXchange 2012 vert.x presentation
Groovy & Grails eXchange 2012 vert.x presentationGroovy & Grails eXchange 2012 vert.x presentation
Groovy & Grails eXchange 2012 vert.x presentation
 
Node.js vs Play Framework
Node.js vs Play FrameworkNode.js vs Play Framework
Node.js vs Play Framework
 
Red Hat Agile integration Workshop Labs
Red Hat Agile integration Workshop LabsRed Hat Agile integration Workshop Labs
Red Hat Agile integration Workshop Labs
 
CloudConnect 2011 - Building Highly Scalable Java Applications on Windows Azure
CloudConnect 2011 - Building Highly Scalable Java Applications on Windows AzureCloudConnect 2011 - Building Highly Scalable Java Applications on Windows Azure
CloudConnect 2011 - Building Highly Scalable Java Applications on Windows Azure
 

Mais de JBug Italy

JBoss Wise: breaking barriers to WS testing
JBoss Wise: breaking barriers to WS testingJBoss Wise: breaking barriers to WS testing
JBoss Wise: breaking barriers to WS testingJBug Italy
 
Camel and JBoss
Camel and JBossCamel and JBoss
Camel and JBossJBug Italy
 
Faster & Greater Messaging System HornetQ zzz
Faster & Greater Messaging System HornetQ zzzFaster & Greater Messaging System HornetQ zzz
Faster & Greater Messaging System HornetQ zzzJBug Italy
 
JBoss BRMS - The enterprise platform for business logic
JBoss BRMS - The enterprise platform for business logicJBoss BRMS - The enterprise platform for business logic
JBoss BRMS - The enterprise platform for business logicJBug Italy
 
JBoss AS7 Overview
JBoss AS7 OverviewJBoss AS7 Overview
JBoss AS7 OverviewJBug Italy
 
Intro JBug Milano - September 2011
Intro JBug Milano - September 2011Intro JBug Milano - September 2011
Intro JBug Milano - September 2011JBug Italy
 
Infinispan and Enterprise Data Grid
Infinispan and Enterprise Data GridInfinispan and Enterprise Data Grid
Infinispan and Enterprise Data GridJBug Italy
 
Drools Introduction
Drools IntroductionDrools Introduction
Drools IntroductionJBug Italy
 
September 2010 - Gatein
September 2010 - GateinSeptember 2010 - Gatein
September 2010 - GateinJBug Italy
 
May 2010 - Infinispan
May 2010 - InfinispanMay 2010 - Infinispan
May 2010 - InfinispanJBug Italy
 
May 2010 - RestEasy
May 2010 - RestEasyMay 2010 - RestEasy
May 2010 - RestEasyJBug Italy
 
May 2010 - Drools flow
May 2010 - Drools flowMay 2010 - Drools flow
May 2010 - Drools flowJBug Italy
 
May 2010 - Hibernate search
May 2010 - Hibernate searchMay 2010 - Hibernate search
May 2010 - Hibernate searchJBug Italy
 
April 2010 - Seam unifies JEE5
April 2010 - Seam unifies JEE5April 2010 - Seam unifies JEE5
April 2010 - Seam unifies JEE5JBug Italy
 
JavaDayIV - Leoncini Writing Restful Applications With Resteasy
JavaDayIV - Leoncini Writing Restful Applications With ResteasyJavaDayIV - Leoncini Writing Restful Applications With Resteasy
JavaDayIV - Leoncini Writing Restful Applications With ResteasyJBug Italy
 
November 2009 - Walking on thin ice… from SOA to EDA
November 2009 - Walking on thin ice… from SOA to EDANovember 2009 - Walking on thin ice… from SOA to EDA
November 2009 - Walking on thin ice… from SOA to EDAJBug Italy
 
November 2009 - Whats Cooking At JBoss Tools
November 2009 - Whats Cooking At JBoss ToolsNovember 2009 - Whats Cooking At JBoss Tools
November 2009 - Whats Cooking At JBoss ToolsJBug Italy
 

Mais de JBug Italy (20)

JBoss Wise: breaking barriers to WS testing
JBoss Wise: breaking barriers to WS testingJBoss Wise: breaking barriers to WS testing
JBoss Wise: breaking barriers to WS testing
 
Camel and JBoss
Camel and JBossCamel and JBoss
Camel and JBoss
 
AS7 and CLI
AS7 and CLIAS7 and CLI
AS7 and CLI
 
Faster & Greater Messaging System HornetQ zzz
Faster & Greater Messaging System HornetQ zzzFaster & Greater Messaging System HornetQ zzz
Faster & Greater Messaging System HornetQ zzz
 
AS7
AS7AS7
AS7
 
JBoss BRMS - The enterprise platform for business logic
JBoss BRMS - The enterprise platform for business logicJBoss BRMS - The enterprise platform for business logic
JBoss BRMS - The enterprise platform for business logic
 
JBoss AS7 Overview
JBoss AS7 OverviewJBoss AS7 Overview
JBoss AS7 Overview
 
JBoss AS7
JBoss AS7JBoss AS7
JBoss AS7
 
Intro JBug Milano - September 2011
Intro JBug Milano - September 2011Intro JBug Milano - September 2011
Intro JBug Milano - September 2011
 
Infinispan and Enterprise Data Grid
Infinispan and Enterprise Data GridInfinispan and Enterprise Data Grid
Infinispan and Enterprise Data Grid
 
Drools Introduction
Drools IntroductionDrools Introduction
Drools Introduction
 
September 2010 - Gatein
September 2010 - GateinSeptember 2010 - Gatein
September 2010 - Gatein
 
May 2010 - Infinispan
May 2010 - InfinispanMay 2010 - Infinispan
May 2010 - Infinispan
 
May 2010 - RestEasy
May 2010 - RestEasyMay 2010 - RestEasy
May 2010 - RestEasy
 
May 2010 - Drools flow
May 2010 - Drools flowMay 2010 - Drools flow
May 2010 - Drools flow
 
May 2010 - Hibernate search
May 2010 - Hibernate searchMay 2010 - Hibernate search
May 2010 - Hibernate search
 
April 2010 - Seam unifies JEE5
April 2010 - Seam unifies JEE5April 2010 - Seam unifies JEE5
April 2010 - Seam unifies JEE5
 
JavaDayIV - Leoncini Writing Restful Applications With Resteasy
JavaDayIV - Leoncini Writing Restful Applications With ResteasyJavaDayIV - Leoncini Writing Restful Applications With Resteasy
JavaDayIV - Leoncini Writing Restful Applications With Resteasy
 
November 2009 - Walking on thin ice… from SOA to EDA
November 2009 - Walking on thin ice… from SOA to EDANovember 2009 - Walking on thin ice… from SOA to EDA
November 2009 - Walking on thin ice… from SOA to EDA
 
November 2009 - Whats Cooking At JBoss Tools
November 2009 - Whats Cooking At JBoss ToolsNovember 2009 - Whats Cooking At JBoss Tools
November 2009 - Whats Cooking At JBoss Tools
 

April 2010 - JBoss Web Services

  • 1. JBoss Web Services Alessio Soldano alessio.soldano@jboss.com Principal Software Eng. JBoss - Red Hat April 28th, 2010
  • 2. Who is Alessio? ● JBoss WS[1] committer since early 2007 ● JBoss / Red Hat employee since end of 2007 ● JBoss Web Service Lead, 2008 ● JBoss AS[2], JBoss Wise[3] contributor ● Current Red Hat representative at JSR-224 EG and W3C WS-ResourceAccess WG ● Apache CXF[4] committer since 2009 [1] http://www.jboss.org/jbossws [2] http://www.jboss.org/jbossas [3] http://www.jboss.org/wise [4] http://cxf.apache.org
  • 3. What is JBoss WS? ● “Just” a feature-rich JAX-WS compatible ws stack till early 2008... ● a web services framework providing integration layers for 3rd party ws stacks on top of multiple JBoss AS versions – CXF, Native and Metro stack – AS 5.x, AS 6.x target containers
  • 4. The benefits of standards / specs W3C standards allow for interoperability ● WS-Security <s:Envelope...> <s:Header> ● WS-Policy <o:Security...> ● WS-Addressing <u:Timestamp u:Id="..">...</u:Timestamp> <o:BinarySecurityToken...>...</o:BinarySecurityToken> ● ... <e:EncryptedKey...>...</e:EncryptedKey> <e:ReferenceList...>...</e:ReferenceList> <Signature xmlns="http://www.w3.org/2000/09/xmldsig#"> Defined way to: ... </Signature> ● format messages </o:Security> ● advertise services </s:Header> ● ... <s:Body>...</s:Body> </s:Envelope>
  • 5. The benefits of standards / specs JCP specs give us common dev API ● JSR-224 / JSR-181 (JAX-WS) ● JSR-109 (WS for JavaEE) EndpointService service = new EndpointService( ● JSR-101 (JAX-RPC) wsdlURL, serviceQName); ● JSR-261* (JAX-WSA) Endpoint port = service.getEndpointPort(); ● ... String retObj = port.echo(“Hello World”); @WebService(name = "Endpoint", serviceName = "EndpointService", targetNamespace = "http://org.jboss.ws/wsref") @SOAPBinding(style = Style.DOCUMENT, use = Use.LITERAL) public class EndpointImpl { @WebMethod(action = “echo”) public String echo(String input) { return input; } }
  • 6. Reasons for integrating ● really good open source implementations already available - NIH syndrome ● focus on added value ● open choice (features, performance, ...) ● ... a lot of Web Services specifications!
  • 8. Who benefits from this move? ● The JBoss community: – different choices depending on needs – greater joint community support – core devs can work on added value ● The integrated ws projects and their community: – additional tests – bugs detection and fix – ...
  • 9. JBoss WSF: high level overview
  • 10. Web Service Framework ● Management ● Tooling – console – common JAXWS tools – endpoint registry – project generator – records system – Eclipse integration ● Configuration ● AS integration – address rewrite – authentication ● Features – authorization – JAXBIntroductions ● Common deploy – Common JAX-WSA JSR- ● Common testsuite 261 API
  • 11. Do I really need your integration layer? ● Home-brew solutions for running CXF / Metro on JBossAS might work for specific usecases, but you... – need to embed the stack in your apps – will suffer from classloading issues – can just use pojo endpoints – have no webserviceref injection in ejb3 – loose additional WSF features ;-) – ...
  • 12. How it works - deployment ● POJO endpoint <web-app ...> @WebService(...) <servlet> public class MyEndpoint { <servlet-name>TestService</servlet-name> public String sayHello() { <servlet-class>org.jboss.test.ws.jaxws.samples.MyEndpoint</servlet-class> return "Hello World!"; </servlet> } <servlet-mapping> } <servlet-name>TestService</servlet-name> <url-pattern>/*</url-pattern> </servlet-mapping> </web-app> ● EJB3 endpoint @WebService(...) @Stateless public class MyEndpoint { Create metadata to public String sayHello() { return "Hello World!"; deploy jboss-web app } }
  • 13. How it works - deployment ● Parse or generate proprietary descriptor – jboss-cxf.xml for CXF stack (Spring conf) – sun-jaxws.xml for Metro stack ● Setup different endpoint servlets for each stack – extending CXFServlet for CXF stack
  • 14. How it works - runtime ● Request handlers: called by enpdoint servlet to serve GET / POST requests; delegate to – CXF ServletController – Metro ServletAdapter ● Invokers: route invocation to JBossAS (JBoss EJB3 layer for ejb3 endpoints) – configured during proprietary descriptor processing / creation
  • 15. How it works - runtime Request Endpoint servlet RequestHandler WS-* ... Invoker CXF JBoss or AS Metro JAX-WS ... handlers Response
  • 16. More on deployers... JBoss AS 5 deployers gives high flexibility ● multiple webservice deployers generated – stack agnostic deployment aspects – stack specific deployment aspects – extensibility, separation of concerns, ... ● two webservice stacks at the same time – JAX-RPC support with CXF / Metro
  • 17. CXF: additional integration hooks ● Bus configuration: CXF runtime behaviour is controlled by the current Bus; we can set: – custom resource resolvers – custom transport factories – custom CXF Configurer bean – ... ● Spring Namespace Handlers: we can change configuration namespace to default bean mapping – override / extend core CXF beans
  • 18. Some links... ● http://www.jboss.org/jbossws ● http://community.jboss.org/wiki/JBossWS ● http://jbossws.blogspot.com/
  • 19. Q&A