hi folks
We are working on a requirement that requires us to have multiple rules that
could fire for a given input and for all the rules that fire, we would want
to cumulate the consequence to reach the final consequence.
As an example, if we want to identify the credit score for a person,
Why not use a Fact that contains your result?
In DRL terms it'd look like this:-
rule one
when
$r : Result( $score : score )
Applicant( numberOfLoans 1 )
then
$r.setScore( $score + 5 );
update( $r );
end
rule two
when
$r : Result( $score :
Thanks a billion mantis!
We do think this would work; let me try it and confirm.
--
View this message in context:
http://drools.46999.n3.nabble.com/Rules-that-cumulate-on-consequence-tp3530214p3530252.html
Sent from the Drools: User forum mailing list archive at Nabble.com.
Good idea,
but note that it will only work properly in a stateless session (which
is most likely in his case).
In a stateful session, with multiple fireAllRules and when the
applicant's properties change between those fireAllRules call,
the trick is to do an insertLogical of a ScoreDiff
Do you mean the Guvnor package editor?
I don't use Guvnor. How can I generate the document from command line like
mvn?
--
View this message in context:
http://drools.46999.n3.nabble.com/Does-drools-support-rule-doc-tp3529621p3530488.html
Sent from the Drools: User forum mailing list archive
How can I change Guvnor interface language?
--
View this message in context:
http://drools.46999.n3.nabble.com/How-to-change-Guvnor-language-tp3530505p3530505.html
Sent from the Drools: User forum mailing list archive at Nabble.com.
___
rules-users
I have imported some rules and models in a package in Guvnor. How can I
delete some of them from the package?
--
View this message in context:
http://drools.46999.n3.nabble.com/How-to-delete-fact-in-Guvnor-tp3530688p3530688.html
Sent from the Drools: User forum mailing list archive at
I have created a package in duvnor. Can I upload other drl files to this
package?
--
View this message in context:
http://drools.46999.n3.nabble.com/How-can-I-import-a-drl-file-in-a-package-in-duvnor-tp3530871p3530871.html
Sent from the Drools: User forum mailing list archive at Nabble.com.
Guvnor is localised to the following locale:-
- es_ES
- fr_FR
- ja_JP
- pt_BR
- zh_CN
The default language for messages etc when no locale is provided (or is
unavailable) is English.
Provided you are using the downloaded WAR, or you have compiled from source
using the full
go to that folder and archive it
On Wed, Nov 23, 2011 at 7:39 AM, Zhao Yi zhaoyi0...@gmail.com wrote:
I have imported some rules and models in a package in Guvnor. How can I
delete some of them from the package?
--
View this message in context:
Hi - I am a Drools newbie and I apologize in advance if the answer to my
question is intuitively obvious to the casual user.
I have an object that has two fields: location(there are more than 50
locations) and age. I am having difficulty building clean rules for the
following pseudo-code
//
Hi all,
I encountered the following issue:
As an example TaskConectxt() holds a list of time related objects called
times.
I would like to write a rule which ideally would filter the TaskContext
according to a specific time object.
The problematic restriction is that this time object
It will work properly in a stateless session ... in sequential mode ...
may be.
This rule for instance, will loop by itself (and all other will also
loop), in a stateless or statefull session :
rule one
when
$r : Result( $score : score )
Applicant( numberOfLoans 1 )
Hello,
I'm a newbie to drools.
I would like to know why i get the following output on the console :
Test Message found!!
No strange message :-)
Test Message found!!
Test Message found!!
NotifyEngineTest.java creates 10 events. Rule test2 should be activated
with every event,
so that the
I think this could work :
*rule*verify time
*when*
$now: java.util.Date() from getTimeByID(ETimeID.NOW)
$tc: TaskContext(times *contains*$now)
*then*
//something
*end*
or an eval :
*rule*verify time
*when*
$tc: TaskContext(eval(
rule test2
salience 5
when
not ( Event( (system == anySystem catagory == anyCatagory ) ||
(system == anyHost message matches .*Hello.*)))
then
System.out.println( No strange message :-) );
end
Hi,
Probably it is because you are using NOT (). The engine will not fire this
rule for
Hi,
If you do not want to check for all alternative cases, you might need a
showstopper to stop the firings of unwanted rules.
This can be achieved by executing insert(new ShowStopper() ); in your RHS.
All LHS of the rules will check for not( ShowStopper() )
Alternatively, you can use the new
Or you can use Guvnor tables and otherwise special value (see doc on
tables under guvnor)
Le 23/11/2011 17:14, FrankVhh a écrit :
Hi,
If you do not want to check for all alternative cases, you might need a
showstopper to stop the firings of unwanted rules.
This can be achieved by
Hi,
Sorry, but I fogot about you :-(.
It does not work because both wolfgang and I did get your question wrong.
If I were you, I would try to work from the opposite direction and check
whether a String matches S but not SF. Than replace that S by VOL.
A second rule could than safely check for
Yay, a great improvement :)
2011/11/23 Vincent Legendre vincent.legen...@eurodecision.com
It will work properly in a stateless session ... in sequential mode ...
may be.
This rule for instance, will loop by itself (and all other will also
loop), in a stateless or statefull session :
rule
I dont see any SQL Exceptions in the log, probably means that all journal
entries did make it to database. How can I figure out how/when/for how long/
the sync messages got lost? I have logs enabled at INFO and I dont see any
WARNING's or ERROR's.
--
View this message in context:
And it wont allow me to re-import the whole repository! How can I fix it?!
ERROR 23-11 10:21:30,264
(RulesRepositoryAdministrator.java:clearRulesRepository:96) Unable to
clear rules repository.
javax.jcr.ReferentialIntegrityException:
98096f69-7629-4083-95e7-73402a6f511e: the node cannot be
Yes.
The DRL file must either specify the package name that it will be imported to,
or the package declaration line must be missing completely -- when missing
Drools Guvnor prompts for the package name.
To import DRL, select the option to create a new Package. Then select the
radio button
And after deleting the fact, you can go to Administration, and remove the
Archive if you are absolutely sure you want it gone.
-Original Message-
From: rules-users-boun...@lists.jboss.org
[mailto:rules-users-boun...@lists.jboss.org] On Behalf Of G S
Sent: Wednesday, November 23, 2011
Wrap in in ()'s like this:
$tc : TaskContext( times contains (getTimeByID(ETimeID.NOW)) )
I have not personally tried this exact scenario, but the concept is the same as
other scenarios I use this for. The ()'s identifies that evaluation should be
used here, except that it's not
Try this:
rule 'Rule One'
activation-group 'age-test'
salience 300
when
Person (location == 'A', age 60 )
Then
do_something();
end
rule 'Rule Two'
activation-group 'age-test'
salience 200
when
Person (location == 'B', age 70 )
Then
do_something();
end
rule
As an aside note. You may want to consider re-working your rules to never use
the || condition.
It's not that this is inherently bad, but that the any logical ORs mean that
you are actually representing more than one rule within the singular rule.
This can make mapping the logic to the
Armand
I don't think that works if location=='B' and age=68
___
rules-users mailing list
rules-users@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/rules-users
Hi,
you might try something like one of the following two variants:
a) Checking for Location only first, inserting a Fact for the respective
location and doing a second rule for each location that checks for this fact
and the age (using salience to ensure only one rule fires and this in the
If you know that your export is good, then you could backup the directory that
contains your guvnor repository (rename it) while guvnor is off-line.
Then start guvnor with an empty repository -- this will force guvnor to
initialize the repository.
Next simply launch Guvnor, and import your
Oh... I misread the pseudo code. I missed that the if (age60) is inside the
if(location==A) rule. This is easy enough to fix. It's would essentially be
the same thing as the otherwise, but in DRL:
rule 'Rule One'
activation-group 'age-test'
salience 300
when
Person
Sorry to repost again But I also realized after sending that if you have
to exclude locations A, B, and C from the else rule, then you do not need
salience, nor activation group, since all the rules are not mutually
exclusive.. This this (much easier too now)
rule 'Rule One'
when
I use database as the store for assets. I was thinking of asking DBA's to
just wipe out all the tables and then re-import. I am assuming the export is
healthy because when I imported it into a test environment it worked well.
I am not too concerned about getting things back up. I am more
now i try import the model i declared in drl file use package.
it works for me .
maybe the model must have a package.
--
View this message in context:
http://drools.46999.n3.nabble.com/calling-function-defined-in-drl-file-from-ruleflow-tp3525538p3532717.html
Sent from the Drools: User forum
34 matches
Mail list logo