In order to invoke a specific Major.Minor version of a Decision Service, the Major.Minor version number must be included as a value of the decisionServiceTargetVersion attribute in the message sample, as shown above.
As the use attribute indicates, specifying a Major.Minor version number is optional. If multiple Major.Minor versions of the same Decision Service Name are deployed simultaneously and an incoming request fails to specify a particular Major Version number, then Corticon Server will execute the Decision Service with highest version number.
If multiple instances of the same Decision Service Name and Major version number are deployed and an incoming request fails to specify a Minor version number, then Corticon Server will execute the live Decision Service with highest Minor version number of the Major version. For example, if you have 2.1, 2.2, and 2.3, and you specify 2, your request will be applied as 2.3. Note that this applies to LIVE Decision Services and not TEST Decision Services: they require a Major.Minor version.
Note: Refer to Service contract examples for full details of the XML service contracts supported (XSD and WSDL).
Let's try a few invocations using variations of the following message:
Copy this text and save the file with a useful name such as Request_noDates_1.0.xml in a local folder.
Run testServerAxis and then choose command 130 to execute the request. After it runs, you are directed to the output folder to see the result, which look like this:
<?xml version="1.0" encoding="UTF-8"?> <soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"> <soapenv:Body> <ns1:CorticonResponse xmlns:ns1="urn:decision:tutorial_example" xmlns="urn:decision:tutorial_example" decisionServiceName="skydiver4_noDates" decisionServiceTargetVersion="1.0"> <ns1:WorkDocuments> <ns1:Person id="Person_id_1"> <ns1:age>30</ns1:age> <ns1:riskRating>low</ns1:riskRating> <ns1:skydiver>false</ns1:skydiver> <ns1:ssn>111-11-1111</ns1:ssn> </ns1:Person> </ns1:WorkDocuments> <ns1:Messages version="1.0"> <ns1:Message> <ns1:severity>Info</ns1:severity> <ns1:text>A person 35 years old or younger is rated as low risk.</ns1:text> <ns1:entityReference href="#Person_id_1" /> </ns1:Message> </ns1:Messages> </ns1:CorticonResponse> </soapenv:Body> </soapenv:Envelope>
Note that the age stated is 35, which is what we defined version 1.0 of the Decision Service. This should be no surprise – we specifically requested version 1.0 in our request message. Corticon Server has honored our request. .
Let's prove the technique by editing the request message to specify another version: