Deployment Descriptor File: services.xml
Each web service class requires an Axis2 deployment descriptor file called services.xml. Use this information to learn about the services.xml file.
Descriptor File Contents
The Cúram build automatically generates a suitable deployment descriptor for the default settings that are described in Inbound Web Service Properties File and Inbound Web Service Properties: ws_inbound.xml. The format and contents of the services.xml are defined by Axis2. For more information, see the Apache Axis2 Configuration Guide (http://axis.apache.org/axis2/java/core/docs/axis2config.html.
Based on the settings from the ws_inbound.xml property files the app_webservices2.xml script generates a services.xml file for each web service class. This descriptor file contains a number of parameters that are used at runtime to define and identify the web service and its behavior.
<serviceGroup>
<service name="ServiceName">
<!-- Generated by app_webservices2.xml -->
<description>
Axis2 web service descriptor
</description>
<messageReceivers>
<messageReceiver
mep="http://www.w3.org/2004/08/wsdl/in-out"
class=
"curam.util.connectors.axis2.CuramXmlDocMessageReceiver"/>
<messageReceiver
mep="http://www.w3.org/2004/08/wsdl/in-only"
class=
"curam.util.connectors.axis2.CuramInOnlyMessageReceiver"/>
</messageReceivers>
<parameter
name="remoteInterfaceName">
my.package.remote.ServiceName</parameter>
<parameter
name="ServiceClass" locked="false">
my.package.remote.ServiceNameBean</parameter>
<parameter
name="homeInterfaceName">
my.package.remote.ServiceNameHome</parameter>
<parameter
name="beanJndiName">
curamejb/ServiceNameHome</parameter>
<parameter
name="curamWSClientMustAuthenticate">
true</parameter>
<parameter
name="providerUrl">
iiop://localhost:2809</parameter>
<parameter
name="jndiContextClass">
com.ibm.websphere.naming.WsnInitialContextFactory
</parameter>
<parameter
name="useOriginalwsdl">
false</parameter>
<parameter
name="modifyUserWSDLPortAddress">
false</parameter>
<!--
NOTE: For any In-Only services (i.e. returning void) you must
explicitly code those operation names here as per:
http://issues.apache.org/jira/browse/AXIS2-4408
For example:
<operation name="insert">
<messageReceiver
class="curam.util.connectors.axis2.
CuramInOnlyMessageReceiver"/>
</operation>
-->
</service>
</serviceGroup>
The following lists the mapping of the services.xml parameters to the settings in your build environment:
- messageReceiver
- Specifies the appropriate receiver class for the MEPs of the service. For Cúram there are three
available settings/classes:
curam.util.connectors.axis2.CuramXmlDocMessageReceiver- For service classes that process W3C Documents as arguments and return values.curam.util.connectors.axis2.CuramMessageReceiver- For service classes that process Cúram classes and use the in-out MEP.curam.util.connectors.axis2.CuramInOnlyMessageReceiver- For service classes that process Cúram classes and use the in-only MEP.
This value is set by the app_webservices2.xml script as per the description above. (Required)
- remoteInterfaceName, ServiceClass, homeInterfaceName, beanJndiName
- Specify the class names and JNDI name required by the receiver code for invoking the service via
the facade bean.
These values are set by the app_webservices2.xml script based on the generated classname value in the ws_inbound.xml properties file. (Required)
- curamWSClientMustAuthenticate, jndiUser, jndiPassword
- Specify credential processing and credentials for accessing the operations of the web service
class.
These are set by the app_webservices2.xml script based on the corresponding properties in ws_inbound.xml (see Inbound Web Service Properties File). Default for curamWSClientMustAuthenticate is true, but can be overridden at runtime by custom receiver code. (Optional)
- providerUrl, jndiContextClass
- Specify the application server-specific connection parameters.
These values are set by the app_webservices2.xml script based on your AppServer.properties settings for your as.vendor, curam.server.port, and curam.server.host properties. Can be set at runtime by custom receiver code. (Optional)
- useOriginalwsdl, modifyUserWSDLPortAddress
- Specify the processing and handling of WSDL at runtime.
These are explicitly set to false by the app_webservices2.xml script due to symptoms reported in, for instance, Apache Axis2 JIRA: AXIS2-4541. (Required for proper WSDL handling.)