Resolve Service Assertion

The Resolve Service Assertion serves two purposes:
gateway91
The
Resolve Service Assertion
serves two purposes:
  • When placed in a
    message-received
    global policy fragment, this assertion does the following
    1. Overrides the normal Gateway service resolution logic.
    2. Routes the message to the service associated with the URI specified in the assertion properties.
  • When placed anywhere else, this assertion does the following:
    1. Looks up the name and GUID of the service at the specified URI 
    2. Places the name and GUID into context variables. 
Normal service resolution logic prevails in this scenario.
One useful application of this assertion: use an Evaluate Request XPath assertion to seek a particular element (for example, "//ns:SpecialElement"). If this element is present, the Resolve Service assertion routes the request to a particular URI (for example, "/specialElementHandler"). If this element is not present, then the message routes using the normal service resolution process.
This assertion is designed for WSDL lookup scenarios, to implement your own policies for security or  WSDL rewriting.
Context Variables
This assertion populates the following variables with information from the resolved service:
Variable
Description
 
<prefix>
.name
Service name (analogous to the
${service.name}
variable)
<prefix>
 
.oid
Service identifier (analogous to the
${service.oid}
variable)
<prefix>
.soap
Boolean indicating whether this a SOAP service (true/false)
Cluster Properties
None
Properties
Setting
What you should know...
URI Path
The request may or may not resolve to this path, depending on the placement of the assertion in a policy.
You can use the
${request.url.path}
variable to specify the URI path. This variable returns the path of the Gateway URL where the message was received.
Variable Prefix
A prefix is required.
Frequently Asked Questions
Question
Answer
Where can I learn more about the Gateway's service resolution logic?
What is the "message-received" global policy?
This type of policy fragment runs when a message is received, but before the service is resolved. For more information, see Global Policy Fragments.