Search

Resume and bio of the author Couple of articles related to my hobby - robotics
My impressions about immigration to Australia. In Russian only. Recipes for everyday problems solving
Linux-related posts Windows-related posts
Software-related posts A lot of info about hardware
Different tools you might find useful Posts about various web technologies
Everything that doesn't fit the rest of the menu RSS feed for this blog

Tag Cloud

Archives

Links

Andrey Mikhalchuk’s Blog

Technoblog about life

Apr 8, 2013 How to call Oracle Policy Automation via SOAP/WSDL

As you probably read in my other post, OPA is a great alternative to the Oracle Business Rules (OBR) as all the business logic could be exposed via web services. Unfortunately Oracle didn’t leave us much documentation about how to do that. So if you’re wondering how do you call OPA determinations server, here is an example:


If you open the determinations server URL on your weblogic server (something like http://yourserver:7001/determinations-server) you will see whole bunch of interfaces exposed for each ruleset:

  • interface for listing all available interfaces
  • version-specific interfaces
  • non-version specific version of the interface, which is actually a link to the most recent version

Version-specific interfaces are divided into generic and specific interfaces. Specific interface provides all the attribute names in the interface. Generic is more flexible, you specify your parameters as a list of keyvals. This example is the non-version-specific generic interface call:

<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:typ="http://oracle.com/determinations/server/10.4/rulebase/assess/types">
<soapenv:Header/>
<soapenv:Body>
<typ:assess-request>
<typ:config>
<typ:show-silent>true</typ:show-silent>
<typ:show-invisible>true</typ:show-invisible>
<typ:show-properties>true</typ:show-properties>
<typ:show-events>true</typ:show-events>
<typ:resolve-indecision-relationships>true</typ:resolve-indecision-relationships>
</typ:config>
<typ:global-instance>
<typ:entity id="household">
<typ:instance id="1">
<typ:attribute id="INPUT" outcome-style="value-only">
<typ:text-val>input_value</typ:text-val>
</typ:attribute>
<typ:attribute id="RESULT" inferred="true" outcome-style="value-only" />
</typ:instance>
</typ:entity>
</typ:global-instance>
</typ:assess-request>
</soapenv:Body>
</soapenv:Envelope>


This post is published in How To, Other.

No comments

No comments so far

Leave a Reply

You must be logged in to post a comment.

Site Map (c) Andrey Mikhalchuk, 2005-2008