Rules categorization/packages
by Amit Kumar
Hello All,
I am looking to organize the rules in different categories. But for
distribution purposes We are creating packages for different
roles/processing phases
So a rule will reside in one pckage but for navigation it can belong to
multiple categories
So packages are like Shirts, Pants, Shoes, Sweaters
Categories are Color, Material, Size, Gender and those have sub categories
witin them
We have rules which will device the category of the item
Like "red rule", "blue rule", "cloth rule", leather rule"
Now the problem we are facing is for category rules is if I define the rule
in Shirt package .. then I will not be able ot use it in Pant package.. Will
have to redefine it.
The other problem in this scenario is If I have a price rule in Shirt
package and the category is "Blue Color" and "XL Size" then I will have to
put it in both categories
When I put the "Blue Rule" on "Blue Category" and "XL Rule" on "XL
Category" and I put the rule in both categories.. will it be an "and"
relationship or will be an "OR"
Regards,
Amit
14 years, 9 months
Question About Programmatically Creating Drools Rules Remotely
by S. McKee
Hello,
I am running a Drools Guvnor server. While it is not an issue to create
rules through the UI, I do have a need to create rules and packages
through a Java program that I am coding that will connect remotely to
the Guvnor server from another box. Does anyone know if this is this
possible? If so, could I get pointed in the right direction for making
this happen?
Thank You,
Scott McKee
14 years, 9 months
April 19th Drools Meeting 2 day medical/healthcare exclusive, 3 day general topics
by Mark Proctor
http://blog.athico.com/2010/03/april-19th-drools-meeting-2-day.html
------
April 19th Drools Meeting 2 day medical/healthcare exclusive, 3
day general topics
<http://blog.athico.com/2010/03/april-19th-drools-meeting-2-day.html>
Posted by Mark Proctor
Logistics
What: Week long meeting, with 2 day medical/healthcare exclusive, 1 day
open to all with medical slant, 2 day open to all all general topics.
Where: 10210 Campus Point Drive, San Diego, CA 92121-1598 (SAIC
Corporation Headquarters)
When: Monday the 19th of April to Friday the 23rd of April
Previous Boot Camps: San Francisco June 2009
Registration:
http://community.jboss.org/wiki/DroolsBootCampSanDiegoApril2010
The boot camp is free, you only need to turn up, but please register
here, http://community.jboss.org/wiki/DroolsBootCampSanDiegoApril2010.
This page also is a live and more informed version of the information
contained here - please read it thoroughly.
Who Should Attend: See the registration page above for more detailed
information.
Overview
Mon-Tue (medical only)
The the first two days are exclusive to the medical and healthcare
communities and only people from medical and healthcare organisations or
with a medical background will be allowed to attend.
Wed (medical slant - open to all)
Keynote - James Taylor (Smart Enough Systems) "Smarter systems for
uncertain times".
The third day will still maintain a medical slant, wrapping up the last
two days, but we will open it up for those that want to observe or
participate. We will try and cover topics that will be interesting to
all there, even if not from medical background, just be aware that
medical discussions take priority. It is recommended that most people
start on the Wednesday, especially as we have an excellent keynote
speaker for everyone.
Thu-Fri (general topics - open to all)
The last two days is open to all and will hvae no specific topic. It is
likely we'll repeat a few talks from mon-tue that are relevant to new
comers.
Agenda
Other than the Wednesday keynote with James Taylor, we do not yet have
dates and times allocated for talks, as we are still waiting for all
talks to be proposed. So if you are thinking of talking, hurry up and
let us know :) (see registration page for more info). The registration
page will be kept up to date with talks, and contains information and
ideas on talks we'd like people to give; basically anything you think
people attending will be interested in - it does not have to be drools
specific. The current proposed talks are:
*Name* *Talk*
James Taylor (Smart Enough Systems
<http://www.smartenoughsystems.com/>) *Wed 9am Key Note :* Smarter
systems for uncertain times
Mark Proctor (JBoss) Intro to Drools 5
Mark Proctor (JBoss) Rule Authoring Techniques
Mark Proctor (JBoss) Spring, Camel and OSGi integration
Kris Verlaenen (JBoss)
Building Domain Specific Workflows for Clinical Decision Support
Kris Verlaenen (JBoss) Dynamic Fragments for Non-Linear Execution of
Adaptive Processes
Edson Tirelli (JBoss) Applying Complex Event Processing
Davide Sottara (University of Bologna) Hybrid Ontologies
Davide Sottara (University of Bologna) Enhancing Rules with Uncertainty
and Vagueness
Ken Kawamoto (Duke University) Clinical Decision Support with HL7 and
Drools
14 years, 9 months
Null Pointer Exception while adding rules
by rulesnubi
Hello,
I'm getting the following exception while add new rules -
java.lang.NullPointerException
at java.util.zip.Inflater.ensureOpen(Inflater.java:325)
at java.util.zip.Inflater.reset(Inflater.java:294)
at java.util.zip.ZipFile.getInflater(ZipFile.java:372)
at java.util.zip.ZipFile.getInputStream(ZipFile.java:320)
at java.util.zip.ZipFile.getInputStream(ZipFile.java:286)
at java.util.jar.JarFile.getInputStream(JarFile.java:387)
at
sun.net.www.protocol.jar.JarURLConnection.getInputStream(JarURLConnection.java:136)
at java.net.URL.openStream(URL.java:1007)
at java.lang.ClassLoader.getResourceAsStream(ClassLoader.java:1161)
at
com.sun.enterprise.loader.EJBClassLoader.getResourceAsStream(EJBClassLoader.java:834)
at
org.apache.catalina.loader.WebappClassLoader.getResourceAsStream(WebappClassLoader.java:1192)
at
org.drools.rule.CompositeClassLoader.getResourceAsStream(CompositeClassLoader.java:86)
at
org.drools.commons.jci.compilers.EclipseJavaCompiler$2.findType(EclipseJavaCompiler.java:240)
at
org.drools.commons.jci.compilers.EclipseJavaCompiler$2.findType(EclipseJavaCompiler.java:217)
at
org.eclipse.jdt.internal.compiler.lookup.LookupEnvironment.askForType(LookupEnvironment.java:122)
at
org.eclipse.jdt.internal.compiler.lookup.PackageBinding.getTypeOrPackage(PackageBinding.java:178)
at
org.eclipse.jdt.internal.compiler.lookup.Scope.getPackage(Scope.java:2060)
at
org.eclipse.jdt.internal.compiler.ast.QualifiedTypeReference.getTypeBinding(QualifiedTypeReference.java:65)
at
org.eclipse.jdt.internal.compiler.ast.TypeReference.resolveType(TypeReference.java:153)
at
org.eclipse.jdt.internal.compiler.ast.TypeReference.resolveSuperType(TypeReference.java:110)
at
org.eclipse.jdt.internal.compiler.lookup.ClassScope.findSupertype(ClassScope.java:1102)
at
org.eclipse.jdt.internal.compiler.lookup.ClassScope.connectSuperInterfaces(ClassScope.java:902)
at
org.eclipse.jdt.internal.compiler.lookup.ClassScope.connectTypeHierarchy(ClassScope.java:948)
at
org.eclipse.jdt.internal.compiler.lookup.CompilationUnitScope.connectTypeHierarchy(CompilationUnitScope.java:288)
at
org.eclipse.jdt.internal.compiler.lookup.LookupEnvironment.completeTypeBindings(LookupEnvironment.java:198)
at
org.eclipse.jdt.internal.compiler.Compiler.beginToCompile(Compiler.java:383)
at
org.eclipse.jdt.internal.compiler.Compiler.compile(Compiler.java:397)
at
org.drools.commons.jci.compilers.EclipseJavaCompiler.compile(EclipseJavaCompiler.java:351)
at
org.drools.commons.jci.compilers.AbstractJavaCompiler.compile(AbstractJavaCompiler.java:51)
at
org.drools.rule.builder.dialect.java.JavaDialect.compileAll(JavaDialect.java:389)
at
org.drools.compiler.DialectCompiletimeRegistry.compileAll(DialectCompiletimeRegistry.java:56)
at
org.drools.compiler.PackageRegistry.compileAll(PackageRegistry.java:74)
at
org.drools.compiler.PackageBuilder.compileAll(PackageBuilder.java:690)
at
org.drools.compiler.PackageBuilder.addPackage(PackageBuilder.java:653)
at
org.drools.compiler.PackageBuilder.addPackageFromDrl(PackageBuilder.java:290)
at
org.drools.compiler.PackageBuilder.addKnowledgeResource(PackageBuilder.java:488)
at
org.drools.builder.impl.KnowledgeBuilderImpl.add(KnowledgeBuilderImpl.java:25)
This is not even consistent. It works some time and throws up the above
exceptions at times.
I'm using drools v 5.0.1 on glassfish application server. The jdk is - Java
HotSpot(TM) Server VM (build 1.5.0_15-b04, mixed mode)
Anyone have similar experiences?
Thanks,
nubi
--
View this message in context: http://n3.nabble.com/Null-Pointer-Exception-while-adding-rules-tp454453p4...
Sent from the Drools - User mailing list archive at Nabble.com.
14 years, 9 months
April 19th Boot Camp to be open to all
by Mark Proctor
http://blog.athico.com/2010/03/april-19th-boot-camp-to-be-open-to-all.html
We will now be opening the boot camp up to all, for the last 3 days. The
boot camp was previously announced here
<http://blog.athico.com/2010/03/drools-open-source-healthcare.html>. The
over all schedule is below. I'll be putting up a registration wiki page
up on line in the next day or two, like last years which you can fine
here
<http://community.jboss.org/wiki/DroolsBootCampSanFranciscoJune2009>.
Keep an eye on the blog for more info soon.
We are looking for people that would like to present, take a focus group
or workshop. The topics can be on drools, or how drools is applied, or
on projects that use drools, or just general interesting topics for
rules, workflow, event processing and ontologies - anything you think
the people there would be interested in. Email me if you would like to
present
*Where *- San Diego, CA (meeting place tbc)*
Date *- Monday the 19th of April to Friday the 23rd of April
Schedule
* *Mon-Tue* (medical only) The the first two days are exclusive to
the medical community and only people from medical organisations
or with a medical background will be allowed to attend.
* *Wed* (medical focus - open to all) The third day will still
maintain a medical theme, wrapping up the last two days, but we
will open it up for those that want to observe or participate. We
will try and cover topics that will be interesting to all there,
even if not from medical background, just be aware that medical
discussions take priority.
* *Thu-Fri* (general topics - open to all) The last two days is open
to all and will have no specific topic
14 years, 9 months
Re: [rules-users] rules-users Digest, Vol 40, Issue 55
by Nilima R
Hi All,
Can someone tell me how to use create enums with Dynamic values in Guvnor.
For example I need enum which does not contain static value like A,B,C
rather these A,B,C values come from database.
Nilima
From:
rules-users-request(a)lists.jboss.org
To:
rules-users(a)lists.jboss.org
Date:
03/12/2010 10:36 PM
Subject:
rules-users Digest, Vol 40, Issue 55
Sent by:
rules-users-bounces(a)lists.jboss.org
Send rules-users mailing list submissions to
rules-users(a)lists.jboss.org
To subscribe or unsubscribe via the World Wide Web, visit
https://lists.jboss.org/mailman/listinfo/rules-users
or, via email, send a message with subject or body 'help' to
rules-users-request(a)lists.jboss.org
You can reach the person managing the list at
rules-users-owner(a)lists.jboss.org
When replying, please edit your Subject line so it is more specific
than "Re: Contents of rules-users digest..."
Today's Topics:
1. Re: OutOfMemoryError on Marshalling with non-existence check
in flow XOR split (heldeen)
2. Re: high sailence event/utility rules and ruleflows (H.C.)
----------------------------------------------------------------------
Message: 1
Date: Fri, 12 Mar 2010 07:49:03 -0800 (PST)
From: heldeen <heldeen(a)overstock.com>
Subject: Re: [rules-users] OutOfMemoryError on Marshalling with
non-existence check in flow XOR split
To: rules-users(a)lists.jboss.org
Message-ID: <1268408943169-444246.post(a)n3.nabble.com>
Content-Type: text/plain; charset=us-ascii
I think I need to clarify a few things. First the OOME is not in running
the
rules but on marshalling the state for the flow, which I do after each
command using a custom CommandService that marshals the session after each
command is executed. Second, the ValidationRuleFlowGroup is only going to
insert a ValidationResult() if there is something that is invalid. So a
valid set of facts would have no ValidationResult() in memory, hence
wanting
to split to a "valid" branch on "not ValidationResult()".
--
View this message in context:
http://n3.nabble.com/OutOfMemoryError-with-non-existence-check-in-flow-XO...
Sent from the Drools - User mailing list archive at Nabble.com.
------------------------------
Message: 2
Date: Fri, 12 Mar 2010 08:36:16 -0800 (PST)
From: "H.C." <canterburry(a)gmail.com>
Subject: Re: [rules-users] high sailence event/utility rules and
ruleflows
To: rules-users(a)lists.jboss.org
Message-ID: <1268411776720-444339.post(a)n3.nabble.com>
Content-Type: text/plain; charset=us-ascii
Thanks,
I tried this but I don't see my ruleflow group rules coming back and
re-processing once the high priority auto focus rules in my new
"maintenance" agenda group have executed. Do my rules in my ruleflow group
now also need an agenda group and auto-focus set to be re-evaluated?
--
View this message in context:
http://n3.nabble.com/high-sailence-event-utility-rules-and-ruleflows-tp44...
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
End of rules-users Digest, Vol 40, Issue 55
*******************************************
=====-----=====-----=====
Notice: The information contained in this e-mail
message and/or attachments to it may contain
confidential or privileged information. If you are
not the intended recipient, any dissemination, use,
review, distribution, printing or copying of the
information contained in this e-mail message
and/or attachments to it are strictly prohibited. If
you have received this communication in error,
please notify us by reply e-mail or telephone and
immediately and permanently delete the message
and any attachments. Thank you
14 years, 9 months
OutOfMemoryError with non-existence check in flow XOR split
by heldeen
I am using drools marshalling for persistence and am getting an OOME with my
simple rule flow. I have a custom CommandService that persists at the end of
each execution. (I am not using JPA :-( ).
In the rule flow I have a split that checks for the non-existence of a
simple pojo using "not ValidationResult()" as one of the constraints. The
other constraint is ValidationResult(valid == false). I get an
OutOfMemoryError using the "not" in one of the constraints. Changing "not
ValidationResult()" to "ValidationResult(valid == true)" results in normal
operation.
The flow is essentially Start->ValidationRuleFlowGroup->XOR Split->Valid
Action XOR Invalid Action -> End. The ValidationRuleFlowGroup has a simple
set of rules that will insert a ValidationResult() fact if something is not
valid.
Anyone have any idea why checking for the non-existence of a fact causes
this error. I'll post the pojo and the stack trace below.
public class ValidationResult {
private boolean isValid;
private String message;
public boolean isValid() {
return isValid;
}
public void setValid(boolean isValid) {
this.isValid = isValid;
}
public String getMessage() {
return message;
}
public void setMessage(String message) {
this.message = message;
}
}
java.lang.OutOfMemoryError: Java heap space
at java.util.Arrays.copyOf(Arrays.java:2786)
at java.io.ByteArrayOutputStream.write(ByteArrayOutputStream.java:94)
at
java.io.ObjectOutputStream$BlockDataOutputStream.drain(ObjectOutputStream.java:1838)
at
java.io.ObjectOutputStream$BlockDataOutputStream.write(ObjectOutputStream.java:1769)
at java.io.DataOutputStream.writeInt(DataOutputStream.java:182)
at
java.io.ObjectOutputStream$BlockDataOutputStream.writeInt(ObjectOutputStream.java:1904)
at java.io.ObjectOutputStream.writeInt(ObjectOutputStream.java:769)
at
org.drools.marshalling.impl.OutputMarshaller.writeLeftTuple(OutputMarshaller.java:459)
at
org.drools.marshalling.impl.OutputMarshaller.writeInitialFactHandleLeftTuples(OutputMarshaller.java:356)
at
org.drools.marshalling.impl.OutputMarshaller.writeFactHandles(OutputMarshaller.java:251)
at
org.drools.marshalling.impl.OutputMarshaller.writeSession(OutputMarshaller.java:85)
at
org.drools.marshalling.impl.DefaultMarshaller.marshall(DefaultMarshaller.java:117)
Thanks,
Heath
--
View this message in context: http://n3.nabble.com/OutOfMemoryError-with-non-existence-check-in-flow-XO...
Sent from the Drools - User mailing list archive at Nabble.com.
14 years, 9 months
About fusion and collections
by Amit Kumar
Hello All,
Was doing some rule writing and am seeing some issues which I want to
overcome.
In Fusion when we send the facts into working memory.. there seems to be no
way that rules are automatically getting triggered.
We have to call fireAllRules after each fact insertion. Is this the way it
was designed. Its like this in the stocktick example also
This one should be simple for somebody with little more experience than me
In the following rule
rule "raise alarm"
when
Event($type : eventType)
$events: ArrayList (size > 10)
from collect (Event(eventType == $type))
then
raise alarm
In the above rule the raise alarm is getting called 10 times. .. How can I
make it to be called only once.
Thanks
Amit
14 years, 9 months