Is there some feature similar to Oracle Policy Automation - Oracle Web Determinations in Drools ? How can this be achieved using Drools ?
-
Drools is a production rule system and does not contain any "features similar to X" unless X is another rule based system. Drools is Turing-complete, so anything that can be programmed can be achieved using Drools. As to the how: hire a consultant. – laune Oct 13 '14 at 06:20
1 Answers
I am working both in Oracle Policy Automation and Drools. From my observation OPA is purely automated ofcourse it needs licencing too. Whereas Drools is open source. It lacks so many things when compared to OPA. But, so far I have not faced any issue with Drools.
As far as the Oracle Web Determinations screens in OPA I think there is no build in feature in Drools to replicate it. As Drools is purely based on coding you can achieve anything if you can code. You can create jsp pages, do internal binding, collect data from screens and set to the class object. Finally on a button press on the screen you can pass this object which has the screen data to the Drools rule engine.
As my project doesn't require screens I test by creating objects of the classes. Then I will hard-code data to the class object attributes. See the code given below;
public static final void main(String[] args) {
try {
// load up the knowledge base
KieServices ks = KieServices.Factory.get();
KieContainer kContainer = ks.getKieClasspathContainer();
KieSession kSession = kContainer.newKieSession("ksession-process");
// start a new process instance
MainGlobal mainGlobal = MainRequestFactory.getMainRequest();
kSession.insert(mainGlobal);
System.out.println("======== START PROCESS ========");
} catch (Throwable t) {
t.printStackTrace();
}
}
MainGlobal
- is my class. I get a object of the class with data hard-coded by calling MainRequestFactory.getMainRequest();

- 53
- 2
- 10