This example shows how to use JAX-WS to implement a SOAP service.
This example uses blueprint to deal with the jaxws-server and Apache CXF as the implementation of the JAXWS specification.
It implements a
BookingService with a SOAP WS implementation.
The “client” bundle uses the
BookingService with a SOAP client stub.
BookingPOJO and the
BookingServiceSoapimplementation of the
The build uses Apache Maven. Simply use:
mvn clean install
On a running Karaf instance, register the features repository using:
karaf@root()> feature:repo-add mvn:org.apache.karaf.examples/karaf-soap-example-features/LATEST/xml
Then, you can install the service provider feature:
karaf@root()> feature:install karaf-soap-example-provider
And the service client feature:
karaf@root()> feature:install karaf-soap-example-client
You can take a look on the WSDL generated for our SOAP WS:
The client feature installs
booking:* commands. You can add a new booking using the
karaf@root()> booking:add 1 TEST TEST
booking:list command displays the list of bookings:
karaf@root()> booking:list ID | Flight | Customer ----------------------- 1 | TEST | TEST
These commands use a CXF SOAP WebService client to interact with the Booking WebService.