Configuring the Action Property

WS-Addressing defines two mechanisms to associate a value of the [action] property with input, output, and fault elements within a WSDL description: explicit association and default association.

Explicit Association

In an explicit association, the [action] property value is set from the value of the Action elements specified for the input, output, and fault messages or the value of the soapAction attribute set in the transport header.

<?xml version="1.0" encoding="utf-8"?>
<definitions targetNamespace="someuri">
<portType name="Hello_PortType">
  <operation name="sayHello">
    <input message="SayHelloRequest" wsam:Action="http://tibco.com/HelloService/Request"/>
    <output message="SayHelloResponse" wsam:Action="http://tibco.com/HelloService/Response"/>
  </operation>
</portType>

Input message [action] = "http://tibco.com/HelloService/Request"
Output message [action] = "http://tibco.com/HelloService/Response"

Default Association

If neither the Action elements or soapAction attribute is specified, the [action] property value is constructed as follows:

  • Input and output messages

    targetnamespace/porttypename/messagename

  • Fault message

    targetnamespace/porttypename/operationname/Fault/messagename

<?xml version="1.0" encoding="utf-8"?>
<definitions targetNamespace="http://tibco.com/defaulting ">
<portType name="Hello_PortType">
  <operation name="sayHello">
    <input message="SayHelloRequest"/>
    <output message="SayHelloResponse" />
    <fault message="InvalidMessage" name="InvalidRequest"/>
  </operation>
</portType>

Input message [action] = 
 "http://tibco.com/defaulting/ Hello_PortType/SayHelloRequest"
Output message [action] = 
 "http://tibco.com/defaulting/ Hello_PortType/SayHelloResponse"
Fault message [action] = 
 "http://tibco.com/defaulting/Hello_PortType/ sayHello/Fault/InvalidRequest"