JAX-WS application deployment model

The administration function of the product is enhanced to support installing and deploying Java™ Application Programming Interface (API) for XML Web Services (JAX-WS) applications like any other WebSphere® Application Server applications.

A JAX-WS application is packaged as a web application archive (WAR) file or a WAR module within an Enterprise Archive (EAR) file. The JAX-WS application deployment model is similar to the Java API for XML Remote Protocol Call (JAX-RPC) web services application model. The main differences are JAX-RPC web services application requires you to add additional bindings and deployment descriptors for application deployment. A JAX-WS application does not require additional bindings and deployment descriptors for deployment. You can deploy your JAX-WS applications as you would deploy any other WebSphere Application Server application.

JAX-WS web services is a rewrite of JAX-RPC web services. The table compares the web services stack for both JAX-WS and JAX-RPC web services.

JAX-RPC web services JAX-WS web services
Bindings are proprietary Bindings are based on the open source Java API for XML Bindings (JAXB)
Parsing is proprietary Parsing is based on the open source Java Specification Request (JSR) 173
No Java annotations support Support for Java annotations such as @WebService, @WebMethod, @WebParam, @WebResult, and @SOAPBinding
During deployment, some deployment descriptor files are created in a JAX-RPC based service and client.
The following files are created on the services side, when it is an EJB based web service and EJB based module:
  • webservices.xml
  • <name_of_service>_mapping.xml
  • ibm-webservices-bnd.xmi
  • ibm-webservices-ext.xmi
When the service is a JavaBeans-based or web module-based service, the following files and deployment descriptors are required:
  • webservices.xml
  • <name_of_service>_mapping.xml
  • In the web.xml file, there is no additional content
  • ibm-webservices-bnd.xmi
  • ibm-webservices-ext.xmi
The web.xml exists in both EJB and JavaBeans based services. However, there is no additional content added to the file during deployment of a Web service application or module.

For JAX-WS web services, the use of the webservices.xml deployment descriptor is optional because you can use annotations to specify all of the information that is contained within the deployment descriptor file. You can use the deployment descriptor file to augment or override existing JAX-WS annotations. Any information that you define in the webservices.xml deployment descriptor overrides any corresponding information that is specified by annotations.

Starting with WebSphere Application Server Version 7.0 and later, Java EE 5 application modules (web application modules version 2.5 or later, or EJB modules version 3.0 or later) are scanned for annotations to identify JAX-WS services and clients. However, pre-Java EE 5 application modules (web application modules version 2.4 or before, or EJB modules version 2.1 or before) are not scanned for JAX-WS annotations, by default, for performance considerations. In the Version 6.1 Feature Pack for Web Services, the default behavior is to scan pre-Java EE 5 web application modules to identify JAX-WS services and to scan pre-Java EE 5 web application modules and EJB modules for service clients during application installation. Because the default behavior for WebSphere Application Server Version 7.0 and later is to not scan pre-Java EE 5 modules for annotations during application installation or server startup, to preserve backward compatability with the feature pack from previous releases, you must configure either the UseWSFEP61ScanPolicy property in the META-INF/MANIFEST.MF of a web application archive (WAR) file or EJB module or define the Java virtual machine custom property, com.ibm.websphere.webservices.UseWSFEP61ScanPolicy, on servers to request scanning during application installation and server startup. To learn more about annotations scanning, see the JAX-WS annotations information.