[rules-users] Conflict detection problem

AlisterC alister.crepy at dps-fr.com
Fri Mar 11 04:26:47 EST 2011


Greetings,

I am working on a collaborative platform project which will contain datas,
informations and knowledges
such as buisness rules. Consequently, a rule engine is a requisite and I am
testing the Drools suite.

Because a lot of different people will be able to define rules, some
combinations might be contradictory.
So the rule user need to know which rules are in conflict, and eventually
choose the ones to disabled to fix the problem.

Here is my use case : I fill in a java class some information about a
people, his hame and his age, and I want to check if he is an adult.
Two different users have written a rule to check this. The first, living in
place where a 18 years old people is an adult wrote this rule :
___________________________________________
rule "Is Major"
	when
		$a : Applicant (age >= 18)
	then 
		$a.setMajor( true );

end
___________________________________________

The second one, write this one :
___________________________________________
rule "Is Minor"
	when
		$a : Applicant (age < 21)
	then 
		$a.setMajor( false );

end
___________________________________________

I've tried to solve this knowledge base with a 19 years old people, but no
conflict was detected.
In fact the rules are executed sequentially and the result depends of the
order the rules are called.

My use case is very simple, but I think I am not considering it correctly.
Or maybe it is impossible with forward chaining ?

Does anyone can help me to solve this problem, by telling what is wrong or
giving me some internet ressource link ?

Thanks a lot in advance.

--
View this message in context: http://drools-java-rules-engine.46999.n3.nabble.com/Conflict-detection-problem-tp2664121p2664121.html
Sent from the Drools - User mailing list archive at Nabble.com.



More information about the rules-users mailing list