Re: [rules-users] No accumulator function found for identifier
Thanks for the tip! I'm on linux, but putting this file in my home dir made it work, too. Steven Williams wrote: Hi Jarek, I have had a similar problem. For the moment I have put the drools.packagebuilder.conf file in my home directory (e.g. c:\documents and settings\username on windows). Whilst not ideal it works. cheers Steve On Tue, May 20, 2008 at 10:36 PM, Jaroslaw Kijanowski [EMAIL PROTECTED] wrote: Hi, when I create my own accumulate function, I add it to src/main/java/META-INF/drools.packagebuilder.conf and it works fine. However, eclipse is showing one error: No accumulator function found for identifier: ... I've found this http://lists.jboss.org/pipermail/rules-users/2007-December/004349.html and tried to move META-INF to the root dir, but then my app doesn't work (and eclipse shows the same error). Any thoughts? Thanks, Jarek ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users
Re: [rules-users] No accumulator function found for identifier
There was an error in the IDE where different configuration files were not correctly loaded from the user classpath when creating a PackageBuilder. I have fixed this in trunk (JIRA JBRULES-1614). For now, I suggest you use the workaround as suggested by by Steve (thx Steve !). Putting the configuration file in your home dir should work. Kris - Original Message - From: Jaroslaw Kijanowski [EMAIL PROTECTED] To: rules-users@lists.jboss.org Sent: Tuesday, May 20, 2008 2:36 PM Subject: [rules-users] No accumulator function found for identifier Hi, when I create my own accumulate function, I add it to src/main/java/META-INF/drools.packagebuilder.conf and it works fine. However, eclipse is showing one error: No accumulator function found for identifier: ... I've found this http://lists.jboss.org/pipermail/rules-users/2007-December/004349.html and tried to move META-INF to the root dir, but then my app doesn't work (and eclipse shows the same error). Any thoughts? Thanks, Jarek ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users
Re: [rules-users] MissingPackageName Exception | Eclipse | brl to drl
Hi, as mentioned in the docs, you could use an ant task. So if you look at the sources drools-ant/src/main/java/org/drools/contrib/DroolsCompilerAntTask.java you will notice, that it adds the package file explicitly. In your case, try this: String rulePackageContent = FileUtils.readFileToString(rule.package); String brl = FileUtils.readFileToString(file); String outputDRL = rulePackageContent + write.marshal(read.unmarshal(brl)); HTH, Jarek - Original Message - Hi, We created a brl rule using guided editor in Eclipse 3.3 On trying to create a rule package we are getting a 'MissingPackageName' exception. As like a brl rule created in BRMS, on eclipse, the DRL source of the created brl shows only the rule body `with the exception of the package statement and imports. Our understanding is that packagebuilder in drools-compiler should pick the package name and the imports defined in the rules.package text file. Things work fine for business rules created in guided editor in BRMS. Are we missing something obvious here? or there isn't a way to compile and test the brl files created in Eclipse. Any inputs are highly appreciated. Thanks. Code snippet fyi File file = new File(test_brl); BRXMLPersistence read = (BRXMLPersistence) BRXMLPersistence.getInstance(); BRDRLPersistence write = (BRDRLPersistence)BRDRLPersistence.getInstance(); String brl = FileUtils.readFileToString(file); String outputDRL = write.marshal(read.unmarshal(brl)); System.out.println(outputDRl+outputDRL); //Output DRL here doesn't show the import statements and package name PackageBuilder builder = new PackageBuilder(); builder.addPackageFromDrl(new StringReader(outputDRL )); //Missing package name for rule package exception occurs here Package pkg = builder.getPackage(); RuleBase ruleBase = RuleBaseFactory.newRuleBase(); ruleBase.addPackage( pkg ); WorkingMemory workingMemory = ruleBase.newStatefulSession(); workingMemory.insert(obj); workingMemory.fireAllRules(); ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users
Re: [rules-users] question on JSR94 compliant jars
Drools is embeddable in any java application, if you add the proper dependencies. The dependencies vary according to what features your application uses. Take a look at this: http://anonsvn.labs.jboss.com/labs/jbossrules/tags/4.0.7.19894.GA/README_DEPENDENCIES.txt []s Edson 2008/5/21 Prem Kumar L [EMAIL PROTECTED]: Hi All, Will I be able to embed the drules rule engine into my application by adding drools-compiler.jar, drools-core.jar and drools-jsr94.jar into the applications classpath ? The reason for the question is this: my application runs on glassfish and since drools is not supported on glassfish I wanted to be sure before I go ahead and embed drools into my app. Any suggestions would be much appreciated. Thanks Prem ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users -- Edson Tirelli JBoss Drools Core Development Office: +55 11 3529-6000 Mobile: +55 11 9287-5646 JBoss, a division of Red Hat @ www.jboss.com ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users
[rules-users] https package url
Hi all, I use the Business Rules Server to deploy rules packages and I use the URL feature to consume them. It works fine but I am concern about security in rules requests. I've seen in the documentation that we can use SSL for BRMS login security but what about url requests to rules packages ?? Regards, Carl ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users
Re: [rules-users] Re: Ruleflow-group attribute causing rule to not fire
Thanks Kris, On 5/21/08, Kris Verlaenen [EMAIL PROTECTED] wrote: This is expected behaviour, let me try to explain. By adding the ruleflow-group attribute to your rules, you are stating that these rule should not be executed as normal, but that the order in which these rules should be executed is specified by a ruleflow. Activations will be created for rules that are part of a ruleflow-group, but they will only be executed if the ruleflow-group is activated. To make sure that rules with a ruleflow-group are executed, you must: 1. Create a ruleflow that specifies when the rules should be activated (using ruleset nodes) AND 2. Start the ruleflow whenever appropriate. My guess is that you are not starting the ruleflow, so the corresponding ruleflow-groups are never activated. You can either start a ruleflow manually in your code (workingMemory.startProcess(id_of_your_ruleflow), for example right before calling workingMemory.fireAllRules()), or using a rule (probably with a high salience) with as consequence drools.getWorkingMemory().startProcess(id_of_your_ruleflow). It is also normal that all other rules that are not tagged with a ruleflow-group attribute just execute as before, even in the presence of ruleflows, both can be used side by side. Kris - Original Message - *From:* Roger Tanuatmadja [EMAIL PROTECTED] *To:* rules-users@lists.jboss.org *Sent:* Monday, May 19, 2008 9:25 PM *Subject:* [rules-users] Re: Ruleflow-group attribute causing rule to not fire From: Roger Tanuatmadja [EMAIL PROTECTED] To: rules-users@lists.jboss.org Date: Mon, 19 May 2008 11:55:19 -0700 Subject: Ruleflow-group attribute causing rule to not fire Hi, I am new to both rules engine and Drools. I am currently evaluating Drools 4.0.7 for use in our new project. Basically I have been writing a bunch of individual rules and things have been fine, the rules that I expected to fire were fired, etc, etc. I then proceeded to investigate rule flows. I started innocently enough i.e. adding the ruleflow-group attribute to some of my rules. I also defined a ruleflow mapping (.rfm). I then reran my unit-tests (WITHOUT reading the rules in as rule flows) and some of my rules were no longer firing!!. I added an Agenda Listener to my code and 1. without the ruleflow-group attribute, activations were created, and fired. 2. with the ruleflow-group attribute, activations were created but not fired. Using the debugger yielded the same logical outcomes i.e. without the ruleflow-group attribute, my breakpoints were hit, but with the attribute specified, none of my breakpoints were hit. My question is: Is this behavior expected? And why? Especially since some other rules (with the attribute specified) continued to work. I've read the documentations as much as possible, but I am really new to this field so I might not even know what questions to ask either. Any help would be greatly appreciated. Thanks, Roger -- ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users
RE: [rules-users] DSL expanders for overriding rules question
I've done as suggested and created the feature request as JBRULES-1615. Thanks, -- Paul Ryan From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Edson Tirelli Sent: Wednesday, May 21, 2008 8:09 AM To: Rules Users List Subject: Re: [rules-users] DSL expanders for overriding rules question Paul, I believe eclipse plug-in supports only one expander per DSLR file. In fact, the expander declaration is only used by the eclipse plug-in. If you need to use more than one expander per rule file, you will have to use the API directly. This is probably something to improve in the future. May I ask you please to open a feature request? Kris, can you confirm that this is the case? []s Edson 2008/5/20 Paul Ryan [EMAIL PROTECTED]mailto:[EMAIL PROTECTED]: I have a question about expanders if anyone on might know the answer I'm trying to setup an import scheme for the rules in my system and thought that having expanders be the extension location might work, however when I try to use multiple expanders the eclipse plug-in throws and illegal argument exception. Is this the proper way to include rules and override or is there better way? Thanks in advance, -- Paul Ryan ___ rules-users mailing list rules-users@lists.jboss.orgmailto:rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users -- Edson Tirelli JBoss Drools Core Development Office: +55 11 3529-6000 Mobile: +55 11 9287-5646 JBoss, a division of Red Hat @ www.jboss.comhttp://www.jboss.com ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users
RE: [rules-users] https package url
Thank you Vikas, I use JBoss AS for testing rith now but we're planning to use weblogic later. We're just testing so by now I haven't try to use security login ... I'll also keep you updated (and everybody on the mailing list !!) Carl _ De : [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] De la part de Vikas Phonsa Envoyé : mercredi 21 mai 2008 12:08 À : Rules Users List Objet : RE: [rules-users] https package url Carl, I have the exact same concern. I posted a similar question several days ago but didn't get any replies. Have you deployed BRMS behind SSL? I haven't so far, so can't say if the RulesAgent can use https URLs. Also, have you been able to enable security? Which app server are you using? If security is enabled and BRMS login is password protected, how would the RulesAgent be able to consume packages from the URLs without using a username/password? I'll keep you posted if I discover anything in this regard. Thanks, Vikas _ From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Cabou, Carl Sent: Wednesday, May 21, 2008 8:49 AM To: Rules Users List Subject: [rules-users] https package url Hi all, I use the Business Rules Server to deploy rules packages and I use the URL feature to consume them. It works fine but I am concern about security in rules requests. I've seen in the documentation that we can use SSL for BRMS login security but what about url requests to rules packages ?? Regards, Carl This email and/or any files or attachments transmitted with it are confidential and intended solely for the use of the individual or entity to whom they are addressed, and may contain information that is privileged, confidential and exempt from disclosure under applicable law. If you are not the intended recipient, or the employee or agent responsible for delivering the message to the intended recipient, you are hereby notified that any dissemination, distribution or copying of this e-mail and/or any files or attachments transmitted with it is strictly forbidden. If you have received this email in error, please delete the e-mail and/or any files or attachments, and also notify the system manager ([EMAIL PROTECTED]) of the error. Please note that any views or opinions presented in this email are solely those of the author and do not necessarily represent those of the company. Finally, the recipient should check this email and any attachments for the presence of viruses. The company accepts no liability for any damage caused by any virus transmitted by this email and/or any files or attachments transmitted with it. ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users