Rule project referencing
by GPatel@tsys.com
Hello
I am looking for a comparable feature in drools that works similar to
"rule project inheritance" in ILOG JRules.
In JRules, one can define a rule project A that contains all the
base-level rules. Then, a new rule project B can be defined that
"references" rule project A. This automatically makes all the rules
defined in rule project A available in project B. One can then add to that
set of rules by defining new rules in project B or override specific rules
in project A. This feature is very handy for setting up client-specific
rules. You can start out with a vanilla set of rules specified in project
A. If a particular client wants additional rules (or wants to override the
default functionality), a new rule project B can be created for that
client that references project A and has the additional rules. No need to
copy-paste all the rules from A to B. That way, if a rule is fixed in A,
all referencing child projects instantly benefit from the update.
Is there a similar feature in drools or a way to achieve the same
functionality?
Thanks
gpatel
-----------------------------------------
The information contained in this communication (including any
attachments hereto) is confidential and is intended solely for the
personal and confidential use of the individual or entity to whom
it is addressed. If the reader of this message is not the intended
recipient or an agent responsible for delivering it to the intended
recipient, you are hereby notified that you have received this
communication in error and that any review, dissemination, copying,
or unauthorized use of this information, or the taking of any
action in reliance on the contents of this information is strictly
prohibited. If you have received this communication in error,
please notify us immediately by e-mail, and delete the original
message. Thank you
15 years, 3 months
Questions regarding Guvnor
by Harshit Bapna
Hello All,
Few questions:
1. What is the release date of Guvnor 5.2 ? (Couldn't find it from the site
of the documentation)
I am interested in the functionality to add the guvnor editors in
another app for rule editing.
2. I have created sub categories under categories using guvnor. Rules
created are associated to the subCategory.
Can I excess the subCategories rules using HTTP request or
KnowledgeAgent ?
for ex: *
http://localhost:8080/drools-guvnor/org.drools.guvnor.Guvnor/package/MI4/
MI4-Sub/LATEST.drl*
I am not able to successfully get the knowledgeBase using this url in my
changeSet.xml
Thanks.
Harshit
15 years, 3 months
Re: [rules-users] timer and duration - and please not the PS!
by Wolfgang Laun
Ooh, it seems Eclipse outwitted me once again. But I think I made it on the
2nd try...
Sorry
W
PS:
(1) A decision on the matter of DSL variables would be appreciated. I'm
currently
developing a non-trivial DSL, and learning a lot about what's needed for a
*real world *application. Most importantly, some means of structuring the
DSL definition, so that they can be applied distinctively to specific groups
of
rules. This reduces the risk of "ricochets" if you know what I mean.
I've thought about proposing an entirely new approach, based on DRL
syntactic
entities, i.e., the expansion of a DSL phrase must be a "medium level"
non-terminal
of the DRL language. But this certainly restricts phrase parameters to
terminals.
If it's too sophisticated, you end up with a parser/compiler almost as nasty
as ANTLR3.
(2) I haven't forgotten the spreadsheet fixes. There's another relic I
found: some of
the column keywords have single letter alternatives (e.g. "U" for "no-loop",
"X" for
"activation-group"). Should I retain them - they are NOT documented in
Expert.
Should I add timer(int:)? Duration is deprecated, I'll leave this in but it
ought to
be marked clearly as such in the documentation, at least.
Please advise - I can live with everything - non of this is important for
my company,
but I want to get the fixes and additions out of my thinning hair ;-)
On 11 December 2010 00:00, Mark Proctor <mproctor(a)codehaus.org> wrote:
> On 10/12/2010 08:44, Wolfgang Laun wrote:
> > Done. There are two FIXME-tests at the end, one for timer() + not; the
> other one
> > demonstrating that drools.halt() from a rule with a timer() doesn't
> > terminate the
> > session - it also keeps firing. Notice that even with no timer() on
> > the "halt" rule
> > but with another rule having a periodic timer "overrules" the
> drools.halt().
> Did you commit? as I'm not seeing anything in trunk.
>
> http://fisheye.jboss.org/changelog/JBossRules/trunk/drools-compiler/src/t...
>
> Mark
> > -W
> >
> >
> > 2010/12/10 Mark Proctor<mproctor(a)codehaus.org>:
> >> On 09/12/2010 14:50, Wolfgang Laun wrote:
> >>
> >> I can confirm that the timer rule continues to fire
> >> - if the condition contains a not CE
> >> - even after the not CE should return false
> >>
> >> Repeating timer firing stops for "positive" CEs turning to false.
> >>
> >> sounds like a bug :(
> >>
> >> Wolfgang, could you commit your test to TimerAndCalendarTest. Take a
> look at
> >> the tests there and follow a similar format, generally when there is
> only
> >> one or two small rules we prefer to inline the text rather than
> externalise
> >> it in a file, see testIntervalTimer
> >>
> >> So that it doesn't break hudson add FIXME to the start of the rule name,
> >> such as
> >> FIXME_testTimerWithNot
> >>
> >> Ideally open a jira and when you commit the code put the jira id in the
> >> commit messgae along with the jira title and a message something like
> >> "adding failing unit test"
> >>
> >> Thanks
> >>
> >> Mark
> >>
> >> -W
> >>
> >>
> >> On 9 December 2010 15:06, OlliSee<o.roess(a)seeburger.de> wrote:
> >>> Thanks,
> >>> unfortunately not working, either.
> >>>
> >>> Maybe it will help, if I describe the scenario more detailed.
> >>>
> >>> I have three A facts inserted at the beginning.
> >>> Then the rule fires the first time after 5 seconds for every A fact and
> >>> inserts the B events.
> >>> Then I retract ONE of the B events, but the rule keeps firing for EVERY
> A
> >>> fact, despite the B events remaining in the WorkingMemory.
> >>> --
> >>> View this message in context:
> >>>
> http://drools-java-rules-engine.46999.n3.nabble.com/timer-and-duration-tp...
> >>> Sent from the Drools - User mailing list archive at Nabble.com.
> >>> _______________________________________________
> >>> rules-users mailing list
> >>> rules-users(a)lists.jboss.org
> >>> https://lists.jboss.org/mailman/listinfo/rules-users
> >>
> >> _______________________________________________
> >> rules-users mailing list
> >> rules-users(a)lists.jboss.org
> >> https://lists.jboss.org/mailman/listinfo/rules-users
> >>
> >>
> >> _______________________________________________
> >> rules-users mailing list
> >> rules-users(a)lists.jboss.org
> >> https://lists.jboss.org/mailman/listinfo/rules-users
> >>
> >>
> > _______________________________________________
> > rules-users mailing list
> > rules-users(a)lists.jboss.org
> > https://lists.jboss.org/mailman/listinfo/rules-users
> >
> >
>
>
> _______________________________________________
> rules-users mailing list
> rules-users(a)lists.jboss.org
> https://lists.jboss.org/mailman/listinfo/rules-users
>
15 years, 3 months
Flow: "Multiple Instances" vs rule task
by Gabor Szokoli
Hi,
I'm looking into Drools Flow, because some of our rules are sequential
and procedural, resulting in salience nightmare (like line numbers in
BASIC, only backwards :-) ) with lots of repetition in conditions.
Besides our domain people just love the idea of executable flow charts :-)
Having read through the documentation, it is not clear how I can
conveniently use rule tasks in a "foreach" node: I would like the
"foreach" node to virtually partition the Working Memory for the rules
inside: each execution of the inner rules should see their own small
subset of the Working Memory.
My initial guess is to do "foreach" over the list of values that
discriminate between the facts, then the inside rules could all start
like this:
when
$processInstance : WorkflowProcessInstance()
$whatever:Whatever( discriminatorField == (
$processInstance.getVariable("forEachVariable") ) )
...
then
Is that the way, or am I missing something here?
Thanks in advance:
Gabor Szokoli
15 years, 3 months
Using GlobalArea in Guvnor
by John Peterson
Hi,
I'm working with Guvnor 5.1.1 and I'm having an issue accessing
Declarative Models defined in the Global Area in the Packages. Is it
possible to create a shared model in the Global Area and then write
rules against them in other packages? It would seem to me that the
answer would be yes (why else have a "Global" area), but, for some
reason, it doesn't seem to recognize them.
Here's a scenario:
I declare a DeclarativeModel in GlobalArea:
GenericFact
id: Integer
valueOne: Integer
label: String
end
I have a package called com.experiment. I'd like to write Business Rule
in it using that GenericFact. However, when I click the "+" sign to add
a Fact, I see a yellow background over "Note: No model has been
defined." Is there something that needs to be done to make the
GlobalArea stuff viewable from the individual packages?
15 years, 3 months
Error at inserting a fact
by Anais Martinez
Hi. I want to test several rules and I'm using pseudo-clock and stream mode.
When I insert the first fact, Drools generates an error of "timestamp must
be greater 0". But if I use real clock, the message doesn't appears.
The fact is a java class, but I haven't defined the timestamp. What is the
problem?
For this test I am not using events.
Thanks
--
View this message in context: http://drools-java-rules-engine.46999.n3.nabble.com/Error-at-inserting-a-...
Sent from the Drools - User mailing list archive at Nabble.com.
15 years, 3 months
getting all binary packages from Guvnor
by Kumar, Ravendra
Hi Guys,
I am just playing with Guvnor and my Knowledge Builder,
I am able to pull a single binary package by hard-coding it into
changeset.xml using Configuration Agent like below
<change-set>
<add>
<resource basicAuthentication='enabled' username='admin'
password='admin'
source='http://localhost:8080/drools-guvnor/org.drools.guvnor.Guvnor/pac
kage/mortgages/TEST' type='PKG' />
</add>
</change-set>
But my requirement is not to hard code all other packages into
change-set.xml, but I want to pull packages from Guvenor becasus a lot
of packages are being create and deleted frequently.
So is there any way that I can get all packages/ or whole knowledgebase
from Guvnor. May be like this
<change-set>
<add>
<resource basicAuthentication='enabled' username='admin'
password='admin'
source='http://localhost:8080/drools-guvnor/org.drools.guvnor.Guvnor/pac
kags' type='PKG[]' />
</add>
</change-set>
And it should return all binary packages.
Any information will be highly appreciated.
Thanks,
Rav
Think green - keep it on the screen.
This e-mail and any attachment is for authorised use by the intended recipient(s) only. It may contain proprietary material, confidential information and/or be subject to legal privilege. It should not be copied, disclosed to, retained or used by, any other party. If you are not an intended recipient then please promptly delete this e-mail and any attachment and all copies and inform the sender. Thank you.
15 years, 3 months
Memory Consumption with 5000 Rules
by thomas.polzin@gmail.com
Dear all,
My setup includes about 5000 rules with the following pattern:
rule "1"
when
(
$c_0 : CFRO( fi.co == "1", su.co == "P", c.co == "C") or
$c_0 : CFRO( fi.co == "2", su.co == "P", c.co == "C") or
$c_0 : CFRO( fi.co == "3", su.co == "P", c.co == "C") or
$c_0 : CFRO( fi.co == "4, su.co == "P", c.co == "C") or
$c_0 : CFRO( fi.co == "5", su.co == "P", c.co == "C")
)
then
Bcf fact = new Bcf ();
fact.setC( "123");
insert( fact);
end
The number of disjunctions varies, it might go up to 80. Just loading these
5000 rules uses about 200mb. I use 5.1.1.
Is this to be expected or do I something fundamentally wrong. Any help
highly appreciated. For instance, would it
make sense to use a rule for each of the disjunction?
I add the rules the with the following code:
DroolsObjectInputStream stream = new DroolsObjectInputStream(inputStream);
Collection<KnowledgePackage> knowledgePackages =
(Collection<KnowledgePackage>)stream.readObject();
stream.close();
engine.addKnowledgePackages(knowledgePackages);
Many thanks in advance
Thomas
15 years, 3 months
Calling a function from another function in 5.0
by Chris Selwyn
I don't seem to be able to find how to call one function from another
function in Drools 5.0.
It works just fine in 5.1 but I am having to use 5.0 because my customer
requires me to use a supported version.
Is this a known problem or is there really no way to do it?
Chris Selwyn
15 years, 3 months
Understanding indexing
by Chris Selwyn
I would like to understand more about how my rules are being executed.
Is there a way that I can find out what indexes are being are being created.
I can see the drools.indexLeftBetaMemory (and friends) properties but I
would like to be able to observe the effects that they are having.
Chris Selwyn
15 years, 3 months