Combining JAX-WS and JAX-RS - 6.3

Talend ESB Service Developer Guide

EnrichVersion
6.3
EnrichProdName
Talend Data Fabric
Talend Data Services Platform
Talend ESB
Talend MDM Platform
Talend Open Studio for ESB
Talend Real-Time Big Data Platform
task
Design and Development
Installation and Upgrade
EnrichPlatform
Talend ESB

Starting with the JAX-RS development is not necessarily all or nothing decision. Some users may want to start developing new web services using JAX-RS while some will prefer continue building on their SOAP WS experience. Sometimes migrating the advanced SOAP services is not an option at all. CXF provides the production-quality environment for SOAP and RESTful web services be developed and combined if needed.

The real world Java-based web services projects will often combine all sort of web services, some of them written using JAX-WS and some JAX-RS. One obvious option for combining JAX-WS and JAX-RS services in CXF is to register multiple JAX-WS and JAX-RS service endpoints all referencing the same service bean. The SOAP WS and REST approaches are different but nothing prevents JAX-WS and JAX-RS service beans delegating to some shared implementation, for example, the one reading or writing data to the database.

Often enough, the SOAP developers who would like to experiment with JAX-RS or make their SOAP services more HTTP-centric, wish to reuse the same code serving both SOAP and plain HTTP requests. CXF lets do the combinataion using either the Java-First or WSDL-first approach.