From reddy.lakshmi at gmail.com Tue Jul 1 06:26:31 2014 From: reddy.lakshmi at gmail.com (LaKhI ReDdY!!!!!!!!!!!) Date: Tue, 1 Jul 2014 15:56:31 +0530 Subject: [rules-users] How to change the Header color and Logo in Guvnor 5.3.3.Final? Message-ID: Hi, I need to change the Header color(top header) and Logo in Guvnor 5.3.3.Final. Any points on where and all i need to do changes? Lakhi Reddy -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140701/100ab3c2/attachment.html From stephen.masters at me.com Tue Jul 1 07:03:30 2014 From: stephen.masters at me.com (Stephen Masters) Date: Tue, 01 Jul 2014 12:03:30 +0100 Subject: [rules-users] How to change the Header color and Logo in Guvnor 5.3.3.Final? In-Reply-To: References: Message-ID: <39811CD4-D120-42AE-BA83-B19341A8F6CD@me.com> If you explode the WAR, you should find an index.jsp and CSS. Modify them to your heart?s content. On 1 Jul 2014, at 11:26, LaKhI ReDdY!!!!!!!!!!! wrote: > Hi, > > I need to change the Header color(top header) and Logo in Guvnor 5.3.3.Final. > Any points on where and all i need to do changes? > > Lakhi Reddy > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users From ventilo35 at free.fr Tue Jul 1 09:57:51 2014 From: ventilo35 at free.fr (ventilo35 at free.fr) Date: Tue, 1 Jul 2014 15:57:51 +0200 (CEST) Subject: [rules-users] Dynamic rules and inheritance In-Reply-To: <1067003540.27308160.1404222703757.JavaMail.root@zimbra1-e1.priv.proxad.net> Message-ID: <1207454859.27321905.1404223071015.JavaMail.root@zimbra1-e1.priv.proxad.net> Hi I'm exploring using dynamic rules (using Drools 6.0.0 Final), and I see a curious behaviour when the knowledge is built using inheritance. What I notice is - new rules which have conditions based on subclasses are fired all right - but new rules which have conditions based on the base class are not always fired - they are fired only if some initial rules where fired, based on the base class (?!?) Here is an runnable example for clarity: // knowledge classes public static class Person { private String firstName; private String lastName; public void setFirstName(String fname) { this.firstName = fname; } public void setLastName(String lname) { this.lastName = lname; } public String getFirstName() { return this.firstName; } public String getLastName() { return this.lastName; } } public static class Contact extends Person { private String msisdn; public void setMsisdn(String m) { this.msisdn = m; } public String getMsisdn() { return this.msisdn; } } // Drools session KieServices ks = KieServices.Factory.get(); KieModuleModel kieModuleModel = ks.newKieModuleModel(); KieBaseModel kieBaseModel1 = kieModuleModel.newKieBaseModel( "rules") .setDefault( true ) .setEqualsBehavior( EqualityBehaviorOption.EQUALITY ) .setEventProcessingMode( EventProcessingOption.STREAM ); KieSessionModel ksessionModel1 = kieBaseModel1.newKieSessionModel( "KSession1" ) .setDefault( true ) .setType( KieSessionModel.KieSessionType.STATEFUL ) .setClockType( ClockTypeOption.get("realtime") ); KieFileSystem kfs = ks.newKieFileSystem(); ReleaseId ri = ks.newReleaseId( "org.default", "artifact", "1.0.0" ); kfs.generateAndWritePomXML(ri); // initial rules kfs.write("src/main/resources/rules/initial.drl", ks.getResources().newFileSystemResource("src/main/resources/rules/initial.drl").setResourceType(ResourceType.DRL)); KieBuilder kieBuilder = ks.newKieBuilder( kfs ).buildAll(); KieContainer kContainer = ks.newKieContainer(ri); KieSession kSession = kContainer.newKieSession(); Contact alice = new Contact(); alice.setFirstName("Alice"); alice.setLastName("Doe"); kSession.insert(alice); Contact bob = new Contact(); bob.setFirstName("Bob"); bob.setLastName("Tester"); kSession.insert(bob); kSession.fireAllRules(); // new rules kfs = ks.newKieFileSystem(); ReleaseId ri2 = ks.newReleaseId( "org.default", "artifact", "1.1.0" ); kfs.generateAndWritePomXML(ri2); kfs.write("src/main/resources/rules/initial.drl", ks.getResources().newFileSystemResource("src/main/resources/rules/initial.drl")); kfs.write("src/main/resources/rules/newrules.drl", ks.getResources().newFileSystemResource("src/main/resources/rules/newrules.drl")); kieBuilder = ks.newKieBuilder( kfs ).buildAll(); kContainer.updateToVersion(ri2); kSession.fireAllRules(); initial.drl : package com.sample import com.sample.DroolsTest.Person; import com.sample.DroolsTest.Contact; rule "Hello World 1" when c: Contact() then System.out.println("initial, working, found Contact "+c.getFirstName()); end rule "Hello World 2" when p: Person() then System.out.println("initial, working, found Person "+p.getFirstName()); end newrules.drl : package com.sample import com.sample.DroolsTest.Person; import com.sample.DroolsTest.Contact; rule "Hello World 3" when c: Contact() then System.out.println("new rule, working, found Contact "+c.getFirstName()); end rule "Hello World 4" when p: Person() then System.out.println("new rule, working, found Person "+p.getFirstName()); end This examples produces : initial, working, found Contact Bob initial, working, found Contact Alice initial, working, found Person Bob initial, working, found Person Alice new rule, working, found Contact Bob new rule, working, found Contact Alice new rule, working, found Person Bob new rule, working, found Person Alice But, if you comment out rule #2 in initial.drl, then the output becomes: initial, working, found Contact Bob initial, working, found Contact Alice new rule, working, found Contact Bob new rule, working, found Contact Alice i.e. rule #4 isn't fired anymore... Is this explainable? Thanks Francois From sunnycal99 at gmail.com Tue Jul 1 17:38:56 2014 From: sunnycal99 at gmail.com (Chris B) Date: Tue, 1 Jul 2014 14:38:56 -0700 (PDT) Subject: [rules-users] kbase using kie In-Reply-To: <1404108464603-4030193.post@n3.nabble.com> References: <1404098437580-4030187.post@n3.nabble.com> <1404100207116-4030189.post@n3.nabble.com> <1404101235183-4030191.post@n3.nabble.com> <1404108464603-4030193.post@n3.nabble.com> Message-ID: <1404250736723-4030210.post@n3.nabble.com> I am able to successfully integrate it now. But running in stream mode is giving some issues This is my code: ks = KieServices.Factory.get(); ReleaseId releaseId1 = ks.newReleaseId("com.sample", "ceaaRules", "" + currentRulesVersion); KieModuleModel kieModuleModel = ks.newKieModuleModel(); KieBaseModel kieBaseModel1 = kieModuleModel.newKieBaseModel("KBase1") .setDefault(true) .setEqualsBehavior(EqualityBehaviorOption.EQUALITY) .setEventProcessingMode(EventProcessingOption.STREAM); KieSessionModel kieSessionModel1 = kieBaseModel1 .newKieSessionModel("KSession1").setDefault(true) .setType(KieSessionModel.KieSessionType.STATEFUL); if (usePseudoClock) { kieSessionModel1.setClockType(ClockTypeOption.get("pseudo")); } else { kieSessionModel1.setClockType(ClockTypeOption.get("realtime")); } km = createAndDeployJar(ks, releaseId1, drlInSystem); kieContainer = ks.newKieContainer(km.getReleaseId()); KieSessionConfiguration ksc = ks.newKieSessionConfiguration(); ksc.setProperty("sessionName", "DroolsSession"); if (usePseudoClock) { ksc.setProperty("drools.clockType", "pseudo"); } else { ksc.setProperty("drools.clockType", "realtime"); } ksc.setProperty("drools.eventProcessingMode", "stream"); kSession = kieContainer.newKieSession(ksc); However when I run it. I get this error ============================ java.lang.RuntimeException: The requested KieBase "defaultKieBase" has been set to run in CLOUD mode but requires features only available in STREAM mode at org.drools.compiler.kie.builder.impl.KieContainerImpl.createKieBase(KieContainerImpl.java:400) at org.drools.compiler.kie.builder.impl.KieContainerImpl.getKieBase(KieContainerImpl.java:346) at org.drools.compiler.kie.builder.impl.KieContainerImpl.newKieSession(KieContainerImpl.java:498) at org.drools.compiler.kie.builder.impl.KieContainerImpl.newKieSession(KieContainerImpl.java:443) at org.drools.compiler.kie.builder.impl.KieContainerImpl.newKieSession(KieContainerImpl.java:434) There is a bug logged ================== https://issues.jboss.org/browse/RTGOV-393 Which says Stream mode is disabled for time being. Is my understanding correct. I am using 6.1.0.CR1 since 6.0.1.Final was having issues in writing the jar file to kfs if the event object is declared outside of drl http://drools.46999.n3.nabble.com/rules-users-Problem-with-declare-event-td4027688.html Thanks -- View this message in context: http://drools.46999.n3.nabble.com/kbase-using-kie-tp4030187p4030210.html Sent from the Drools: User forum mailing list archive at Nabble.com. From maruti.nitj at gmail.com Wed Jul 2 00:56:14 2014 From: maruti.nitj at gmail.com (maruthi_s) Date: Tue, 1 Jul 2014 21:56:14 -0700 (PDT) Subject: [rules-users] Unable to Resolve class Error - Drools 5.5 in concurrent processing In-Reply-To: <1404275839887-4030211.post@n3.nabble.com> References: <1404275839887-4030211.post@n3.nabble.com> Message-ID: <1404276974770-4030212.post@n3.nabble.com> Sending to drools user list -- View this message in context: http://drools.46999.n3.nabble.com/Unable-to-Resolve-class-Error-Drools-5-5-in-concurrent-processing-tp4030211p4030212.html Sent from the Drools: User forum mailing list archive at Nabble.com. From reddy.lakshmi at gmail.com Wed Jul 2 02:35:10 2014 From: reddy.lakshmi at gmail.com (LaKhI ReDdY!!!!!!!!!!!) Date: Wed, 2 Jul 2014 12:05:10 +0530 Subject: [rules-users] How to change the Header color and Logo in Guvnor 5.3.3.Final? In-Reply-To: <39811CD4-D120-42AE-BA83-B19341A8F6CD@me.com> References: <39811CD4-D120-42AE-BA83-B19341A8F6CD@me.com> Message-ID: Hi Stephen, Thanks for your reply. I have downloaded the guvnor-5.3.3.Final.zip file for source code ,using maven i have compiled ,build and deployed. In this zip file i got the following projects. guvnor-bulk-importer guvnor-repository guvnor-webapp guvnor-distributions etc... In this source code , where and all i need to make the changes for logo and header colors? Regards, Lakhi Reddy On Tue, Jul 1, 2014 at 4:33 PM, Stephen Masters wrote: > If you explode the WAR, you should find an index.jsp and CSS. Modify them > to your heart?s content. > > > On 1 Jul 2014, at 11:26, LaKhI ReDdY!!!!!!!!!!! > wrote: > > > Hi, > > > > I need to change the Header color(top header) and Logo in Guvnor > 5.3.3.Final. > > Any points on where and all i need to do changes? > > > > Lakhi Reddy > > _______________________________________________ > > rules-users mailing list > > rules-users at lists.jboss.org > > https://lists.jboss.org/mailman/listinfo/rules-users > > > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140702/46326d8a/attachment-0001.html From zahid.ahmed at emirates.com Wed Jul 2 02:52:14 2014 From: zahid.ahmed at emirates.com (Zahid Ahmed) Date: Wed, 2 Jul 2014 06:52:14 +0000 Subject: [rules-users] How to change the Header color and Logo in Guvnor 5.3.3.Final? In-Reply-To: References: <39811CD4-D120-42AE-BA83-B19341A8F6CD@me.com> Message-ID: In guvnor-webapp project Regards, Zahid Ahmed Senior Software Engineer | Emirates Group IT P.O. Box 686 | Dubai, United Arab Emirates T +971 4 245 3153 | M +971 55 1183602 [http://cdn.ek.aero/email/e_signatures/ekg2013.jpg] From: rules-users-bounces at lists.jboss.org [mailto:rules-users-bounces at lists.jboss.org] On Behalf Of LaKhI ReDdY!!!!!!!!!!! Sent: 02 July 2014 10:35 To: Rules Users List; stephen.masters at me.com Subject: Re: [rules-users] How to change the Header color and Logo in Guvnor 5.3.3.Final? Hi Stephen, Thanks for your reply. I have downloaded the guvnor-5.3.3.Final.zip file for source code ,using maven i have compiled ,build and deployed. In this zip file i got the following projects. guvnor-bulk-importer guvnor-repository guvnor-webapp guvnor-distributions etc... In this source code , where and all i need to make the changes for logo and header colors? Regards, Lakhi Reddy On Tue, Jul 1, 2014 at 4:33 PM, Stephen Masters > wrote: If you explode the WAR, you should find an index.jsp and CSS. Modify them to your heart?s content. On 1 Jul 2014, at 11:26, LaKhI ReDdY!!!!!!!!!!! > wrote: > Hi, > > I need to change the Header color(top header) and Logo in Guvnor 5.3.3.Final. > Any points on where and all i need to do changes? > > Lakhi Reddy > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users _______________________________________________ rules-users mailing list rules-users at lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140702/32a9e040/attachment.html -------------- next part -------------- A non-text attachment was scrubbed... Name: image001.jpg Type: image/jpeg Size: 8518 bytes Desc: image001.jpg Url : http://lists.jboss.org/pipermail/rules-users/attachments/20140702/32a9e040/attachment.jpg From reddy.lakshmi at gmail.com Wed Jul 2 05:45:59 2014 From: reddy.lakshmi at gmail.com (LaKhI ReDdY!!!!!!!!!!!) Date: Wed, 2 Jul 2014 15:15:59 +0530 Subject: [rules-users] How to migrate data from Guvnor 5.1.1 to 5.3.3.Final version. Message-ID: Hi , I need information on how to migrate existing repository from Guvnor 5.1.1 to 5.3.3.Final version. Currently i am using Guvnor 5.1.1 version and data is stored in Oracle database. I am moving to Guvnor 5.3.3.Final version. I would like to migrate the existing data from Guvnor 5.1.1 to 5.3.3.Final instance. One way i see is export from Guvnor 5.1.1 and import the exported xml in Guvnor 5.3.3.Final instance. Is there any other way to migrate the data? Regards, Lakshmi Reddy -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140702/76f53237/attachment-0001.html From rajeswari at raremile.com Wed Jul 2 06:22:17 2014 From: rajeswari at raremile.com (Rajeswari) Date: Wed, 2 Jul 2014 03:22:17 -0700 (PDT) Subject: [rules-users] Usage of java.util.List in Drools Guvnor 5.5.0 Message-ID: <1404296537366-4030217.post@n3.nabble.com> Created a Model in Guvnor 5.5.0 with 3 fields - 2 Text, 1 java.util.List The model is verified and validated - correctly. Source looks like below declare FormatConfig fieldName: String regEx: String regExPatterns: java.util.List end While trying to create a Business Rule using the above created Model. The rule gets fired and works fine. rule "MyFormat" dialect "mvel" when config : FormatConfig( fieldName == "AMOUNT" ) then config.setRegEx( "123" ); retract( config ); end But, the moment I try to use the List, by only declaring a List in the "When" section, the rule stops working. rule "MyFormat" dialect "mvel" when config : FormatConfig( fieldName == "AMOUNT" ) regExPatterns1: java.util.List ( ) then config.setRegEx( "123" ); retract( config ); end My final intention is to modify the regExPatterns list in the "THEN" block -- View this message in context: http://drools.46999.n3.nabble.com/Usage-of-java-util-List-in-Drools-Guvnor-5-5-0-tp4030217.html Sent from the Drools: User forum mailing list archive at Nabble.com. From rajeswari at raremile.com Wed Jul 2 06:23:02 2014 From: rajeswari at raremile.com (Rajeswari Devadass) Date: Wed, 2 Jul 2014 15:53:02 +0530 Subject: [rules-users] Usage of List in Drools 5.5.0 Message-ID: Created a Model in Guvnor 5.5.0 with 3 fields - 2 Text, 1 java.util.List The model is verified and validated - correctly. Source looks like below declare FormatConfig fieldName: String regEx: String regExPatterns: java.util.List end While trying to create a Business Rule using the above created Model. The rule gets fired and works fine. rule "MyFormat" dialect "mvel" when config : FormatConfig( fieldName == "AMOUNT" ) then config.setRegEx( "123" ); retract( config ); end But, the moment I try to use the List, by only declaring a List in the "When" section, the rule stops working. rule "MyFormat" dialect "mvel" when config : FormatConfig( fieldName == "AMOUNT" ) regExPatterns1: java.util.List ( ) then config.setRegEx( "123" ); retract( config ); end My final intention is to modify the regExPatterns list in the "THEN" block -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140702/dce87ea1/attachment.html From michael.anstis at gmail.com Wed Jul 2 06:34:24 2014 From: michael.anstis at gmail.com (Michael Anstis) Date: Wed, 2 Jul 2014 11:34:24 +0100 Subject: [rules-users] How to migrate data from Guvnor 5.1.1 to 5.3.3.Final version. In-Reply-To: References: Message-ID: The only solution that could work is to export your repository from 5.1.1 and import into 5.3.3. You'll loose all history though. On 2 July 2014 10:45, LaKhI ReDdY!!!!!!!!!!! wrote: > Hi , > > I need information on how to migrate existing repository from Guvnor 5.1.1 > to 5.3.3.Final version. > > Currently i am using Guvnor 5.1.1 version and data is stored in Oracle > database. I am moving to Guvnor 5.3.3.Final version. > I would like to migrate the existing data from Guvnor 5.1.1 to 5.3.3.Final > instance. > > One way i see is export from Guvnor 5.1.1 and import the exported xml in > Guvnor 5.3.3.Final instance. > > Is there any other way to migrate the data? > > Regards, > Lakshmi Reddy > > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140702/fae203b0/attachment.html From michael.anstis at gmail.com Wed Jul 2 06:35:10 2014 From: michael.anstis at gmail.com (Michael Anstis) Date: Wed, 2 Jul 2014 11:35:10 +0100 Subject: [rules-users] Usage of java.util.List in Drools Guvnor 5.5.0 In-Reply-To: <1404296537366-4030217.post@n3.nabble.com> References: <1404296537366-4030217.post@n3.nabble.com> Message-ID: Do you insert a List into working memory? On 2 July 2014 11:22, Rajeswari wrote: > Created a Model in Guvnor 5.5.0 with 3 fields - 2 Text, 1 java.util.List > The model is verified and validated - correctly. > Source looks like below > declare FormatConfig > fieldName: String > regEx: String > regExPatterns: java.util.List > end > > While trying to create a Business Rule using the above created Model. The > rule gets fired and works fine. > rule "MyFormat" > dialect "mvel" > when > config : FormatConfig( fieldName == "AMOUNT" ) > then > config.setRegEx( "123" ); > retract( config ); > end > > But, the moment I try to use the List, by only declaring a List in the > "When" section, the rule stops working. > rule "MyFormat" > dialect "mvel" > when > config : FormatConfig( fieldName == "AMOUNT" ) > regExPatterns1: java.util.List ( ) > then > config.setRegEx( "123" ); > retract( config ); > end > > My final intention is to modify the regExPatterns list in the "THEN" block > > > > > -- > View this message in context: > http://drools.46999.n3.nabble.com/Usage-of-java-util-List-in-Drools-Guvnor-5-5-0-tp4030217.html > Sent from the Drools: User forum mailing list archive at Nabble.com. > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140702/738e4840/attachment.html From reddy.lakshmi at gmail.com Wed Jul 2 06:49:22 2014 From: reddy.lakshmi at gmail.com (LaKhI ReDdY!!!!!!!!!!!) Date: Wed, 2 Jul 2014 16:19:22 +0530 Subject: [rules-users] How to migrate data from Guvnor 5.1.1 to 5.3.3.Final version. In-Reply-To: References: Message-ID: Thanks Michael. What about Drools-ant task for Jackrabbit JCR repository migration?, can we use this for 5.1.1 and import into 5.3.3? Regards, Lakshmi Reddy On Wed, Jul 2, 2014 at 4:04 PM, Michael Anstis wrote: > The only solution that could work is to export your repository from 5.1.1 > and import into 5.3.3. > > You'll loose all history though. > > > On 2 July 2014 10:45, LaKhI ReDdY!!!!!!!!!!! > wrote: > >> Hi , >> >> I need information on how to migrate existing repository from Guvnor >> 5.1.1 to 5.3.3.Final version. >> >> Currently i am using Guvnor 5.1.1 version and data is stored in Oracle >> database. I am moving to Guvnor 5.3.3.Final version. >> I would like to migrate the existing data from Guvnor 5.1.1 to >> 5.3.3.Final instance. >> >> One way i see is export from Guvnor 5.1.1 and import the exported xml in >> Guvnor 5.3.3.Final instance. >> >> Is there any other way to migrate the data? >> >> Regards, >> Lakshmi Reddy >> >> _______________________________________________ >> rules-users mailing list >> rules-users at lists.jboss.org >> https://lists.jboss.org/mailman/listinfo/rules-users >> > > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140702/144a0539/attachment.html From rajeswari at raremile.com Wed Jul 2 07:05:49 2014 From: rajeswari at raremile.com (Rajeswari) Date: Wed, 2 Jul 2014 04:05:49 -0700 (PDT) Subject: [rules-users] Usage of java.util.List in Drools Guvnor 5.5.0 In-Reply-To: References: <1404296537366-4030217.post@n3.nabble.com> Message-ID: <1404299149792-4030222.post@n3.nabble.com> Hi, I need to modify the List field in my Config object. -- View this message in context: http://drools.46999.n3.nabble.com/Usage-of-java-util-List-in-Drools-Guvnor-5-5-0-tp4030217p4030222.html Sent from the Drools: User forum mailing list archive at Nabble.com. From michael.anstis at gmail.com Wed Jul 2 07:12:45 2014 From: michael.anstis at gmail.com (Michael Anstis) Date: Wed, 2 Jul 2014 12:12:45 +0100 Subject: [rules-users] Usage of java.util.List in Drools Guvnor 5.5.0 In-Reply-To: <1404299149792-4030222.post@n3.nabble.com> References: <1404296537366-4030217.post@n3.nabble.com> <1404299149792-4030222.post@n3.nabble.com> Message-ID: So your FormatConfig object contains a list that you need access to? rule "MyFormat" dialect "mvel" when config : FormatConfig( fieldName == "AMOUNT", $l : listField ) then $l.doWhatEverYouWant(); config.setRegEx( "123" ); retract( config ); end On 2 July 2014 12:05, Rajeswari wrote: > Hi, > I need to modify the List field in my Config object. > > > > -- > View this message in context: > http://drools.46999.n3.nabble.com/Usage-of-java-util-List-in-Drools-Guvnor-5-5-0-tp4030217p4030222.html > Sent from the Drools: User forum mailing list archive at Nabble.com. > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140702/63470acb/attachment-0001.html From rajeswari at raremile.com Wed Jul 2 07:18:33 2014 From: rajeswari at raremile.com (Rajeswari) Date: Wed, 2 Jul 2014 04:18:33 -0700 (PDT) Subject: [rules-users] Usage of java.util.List in Drools Guvnor 5.5.0 In-Reply-To: References: <1404296537366-4030217.post@n3.nabble.com> <1404299149792-4030222.post@n3.nabble.com> Message-ID: <1404299913857-4030224.post@n3.nabble.com> Thanks How can I do this in Business Rule Editor. I should be able to use the editor instead of free form DRL -- View this message in context: http://drools.46999.n3.nabble.com/Usage-of-java-util-List-in-Drools-Guvnor-5-5-0-tp4030217p4030224.html Sent from the Drools: User forum mailing list archive at Nabble.com. From michael.anstis at gmail.com Wed Jul 2 07:32:44 2014 From: michael.anstis at gmail.com (Michael Anstis) Date: Wed, 2 Jul 2014 12:32:44 +0100 Subject: [rules-users] Usage of java.util.List in Drools Guvnor 5.5.0 In-Reply-To: <1404299913857-4030224.post@n3.nabble.com> References: <1404296537366-4030217.post@n3.nabble.com> <1404299149792-4030222.post@n3.nabble.com> <1404299913857-4030224.post@n3.nabble.com> Message-ID: Add the field to the pattern (as you have done for "fieldName") and then enter a variable name for the field (you might need to add a "list != null" constraint, I can't remember) On 2 July 2014 12:18, Rajeswari wrote: > Thanks > How can I do this in Business Rule Editor. > I should be able to use the editor instead of free form DRL > > > > -- > View this message in context: > http://drools.46999.n3.nabble.com/Usage-of-java-util-List-in-Drools-Guvnor-5-5-0-tp4030217p4030224.html > Sent from the Drools: User forum mailing list archive at Nabble.com. > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140702/f901dbdb/attachment.html From maruti.nitj at gmail.com Wed Jul 2 09:19:50 2014 From: maruti.nitj at gmail.com (maruthi_s) Date: Wed, 2 Jul 2014 06:19:50 -0700 (PDT) Subject: [rules-users] Unable to resolve class error , drools 5.5 in concurrent execution. JSR94Support and Spring Message-ID: <1404307190338-4030226.post@n3.nabble.com> Hi , We use Drools 5.5 and drool implementation is done through Spring JSR94Support API> The Rule engine is called in concurrent mode, i.e , JSR94Support.executeStateless(name,list) is executed through multiple threads. And when the rules are executed we randomly get the following exception org.drools.RuntimeDroolsException: Unable to resolve class 'someclass(this is sample)here actual class is printed>' at org.drools.base.ClassFieldAccessorCache.getClass(ClassFieldAccessorCache.java:126) at org.drools.base.ClassFieldAccessorCache.getClassObjectType(ClassFieldAccessorCache.java:48) at org.drools.reteoo.ClassObjectTypeConf.(ClassObjectTypeConf.java:83) at org.drools.common.ObjectTypeConfigurationRegistry.getObjectTypeConf(ObjectTypeConfigurationRegistry.java:71) at org.drools.common.NamedEntryPoint.insert(NamedEntryPoint.java:159) at org.drools.common.AbstractWorkingMemory.insert(AbstractWorkingMemory.java:903) at org.drools.common.AbstractWorkingMemory.insert(AbstractWorkingMemory.java:847) at org.drools.reteoo.ReteooStatelessSession.executeWithResults(ReteooStatelessSession.java:273) The rules are registered every 15 minutes through RuleAdministrator.registerRuleExecutionset , so whenever we refresh the rules and the subsequent thread even after the registration is completed, fails with the above message. This happens only when the rules are invoked concurrently. Please advise. -- View this message in context: http://drools.46999.n3.nabble.com/Unable-to-resolve-class-error-drools-5-5-in-concurrent-execution-JSR94Support-and-Spring-tp4030226.html Sent from the Drools: User forum mailing list archive at Nabble.com. From dsotty at gmail.com Tue Jul 1 21:51:59 2014 From: dsotty at gmail.com (Davide Sottara) Date: Tue, 01 Jul 2014 20:51:59 -0500 Subject: [rules-users] Unable to resolve class error , drools 5.5 in concurrent execution. JSR94Support and Spring In-Reply-To: <1404307190338-4030226.post@n3.nabble.com> References: <1404307190338-4030226.post@n3.nabble.com> Message-ID: <53B365BF.5020206@gmail.com> 5.5 was not thread-safe and some of these concurrency issues have been fixed in later versions. Could you try 5.6 or 6.x? On 07/02/2014 08:19 AM, maruthi_s wrote: > Hi , > > We use Drools 5.5 and drool implementation is done through Spring > JSR94Support API> > The Rule engine is called in concurrent mode, > i.e , JSR94Support.executeStateless(name,list) is executed through multiple > threads. > > And when the rules are executed we randomly get the following exception > > org.drools.RuntimeDroolsException: Unable to resolve class 'someclass(this > is sample)here actual class is printed>' > at > org.drools.base.ClassFieldAccessorCache.getClass(ClassFieldAccessorCache.java:126) > at > org.drools.base.ClassFieldAccessorCache.getClassObjectType(ClassFieldAccessorCache.java:48) > at > org.drools.reteoo.ClassObjectTypeConf.(ClassObjectTypeConf.java:83) > at > org.drools.common.ObjectTypeConfigurationRegistry.getObjectTypeConf(ObjectTypeConfigurationRegistry.java:71) > at > org.drools.common.NamedEntryPoint.insert(NamedEntryPoint.java:159) > at > org.drools.common.AbstractWorkingMemory.insert(AbstractWorkingMemory.java:903) > at > org.drools.common.AbstractWorkingMemory.insert(AbstractWorkingMemory.java:847) > at > org.drools.reteoo.ReteooStatelessSession.executeWithResults(ReteooStatelessSession.java:273) > > The rules are registered every 15 minutes through > RuleAdministrator.registerRuleExecutionset , > so whenever we refresh the rules and the subsequent thread even after the > registration is completed, fails with the above message. This happens only > when the rules are invoked concurrently. > > Please advise. > > > > -- > View this message in context: http://drools.46999.n3.nabble.com/Unable-to-resolve-class-error-drools-5-5-in-concurrent-execution-JSR94Support-and-Spring-tp4030226.html > Sent from the Drools: User forum mailing list archive at Nabble.com. > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users > From mjr4184 at gmail.com Wed Jul 2 11:18:00 2014 From: mjr4184 at gmail.com (mikerod) Date: Wed, 2 Jul 2014 08:18:00 -0700 (PDT) Subject: [rules-users] Equality semantics of logical assertions and stated assertions In-Reply-To: References: <1403885772808-4030179.post@n3.nabble.com> Message-ID: <1404314280984-4030228.post@n3.nabble.com> Thanks a lot for the detailed response. This line of reasoning makes sense to me. I can see now why the behavior is the way that it is. I appreciate the quick feedback too! -- View this message in context: http://drools.46999.n3.nabble.com/Equality-semantics-of-logical-assertions-and-stated-assertions-tp4030179p4030228.html Sent from the Drools: User forum mailing list archive at Nabble.com. From mjr4184 at gmail.com Wed Jul 2 12:29:32 2014 From: mjr4184 at gmail.com (mikerod) Date: Wed, 2 Jul 2014 09:29:32 -0700 (PDT) Subject: [rules-users] Equality semantics of logical assertions and stated assertions In-Reply-To: <1404314280984-4030228.post@n3.nabble.com> References: <1403885772808-4030179.post@n3.nabble.com> <1404314280984-4030228.post@n3.nabble.com> Message-ID: Add - Mike Rodriguez > On Jul 2, 2014, at 10:18 AM, "mikerod [via Drools]" wrote: > > Thanks a lot for the detailed response. This line of reasoning makes sense to me. I can see now why the behavior is the way that it is. > > I appreciate the quick feedback too! > > > If you reply to this email, your message will be added to the discussion below: > http://drools.46999.n3.nabble.com/Equality-semantics-of-logical-assertions-and-stated-assertions-tp4030179p4030228.html > To unsubscribe from Equality semantics of logical assertions and stated assertions, click here. > NAML -- View this message in context: http://drools.46999.n3.nabble.com/Equality-semantics-of-logical-assertions-and-stated-assertions-tp4030179p4030229.html Sent from the Drools: User forum mailing list archive at Nabble.com. -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140702/93a66e55/attachment.html From maruti.nitj at gmail.com Wed Jul 2 16:38:06 2014 From: maruti.nitj at gmail.com (maruthi_s) Date: Wed, 2 Jul 2014 13:38:06 -0700 (PDT) Subject: [rules-users] Unable to resolve class error , drools 5.5 in concurrent execution. JSR94Support and Spring In-Reply-To: <53B365BF.5020206@gmail.com> References: <1404307190338-4030226.post@n3.nabble.com> <53B365BF.5020206@gmail.com> Message-ID: <1404333482121-4030230.post@n3.nabble.com> This is the method which throws Exception during concurrency. Highlighted Line number throws the exception ClassName : ClassFieldAccessorCache public Class getClass(String className) { try { return this.classLoader.loadClass( className ); // Exception happens here. And This happens only during multithreading or concurrent calls. } catch ( ClassNotFoundException e ) { throw new RuntimeDroolsException( "Unable to resolve class '" + className + "'" ); } } -- View this message in context: http://drools.46999.n3.nabble.com/Unable-to-resolve-class-error-drools-5-5-in-concurrent-execution-JSR94Support-and-Spring-tp4030226p4030230.html Sent from the Drools: User forum mailing list archive at Nabble.com. From zahid.ahmed at emirates.com Thu Jul 3 06:03:20 2014 From: zahid.ahmed at emirates.com (Zahid Ahmed) Date: Thu, 3 Jul 2014 10:03:20 +0000 Subject: [rules-users] Drools 6.0 | Workbench Authentication | JAAS with DB Message-ID: Hi, I am configuring DB based JAAS Authentication for Kie-Drools-Workbench 6.1.0. Server log shows user is authenticated and roles are assigned to the user. But KIE login form says "Login failed: Not Authorized ". I have also added roles in Organizational Unit, Repository and Projects using kie-config-cli. But still getting the same error. Kindly let me know what wrong am I doing. Standalone.xml Kie-drools-wb.War / WEB_INF/jboss-web.xml| drools-guvnor Server Logs 13:55:22,408 TRACE [org.jboss.security.auth.spi.DatabaseServerLoginModule] (http--127.0.0.1-8080-2) initialize 13:55:22,410 TRACE [org.jboss.security.auth.spi.DatabaseServerLoginModule] (http--127.0.0.1-8080-2) Security domain: other 13:55:22,412 TRACE [org.jboss.security.auth.spi.DatabaseServerLoginModule] (http--127.0.0.1-8080-2) Password hashing activated: algorithm = MD5, encoding = base64, charset = UTF-8, callback = null, storeCallback = null 13:55:22,415 TRACE [org.jboss.security.auth.spi.DatabaseServerLoginModule] (http--127.0.0.1-8080-2) DatabaseServerLoginModule, dsJndiName=java:jboss/datasources/jdbc/jbpmStagingRWDS 13:55:22,419 TRACE [org.jboss.security.auth.spi.DatabaseServerLoginModule] (http--127.0.0.1-8080-2) principalsQuery=select PASSWORD from principals where PRINCIPALID=? 13:55:22,422 TRACE [org.jboss.security.auth.spi.DatabaseServerLoginModule] (http--127.0.0.1-8080-2) rolesQuery=select ROLE,ROLEGROUP from roles WHERE principalid=? 13:55:22,424 TRACE [org.jboss.security.auth.spi.DatabaseServerLoginModule] (http--127.0.0.1-8080-2) suspendResume=true 13:55:22,426 TRACE [org.jboss.security.auth.spi.DatabaseServerLoginModule] (http--127.0.0.1-8080-2) login 13:55:22,428 TRACE [org.jboss.security.auth.spi.DatabaseServerLoginModule] (http--127.0.0.1-8080-2) suspendAnyTransaction 13:55:22,489 TRACE [org.jboss.security.auth.spi.DatabaseServerLoginModule] (http--127.0.0.1-8080-2) Excuting query: select PASSWORD from principals where PRINCIPALID=?, with username: iit 13:55:22,495 TRACE [org.jboss.security.auth.spi.DatabaseServerLoginModule] (http--127.0.0.1-8080-2) Obtained user password 13:55:22,497 TRACE [org.jboss.security.auth.spi.DatabaseServerLoginModule] (http--127.0.0.1-8080-2) resumeAnyTransaction 13:55:22,499 TRACE [org.jboss.security.auth.spi.DatabaseServerLoginModule] (http--127.0.0.1-8080-2) User 'iit' authenticated, loginOk=true 13:55:22,501 TRACE [org.jboss.security.auth.spi.DatabaseServerLoginModule] (http--127.0.0.1-8080-2) commit, loginOk=true 13:55:22,503 TRACE [org.jboss.security.auth.spi.DatabaseServerLoginModule] (http--127.0.0.1-8080-2) getRoleSets using rolesQuery: select ROLE,ROLEGROUP from roles WHERE principalid=?, username: iit 13:55:22,507 TRACE [org.jboss.security.auth.spi.DatabaseServerLoginModule] (http--127.0.0.1-8080-2) suspendAnyTransaction 13:55:22,509 TRACE [org.jboss.security.auth.spi.DatabaseServerLoginModule] (http--127.0.0.1-8080-2) Excuting query: select ROLE,ROLEGROUP from roles WHERE principalid=?, with username: iit 13:55:22,514 TRACE [org.jboss.security.auth.spi.DatabaseServerLoginModule] (http--127.0.0.1-8080-2) Assign user to role admin 13:55:22,516 TRACE [org.jboss.security.auth.spi.DatabaseServerLoginModule] (http--127.0.0.1-8080-2) Assign user to role analyst 13:55:22,518 TRACE [org.jboss.security.auth.spi.DatabaseServerLoginModule] (http--127.0.0.1-8080-2) Assign user to role developer 13:55:22,521 TRACE [org.jboss.security.auth.spi.DatabaseServerLoginModule] (http--127.0.0.1-8080-2) Assign user to role manager 13:55:22,523 TRACE [org.jboss.security.auth.spi.DatabaseServerLoginModule] (http--127.0.0.1-8080-2) Assign user to role user 13:55:22,525 TRACE [org.jboss.security.auth.spi.DatabaseServerLoginModule] (http--127.0.0.1-8080-2) resumeAnyTransaction 13:55:22,527 TRACE [org.jboss.security.authentication.JBossCachedAuthenticationManager] (http--127.0.0.1-8080-2) defaultLogin, lc=javax.security.auth.login.LoginContext at 3460a6, subject=Subject(11883582).principals=org.jboss.security.SimplePrincipal at 25145532(iit)org.jboss.security.SimpleGroup at 12885648(CallerPrincip al(members:iit))org.jboss.security.SimpleGroup at 12885648(admingrp(members:admin))org.jboss.security.SimpleGroup at 12885648(usergrp(members:user))org.jboss.security.SimpleGroup at 12885648(analystgrp(members:analyst))org.jboss.security.SimpleGroup at 12885648(developergrp(members:developer))org.jboss.security.SimpleGroup at 12 885648(managergrp(members:manager)) 13:55:22,538 TRACE [org.jboss.security.authentication.JBossCachedAuthenticationManager] (http--127.0.0.1-8080-2) updateCache, inputSubject=Subject(11883582).principals=org.jboss.security.SimplePrincipal at 25145532(iit)org.jboss.security.SimpleGroup at 12885648(CallerPrincipal(members:iit))org.jboss.security.SimpleGroup @12885648(admingrp(members:admin))org.jboss.security.SimpleGroup at 12885648(usergrp(members:user))org.jboss.security.SimpleGroup at 12885648(analystgrp(members:analyst))org.jboss.security.SimpleGroup at 12885648(developergrp(members:developer))org.jboss.security.SimpleGroup at 12885648(managergrp(members:manager)), cacheSubj ect=Subject(11399784).principals=org.jboss.security.SimplePrincipal at 25145532(iit)org.jboss.security.SimpleGroup at 12885648(CallerPrincipal(members:iit))org.jboss.security.SimpleGroup at 12885648(admingrp(members:admin))org.jboss.security.SimpleGroup at 12885648(usergrp(members:user))org.jboss.security.SimpleGroup at 12885648 (analystgrp(members:analyst))org.jboss.security.SimpleGroup at 12885648(developergrp(members:developer))org.jboss.security.SimpleGroup at 12885648(managergrp(members:manager)) 13:55:22,556 TRACE [org.jboss.security.authentication.JBossCachedAuthenticationManager] (http--127.0.0.1-8080-2) Inserted cache info: org.jboss.security.authentication.JBossCachedAuthenticationManager$DomainInfo at 5bd7b 13:55:22,560 TRACE [org.jboss.security.authentication.JBossCachedAuthenticationManager] (http--127.0.0.1-8080-2) End isValid, true 13:55:22,562 TRACE [org.jboss.security.SecurityRolesAssociation] (http--127.0.0.1-8080-2) Setting threadlocal:null 13:55:22,576 TRACE [org.jboss.security.SecurityRolesAssociation] (http--127.0.0.1-8080-2) Setting threadlocal:null 13:55:22,578 TRACE [org.jboss.security.authentication.JBossCachedAuthenticationManager] (http--127.0.0.1-8080-2) Flushing iit from cache 13:55:22,580 TRACE [org.jboss.security.auth.spi.DatabaseServerLoginModule] (http--127.0.0.1-8080-2) logout 13:55:22,841 TRACE [org.jboss.security.SecurityRolesAssociation] (http--127.0.0.1-8080-3) Setting threadlocal:null 13:55:22,845 TRACE [org.jboss.security.SecurityRolesAssociation] (http--127.0.0.1-8080-2) Setting threadlocal:null 13:55:22,845 TRACE [org.jboss.security.SecurityRolesAssociation] (http--127.0.0.1-8080-1) Setting threadlocal:null Config Tool ******************************************************** ************* Welcome to Kie config CLI **************** ******************************************************** >>Please specify location of the parent folder of .niogit D:\Servers\Drools-6-Deployment\Server-A-As-7\bin >>Please enter command (type help to see available commands): add-role-repo >>Repository alias:netsolrepo >>Security roles (comma separated list):admin,analyst,business,user,developer Result: Role admin added successfully to repository netsolrepo Role analyst added successfully to repository netsolrepo Role business added successfully to repository netsolrepo Role user added successfully to repository netsolrepo Role developer added successfully to repository netsolrepo >>>>>>>>>>>>>>>>>>>>>>>>>>> >>Please enter command (type help to see available commands): add-role-org-unit >>Organizational Unit name:netsol >>Security roles (comma separated list):admin,analyst,business,user,developer Result: Role admin added successfully to Organizational Unit netsol Role analyst added successfully to Organizational Unit netsol Role business added successfully to Organizational Unit netsol Role user added successfully to Organizational Unit netsol Role developer added successfully to Organizational Unit netsol Regards, Zahid Ahmed -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140703/9bb1134c/attachment-0001.html From breesejw at yahoo.com Thu Jul 3 17:15:37 2014 From: breesejw at yahoo.com (James Breese) Date: Thu, 3 Jul 2014 14:15:37 -0700 Subject: [rules-users] Memory leak or rule problem? Message-ID: <340A4D7F-56C5-4546-94F3-FBB7D5B9D35C@yahoo.com> We?re running DROOLS 6.1.0-SNAPSHOT and are seeing unbounded memory growth for certain rules. I?ve put together an example that reproduces the problem using a rule based on (but not identical to) one that we are seeing memory leaks. I?m not sure if the leaks are caused by poorly written rules or by something else. The attached example can be built and run using maven, i.e. ?mvn install exec:exec? It?s running DROOLS in stream mode using a real-time clock and using EQUALITY equals behavior. The input to the rules are events that are identified by their eventId (a long value) and a state enumeration having 3 possible values: ACTIVE, INACTIVE and ACCEPTED. The rules are supposed to work like this: 1. If an event is received with a state of ACTIVE and no event having that eventId has been captured, then capture the event data in a new fact (CapturedEvent) and delete the event. 2. If an event is received with a state of INACTIVE and an event having the same eventId has previously been captured, then delete the CapturedEvent fact. 3. If, after 10 seconds the CapturedEvent fact is still there then set its state to ACCEPTED. 4. All other events facts are deleted. Not a real useful example, but it does demonstrate either a memory leak or a poorly written set of rules. After creating the KieSession in streams mode, the demo starts inserting event facts every 5ms. There are 1000 different eventIds - each iteration of events being inserted sends one event with each eventId. Initially the events state is set to ACTIVE. Periodically the events state is set to INACTIVE for one iteration, then back to ACTIVE. The intent is that 1000 different events will, 10 seconds after they?re first inserted, transition from ACTIVE to ACCEPTED. Then shortly after the INACTIVE events are sent and all 1000 CapturedEvent facts are deleted. The cycle then repeats until 500,000 events have been inserted into the session. Because all events are deleted by one of the rules, at the end of the run there should be 1000 facts of type CapturedEvent in the session since the final iteration of events all have a state of ACTIVE. For example, the set of events look something like this: Time ID State 0.000s 0 ACTIVE 0.005s 1 ACTIVE 0.010s 2 ACTIVE ? 4.995s 999 ACTIVE 5.000s 0 ACTIVE 5.005s 1 ACTIVE ? 9.995s 999 ACTIVE 10.000s 0 ACTIVE 10.005s 1 ACTIVE ? 14.995s 999 ACTIVE 15.000s 0 INACTIVE 15.005s 1 INACTIVE 15.010s 2 INACTIVE ? 19.995s 999 INACTIVE 20.000s 0 ACTIVE and so on until a total of 500,000 events are inserted. Each iteration of 1000 events takes 5 seconds. So basically the first three iterations the events are ACTIVE then the fourth iteration the events are INACTIVE, then three more iterations of ACTIVE, etc. What actually happens is that the rules actually work but only once for each ID. So, for example, the first insert of event ID 0 with state of ACTIVE matches the ?capture active? rule as expected. The second insert of event ID 0 with state of ACTIVE matches the ?delete events? rule. 10 seconds after the first event with ID 0 arrives, the ?ensure active? rule matches. The third ACTIVE event also matches the ?delete event? rule. When the fourth event with ID 0 and state INACTIVE is inserted that matches the ?restart timer? rule which deletes the CapturedEvent fact. When the next event with ID 0 and state ACTIVE is inserted, I expected the ?capture active? rule to fire because the CapturedEvent fact was deleted. But instead the ?delete events? rule matches, and from this point on all events trigger the ?delete events? rule. After garbage collection, analysis of the heap dump shows there are 248,000 instances of org.drools.core.reteoo.RightTuple objects and the same number of org.drools.core.common.PhreakPropagationContext objects. Also, there are 124,000 instances of org.drools.core.common.EventFactHandle objects, even though the reported fact count is 0. The demo project is attached. -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140703/6cc2e548/attachment.html -------------- next part -------------- A non-text attachment was scrubbed... Name: memory-leak.tar.bz2 Type: application/x-bzip2 Size: 5380 bytes Desc: not available Url : http://lists.jboss.org/pipermail/rules-users/attachments/20140703/6cc2e548/attachment.bz2 -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140703/6cc2e548/attachment-0001.html From sumitdhaniya at gmail.com Fri Jul 4 17:23:38 2014 From: sumitdhaniya at gmail.com (Sumit Dhaniya) Date: Fri, 4 Jul 2014 14:23:38 -0700 (PDT) Subject: [rules-users] Kie namespace Message-ID: <1404509018489-4030236.post@n3.nabble.com> I'm trying to configure drools in my spring application but I'm struggling to find even schema location for drools. I tried http://drools.org/schema/kie-spring.xsd but it throws error :- Referenced file contains errors (http://drools.org/schema/kie-spring.xsd). What I need to get it working. Is there any good documentation for spring-integration and performance measures which should be taken. -- View this message in context: http://drools.46999.n3.nabble.com/Kie-namespace-tp4030236.html Sent from the Drools: User forum mailing list archive at Nabble.com. From federico.bertola88 at gmail.com Sat Jul 5 11:34:26 2014 From: federico.bertola88 at gmail.com (Federico Bertola) Date: Sat, 05 Jul 2014 17:34:26 +0200 Subject: [rules-users] Is protobuf cache actually used? In-Reply-To: <1404314280984-4030228.post@n3.nabble.com> References: <1403885772808-4030179.post@n3.nabble.com> <1404314280984-4030228.post@n3.nabble.com> Message-ID: <53B81B02.3090104@gmail.com> Hi, from what I see, the protobuf cache that the KnowledgeBuilder produce and saves as *.cache, is not currently used anywhere, right? If so, what would it be required to reload the compilation data inside the KnowledgeBuilder? There's something I'm missing or there is some piece of code demonstrating this capability? Best regards, Federico. From sumitdhaniya at gmail.com Sat Jul 5 16:29:04 2014 From: sumitdhaniya at gmail.com (Sumit Dhaniya) Date: Sat, 5 Jul 2014 13:29:04 -0700 (PDT) Subject: [rules-users] Rules not picked when packaged inside the JAR In-Reply-To: <1400083985229-4029578.post@n3.nabble.com> References: <1398750710805-4029378.post@n3.nabble.com> <12175C44-DBE9-4E36-B6E9-DA6E4D786B78@codehaus.org> <1399907138229-4029531.post@n3.nabble.com> <1400083985229-4029578.post@n3.nabble.com> Message-ID: <1404592144888-4030239.post@n3.nabble.com> Hi, I'm also trying to create beans of KieBase objects declared in my kmodule.xml file which is in a jar imported by using maven dependencies in my project but it doesn't work. Below are few methodologies I tried :- @KBase(name="defaultKieBase") @KReleaseId(artifactId="com.demo", groupId="FirstDemo", version="1.0") private KieBase kbase; KieServices.Factory.get().newKieContainer(KieServices.Factory.get().newReleaseId("com.demo","FirstDemo","1.0")) nothing works until I import drl files in my project and write own kmodule.xml file. FirstDemo Project is imported correctly using maven I can see it in my dependencies also. Is there anything I'm doing wrong? I'm using spring-tc server and trying this in spring project and I've imported spring-kie and kie-ci and related dependencies in my project. -- View this message in context: http://drools.46999.n3.nabble.com/Rules-not-picked-when-packaged-inside-the-JAR-tp4029378p4030239.html Sent from the Drools: User forum mailing list archive at Nabble.com. From mproctor at codehaus.org Sat Jul 5 18:52:04 2014 From: mproctor at codehaus.org (Mark Proctor) Date: Sat, 5 Jul 2014 23:52:04 +0100 Subject: [rules-users] Kie namespace In-Reply-To: <1404509018489-4030236.post@n3.nabble.com> References: <1404509018489-4030236.post@n3.nabble.com> Message-ID: <097FC7A2-8A45-4141-97CD-DDC20868DC7F@codehaus.org> It?s in the jar: https://github.com/droolsjbpm/droolsjbpm-integration/blob/master/kie-spring/src/main/resources/org/kie/spring/kie-spring-6.0.0.xsd On 4 Jul 2014, at 22:23, Sumit Dhaniya wrote: > I'm trying to configure drools in my spring application but I'm struggling to > find even schema location for drools. I tried > http://drools.org/schema/kie-spring.xsd but it throws error :- > > Referenced file contains errors (http://drools.org/schema/kie-spring.xsd). > > What I need to get it working. Is there any good documentation for > spring-integration and performance measures which should be taken. > > > > -- > View this message in context: http://drools.46999.n3.nabble.com/Kie-namespace-tp4030236.html > Sent from the Drools: User forum mailing list archive at Nabble.com. > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users From zahid.ahmed at emirates.com Sun Jul 6 03:34:39 2014 From: zahid.ahmed at emirates.com (706826) Date: Sun, 6 Jul 2014 00:34:39 -0700 (PDT) Subject: [rules-users] Workbench JAAS Authenticated , But NOT Authorized Message-ID: <1404632079193-4030241.post@n3.nabble.com> Hi, I am configuring DB based JAAS Authentication for Kie-Drools-Workbench 6.1.0. Server log (Pasted Below) shows user is authenticated and roles are assigned to the user. But KIE login form says ?Login failed: Not Authorized ?. I have also added roles in Organizational Unit, Repository and Projects using kie-config-cli. But still getting the same error. Kindly let me know what wrong am I doing. Standalone.xml Kie-drools-wb.War / WEB_INF/jboss-web.xml| drools-guvnor Server Logs 13:55:22,408 TRACE [org.jboss.security.auth.spi.DatabaseServerLoginModule] (http--127.0.0.1-8080-2) initialize 13:55:22,410 TRACE [org.jboss.security.auth.spi.DatabaseServerLoginModule] (http--127.0.0.1-8080-2) Security domain: other 13:55:22,412 TRACE [org.jboss.security.auth.spi.DatabaseServerLoginModule] (http--127.0.0.1-8080-2) Password hashing activated: algorithm = MD5, encoding = base64, charset = UTF-8, callback = null, storeCallback = null 13:55:22,415 TRACE [org.jboss.security.auth.spi.DatabaseServerLoginModule] (http--127.0.0.1-8080-2) DatabaseServerLoginModule, dsJndiName=java:jboss/datasources/jdbc/jbpmStagingRWDS 13:55:22,419 TRACE [org.jboss.security.auth.spi.DatabaseServerLoginModule] (http--127.0.0.1-8080-2) principalsQuery=select PASSWORD from principals where PRINCIPALID=? 13:55:22,422 TRACE [org.jboss.security.auth.spi.DatabaseServerLoginModule] (http--127.0.0.1-8080-2) rolesQuery=select ROLE,ROLEGROUP from roles WHERE principalid=? 13:55:22,424 TRACE [org.jboss.security.auth.spi.DatabaseServerLoginModule] (http--127.0.0.1-8080-2) suspendResume=true 13:55:22,426 TRACE [org.jboss.security.auth.spi.DatabaseServerLoginModule] (http--127.0.0.1-8080-2) login 13:55:22,428 TRACE [org.jboss.security.auth.spi.DatabaseServerLoginModule] (http--127.0.0.1-8080-2) suspendAnyTransaction 13:55:22,489 TRACE [org.jboss.security.auth.spi.DatabaseServerLoginModule] (http--127.0.0.1-8080-2) Excuting query: select PASSWORD from principals where PRINCIPALID=?, with username: iit 13:55:22,495 TRACE [org.jboss.security.auth.spi.DatabaseServerLoginModule] (http--127.0.0.1-8080-2) Obtained user password 13:55:22,497 TRACE [org.jboss.security.auth.spi.DatabaseServerLoginModule] (http--127.0.0.1-8080-2) resumeAnyTransaction 13:55:22,499 TRACE [org.jboss.security.auth.spi.DatabaseServerLoginModule] (http--127.0.0.1-8080-2) User 'iit' authenticated, loginOk=true 13:55:22,501 TRACE [org.jboss.security.auth.spi.DatabaseServerLoginModule] (http--127.0.0.1-8080-2) commit, loginOk=true 13:55:22,503 TRACE [org.jboss.security.auth.spi.DatabaseServerLoginModule] (http--127.0.0.1-8080-2) getRoleSets using rolesQuery: select ROLE,ROLEGROUP from roles WHERE principalid=?, username: iit 13:55:22,507 TRACE [org.jboss.security.auth.spi.DatabaseServerLoginModule] (http--127.0.0.1-8080-2) suspendAnyTransaction 13:55:22,509 TRACE [org.jboss.security.auth.spi.DatabaseServerLoginModule] (http--127.0.0.1-8080-2) Excuting query: select ROLE,ROLEGROUP from roles WHERE principalid=?, with username: iit 13:55:22,514 TRACE [org.jboss.security.auth.spi.DatabaseServerLoginModule] (http--127.0.0.1-8080-2) Assign user to role admin 13:55:22,516 TRACE [org.jboss.security.auth.spi.DatabaseServerLoginModule] (http--127.0.0.1-8080-2) Assign user to role analyst 13:55:22,518 TRACE [org.jboss.security.auth.spi.DatabaseServerLoginModule] (http--127.0.0.1-8080-2) Assign user to role developer 13:55:22,521 TRACE [org.jboss.security.auth.spi.DatabaseServerLoginModule] (http--127.0.0.1-8080-2) Assign user to role manager 13:55:22,523 TRACE [org.jboss.security.auth.spi.DatabaseServerLoginModule] (http--127.0.0.1-8080-2) Assign user to role user 13:55:22,525 TRACE [org.jboss.security.auth.spi.DatabaseServerLoginModule] (http--127.0.0.1-8080-2) resumeAnyTransaction 13:55:22,527 TRACE [org.jboss.security.authentication.JBossCachedAuthenticationManager] (http--127.0.0.1-8080-2) defaultLogin, lc=javax.security.auth.login.LoginContext at 3460a6, subject=Subject(11883582).principals=org.jboss.security.SimplePrincipal at 25145532(iit)org.jboss.security.SimpleGroup at 12885648(CallerPrincip al(members:iit))org.jboss.security.SimpleGroup at 12885648(admingrp(members:admin))org.jboss.security.SimpleGroup at 12885648(usergrp(members:user))org.jboss.security.SimpleGroup at 12885648(analystgrp(members:analyst))org.jboss.security.SimpleGroup at 12885648(developergrp(members:developer))org.jboss.security.SimpleGroup at 12 885648(managergrp(members:manager)) 13:55:22,538 TRACE [org.jboss.security.authentication.JBossCachedAuthenticationManager] (http--127.0.0.1-8080-2) updateCache, inputSubject=Subject(11883582).principals=org.jboss.security.SimplePrincipal at 25145532(iit)org.jboss.security.SimpleGroup at 12885648(CallerPrincipal(members:iit))org.jboss.security.SimpleGroup @12885648(admingrp(members:admin))org.jboss.security.SimpleGroup at 12885648(usergrp(members:user))org.jboss.security.SimpleGroup at 12885648(analystgrp(members:analyst))org.jboss.security.SimpleGroup at 12885648(developergrp(members:developer))org.jboss.security.SimpleGroup at 12885648(managergrp(members:manager)), cacheSubj ect=Subject(11399784).principals=org.jboss.security.SimplePrincipal at 25145532(iit)org.jboss.security.SimpleGroup at 12885648(CallerPrincipal(members:iit))org.jboss.security.SimpleGroup at 12885648(admingrp(members:admin))org.jboss.security.SimpleGroup at 12885648(usergrp(members:user))org.jboss.security.SimpleGroup at 12885648 (analystgrp(members:analyst))org.jboss.security.SimpleGroup at 12885648(developergrp(members:developer))org.jboss.security.SimpleGroup at 12885648(managergrp(members:manager)) 13:55:22,556 TRACE [org.jboss.security.authentication.JBossCachedAuthenticationManager] (http--127.0.0.1-8080-2) Inserted cache info: org.jboss.security.authentication.JBossCachedAuthenticationManager$DomainInfo at 5bd7b 13:55:22,560 TRACE [org.jboss.security.authentication.JBossCachedAuthenticationManager] (http--127.0.0.1-8080-2) End isValid, true 13:55:22,562 TRACE [org.jboss.security.SecurityRolesAssociation] (http--127.0.0.1-8080-2) Setting threadlocal:null 13:55:22,576 TRACE [org.jboss.security.SecurityRolesAssociation] (http--127.0.0.1-8080-2) Setting threadlocal:null 13:55:22,578 TRACE [org.jboss.security.authentication.JBossCachedAuthenticationManager] (http--127.0.0.1-8080-2) Flushing iit from cache 13:55:22,580 TRACE [org.jboss.security.auth.spi.DatabaseServerLoginModule] (http--127.0.0.1-8080-2) logout 13:55:22,841 TRACE [org.jboss.security.SecurityRolesAssociation] (http--127.0.0.1-8080-3) Setting threadlocal:null 13:55:22,845 TRACE [org.jboss.security.SecurityRolesAssociation] (http--127.0.0.1-8080-2) Setting threadlocal:null 13:55:22,845 TRACE [org.jboss.security.SecurityRolesAssociation] (http--127.0.0.1-8080-1) Setting threadlocal:null Config Tool ******************************************************** ************* Welcome to Kie config CLI **************** ******************************************************** >>Please specify location of the parent folder of .niogit D:\Servers\Drools-6-Deployment\Server-A-As-7\bin >>Please enter command (type help to see available commands): add-role-repo >>Repository alias:netsolrepo >>Security roles (comma separated list):admin,analyst,business,user,developer Result: Role admin added successfully to repository netsolrepo Role analyst added successfully to repository netsolrepo Role business added successfully to repository netsolrepo Role user added successfully to repository netsolrepo Role developer added successfully to repository netsolrepo >>>>>>>>>>>>>>>>>>>>>>>>>>> >>Please enter command (type help to see available commands): add-role-org-unit >>Organizational Unit name:netsol >>Security roles (comma separated list):admin,analyst,business,user,developer Result: Role admin added successfully to Organizational Unit netsol Role analyst added successfully to Organizational Unit netsol Role business added successfully to Organizational Unit netsol Role user added successfully to Organizational Unit netsol Role developer added successfully to Organizational Unit netsol Regards, Zahid Ahmed -- View this message in context: http://drools.46999.n3.nabble.com/Workbench-JAAS-Authenticated-But-NOT-Authorized-tp4030241.html Sent from the Drools: User forum mailing list archive at Nabble.com. From sumitdhaniya at gmail.com Sun Jul 6 04:44:31 2014 From: sumitdhaniya at gmail.com (Sumit Dhaniya) Date: Sun, 6 Jul 2014 01:44:31 -0700 (PDT) Subject: [rules-users] Kie namespace In-Reply-To: <097FC7A2-8A45-4141-97CD-DDC20868DC7F@codehaus.org> References: <1404509018489-4030236.post@n3.nabble.com> <097FC7A2-8A45-4141-97CD-DDC20868DC7F@codehaus.org> Message-ID: Thanks Mark, It's still throwing No setter found for property 'kBaseName' in class 'org.kie.spring.factorybeans.KSessionFactoryBean'. On Sun, Jul 6, 2014 at 4:23 AM, Mark Proctor [via Drools] < ml-node+s46999n4030240h76 at n3.nabble.com> wrote: > It?s in the jar: > > https://github.com/droolsjbpm/droolsjbpm-integration/blob/master/kie-spring/src/main/resources/org/kie/spring/kie-spring-6.0.0.xsd > > > On 4 Jul 2014, at 22:23, Sumit Dhaniya <[hidden email] > > wrote: > > > I'm trying to configure drools in my spring application but I'm > struggling to > > find even schema location for drools. I tried > > http://drools.org/schema/kie-spring.xsd but it throws error :- > > > > Referenced file contains errors (http://drools.org/schema/kie-spring.xsd). > > > > > What I need to get it working. Is there any good documentation for > > spring-integration and performance measures which should be taken. > > > > > > > > -- > > View this message in context: > http://drools.46999.n3.nabble.com/Kie-namespace-tp4030236.html > > Sent from the Drools: User forum mailing list archive at Nabble.com. > > _______________________________________________ > > rules-users mailing list > > [hidden email] > > https://lists.jboss.org/mailman/listinfo/rules-users > > > _______________________________________________ > rules-users mailing list > [hidden email] > https://lists.jboss.org/mailman/listinfo/rules-users > > > ------------------------------ > If you reply to this email, your message will be added to the discussion > below: > http://drools.46999.n3.nabble.com/Kie-namespace-tp4030236p4030240.html > To unsubscribe from Kie namespace, click here > > . > NAML > > -- View this message in context: http://drools.46999.n3.nabble.com/Kie-namespace-tp4030236p4030242.html Sent from the Drools: User forum mailing list archive at Nabble.com. -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140706/bd39c6c3/attachment.html From sumitdhaniya at gmail.com Sun Jul 6 04:46:43 2014 From: sumitdhaniya at gmail.com (Sumit Dhaniya) Date: Sun, 6 Jul 2014 01:46:43 -0700 (PDT) Subject: [rules-users] Kie Spring integration Message-ID: <1404636403907-4030243.post@n3.nabble.com> Hi, I'm trying to inject KieBase objects declared in my kmodule.xml file which is in a jar imported by using maven dependencies in my project but it doesn't work. Below are few things I tried :- 1.) @KBase(name="defaultKieBase") @KReleaseId(artifactId="com.demo", groupId="FirstDemo", version="1.0") private KieBase kbase; 2.)KieServices.Factory.get().newKieContainer(KieServices.Factory.get().newReleaseId("com.demo","FirstDemo","1.0")) nothing works until I import drl files in my project and write own kmodule.xml file. FirstDemo Project is imported correctly using maven I can see it in my dependencies also. Is there anything I'm doing wrong? I'm using spring-tc server and trying this in spring project and I've imported spring-kie and kie-ci and related dependencies in my project. -- View this message in context: http://drools.46999.n3.nabble.com/Kie-Spring-integration-tp4030243.html Sent from the Drools: User forum mailing list archive at Nabble.com. From mproctor at codehaus.org Sun Jul 6 10:23:14 2014 From: mproctor at codehaus.org (Mark Proctor) Date: Sun, 6 Jul 2014 15:23:14 +0100 Subject: [rules-users] Kie namespace In-Reply-To: References: <1404509018489-4030236.post@n3.nabble.com> <097FC7A2-8A45-4141-97CD-DDC20868DC7F@codehaus.org> Message-ID: If you think it?s a bug, you?ll need to write a unit test, and submit as a pull request. https://github.com/vinodkiran/droolsjbpm-integration/blob/kmodule-spring/kie-spring/src/test/java/org/kie/spring/tests/KieSpringKModuleTest.java https://github.com/vinodkiran/droolsjbpm-integration/blob/kmodule-spring/kie-spring/src/test/resources/META-INF/kmodule-spring.xml http://docs.jboss.org/drools/release/5.6.0.Final/droolsjbpm-introduction-docs/html/gettingstarted.html mark On 6 Jul 2014, at 09:44, Sumit Dhaniya wrote: > Thanks Mark, > It's still throwing > No setter found for property 'kBaseName' in class 'org.kie.spring.factorybeans.KSessionFactoryBean'. > > > On Sun, Jul 6, 2014 at 4:23 AM, Mark Proctor [via Drools] <[hidden email]> wrote: > It?s in the jar: > https://github.com/droolsjbpm/droolsjbpm-integration/blob/master/kie-spring/src/main/resources/org/kie/spring/kie-spring-6.0.0.xsd > > > On 4 Jul 2014, at 22:23, Sumit Dhaniya <[hidden email]> wrote: > > > I'm trying to configure drools in my spring application but I'm struggling to > > find even schema location for drools. I tried > > http://drools.org/schema/kie-spring.xsd but it throws error :- > > > > Referenced file contains errors (http://drools.org/schema/kie-spring.xsd). > > > > What I need to get it working. Is there any good documentation for > > spring-integration and performance measures which should be taken. > > > > > > > > -- > > View this message in context: http://drools.46999.n3.nabble.com/Kie-namespace-tp4030236.html > > Sent from the Drools: User forum mailing list archive at Nabble.com. > > _______________________________________________ > > rules-users mailing list > > [hidden email] > > https://lists.jboss.org/mailman/listinfo/rules-users > > > _______________________________________________ > rules-users mailing list > [hidden email] > https://lists.jboss.org/mailman/listinfo/rules-users > > > If you reply to this email, your message will be added to the discussion below: > http://drools.46999.n3.nabble.com/Kie-namespace-tp4030236p4030240.html > To unsubscribe from Kie namespace, click here. > NAML > > > View this message in context: Re: [rules-users] Kie namespace > Sent from the Drools: User forum mailing list archive at Nabble.com. > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140706/19cf1643/attachment-0001.html From vinodkiran at usa.net Sun Jul 6 10:31:58 2014 From: vinodkiran at usa.net (vinodkiran) Date: Sun, 6 Jul 2014 07:31:58 -0700 (PDT) Subject: [rules-users] Kie namespace In-Reply-To: References: <1404509018489-4030236.post@n3.nabble.com> <097FC7A2-8A45-4141-97CD-DDC20868DC7F@codehaus.org> Message-ID: <1404657118822-4030245.post@n3.nabble.com> We had users report this error while using Eclipse. I am assuming that this is an error reported by the IDE. Previously, I had debugged this issue with another user and realized that the code works just fine (despite the complaints by the IDE). This is due to certain IDE settings. http://lists.jboss.org/pipermail/rules-users/2014-April/035764.html (look at the other related messages) -Vinod -- View this message in context: http://drools.46999.n3.nabble.com/Kie-namespace-tp4030236p4030245.html Sent from the Drools: User forum mailing list archive at Nabble.com. From vinodkiran at usa.net Sun Jul 6 10:36:02 2014 From: vinodkiran at usa.net (vinodkiran) Date: Sun, 6 Jul 2014 07:36:02 -0700 (PDT) Subject: [rules-users] Kie Spring integration In-Reply-To: <1404636403907-4030243.post@n3.nabble.com> References: <1404636403907-4030243.post@n3.nabble.com> Message-ID: <1404657362415-4030246.post@n3.nabble.com> If you are using kie-spring, you need a spring XML and not a kmodule.xml https://github.com/droolsjbpm/droolsjbpm-integration/blob/master/kie-spring/src/test/resources/org/kie/spring/beans-internal2.xml if you are using kie-spring-annotations, please look at https://github.com/droolsjbpm/droolsjbpm-integration/blob/master/kie-spring/src/test/java/org/kie/spring/beans/annotations/NamedKieBean.java -Vinod -- View this message in context: http://drools.46999.n3.nabble.com/Kie-Spring-integration-tp4030243p4030246.html Sent from the Drools: User forum mailing list archive at Nabble.com. From sumitdhaniya at gmail.com Sun Jul 6 10:53:36 2014 From: sumitdhaniya at gmail.com (sumit dhaniya) Date: Sun, 6 Jul 2014 20:23:36 +0530 Subject: [rules-users] Kie namespace In-Reply-To: <1404657118822-4030245.post@n3.nabble.com> References: <1404509018489-4030236.post@n3.nabble.com> <097FC7A2-8A45-4141-97CD-DDC20868DC7F@codehaus.org> <1404657118822-4030245.post@n3.nabble.com> Message-ID: Yes code works just fine, no error is thrown while running the project. On Sun, Jul 6, 2014 at 8:01 PM, vinodkiran wrote: > We had users report this error while using Eclipse. > > I am assuming that this is an error reported by the IDE. Previously, I had > debugged this issue with another user and realized that the code works just > fine (despite the complaints by the IDE). This is due to certain IDE > settings. > > http://lists.jboss.org/pipermail/rules-users/2014-April/035764.html (look > at > the other related messages) > > -Vinod > > > > -- > View this message in context: > http://drools.46999.n3.nabble.com/Kie-namespace-tp4030236p4030245.html > Sent from the Drools: User forum mailing list archive at Nabble.com. > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140706/719ba9d0/attachment.html From sumitdhaniya at gmail.com Sun Jul 6 11:31:00 2014 From: sumitdhaniya at gmail.com (Sumit Dhaniya) Date: Sun, 6 Jul 2014 08:31:00 -0700 (PDT) Subject: [rules-users] Kie Spring integration In-Reply-To: <1404657362415-4030246.post@n3.nabble.com> References: <1404636403907-4030243.post@n3.nabble.com> <1404657362415-4030246.post@n3.nabble.com> Message-ID: Even if I create a spring integration file it doesn't directly injects the objects i.e. if I use @Inject annotation it throws no qualifying bean exception, but it works if I inject an application context bean and then try to getBean using context.getBean("beanName") method. Note:- bean name is same what I give in @KBase annotation. Moreover if my drl or rdrl files are in a jar which I imported through maven in my project it doesn't load the rules in that Kie Base it just creates a new KieBase object with no rules. But if I put my drl files directly into my resources folder than it works just fine and all rules are fired. On Sun, Jul 6, 2014 at 8:06 PM, vinodkiran [via Drools] < ml-node+s46999n4030246h62 at n3.nabble.com> wrote: > If you are using kie-spring, you need a spring XML and not a kmodule.xml > > > https://github.com/droolsjbpm/droolsjbpm-integration/blob/master/kie-spring/src/test/resources/org/kie/spring/beans-internal2.xml > > > if you are using kie-spring-annotations, please look at > > > https://github.com/droolsjbpm/droolsjbpm-integration/blob/master/kie-spring/src/test/java/org/kie/spring/beans/annotations/NamedKieBean.java > > > -Vinod > > ------------------------------ > If you reply to this email, your message will be added to the discussion > below: > > http://drools.46999.n3.nabble.com/Kie-Spring-integration-tp4030243p4030246.html > To unsubscribe from Kie Spring integration, click here > > . > NAML > > -- View this message in context: http://drools.46999.n3.nabble.com/Kie-Spring-integration-tp4030243p4030248.html Sent from the Drools: User forum mailing list archive at Nabble.com. -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140706/5a9abc0f/attachment.html From vinodkiran at usa.net Sun Jul 6 12:09:07 2014 From: vinodkiran at usa.net (vinodkiran) Date: Sun, 6 Jul 2014 09:09:07 -0700 (PDT) Subject: [rules-users] Kie Spring integration In-Reply-To: <1404636403907-4030243.post@n3.nabble.com> References: <1404636403907-4030243.post@n3.nabble.com> Message-ID: <1404662947998-4030249.post@n3.nabble.com> if you are using a spring XML with annotations please ensure that the following declaration is available in the XML file Sample: https://github.com/droolsjbpm/droolsjbpm-integration/blob/master/kie-spring/src/test/resources/org/kie/spring/annotations/kie-spring-annotations.xml -- View this message in context: http://drools.46999.n3.nabble.com/Kie-Spring-integration-tp4030243p4030249.html Sent from the Drools: User forum mailing list archive at Nabble.com. From sumitdhaniya at gmail.com Sun Jul 6 13:42:01 2014 From: sumitdhaniya at gmail.com (sumit dhaniya) Date: Sun, 6 Jul 2014 23:12:01 +0530 Subject: [rules-users] Kie Spring integration In-Reply-To: <1404662947998-4030249.post@n3.nabble.com> References: <1404636403907-4030243.post@n3.nabble.com> <1404662947998-4030249.post@n3.nabble.com> Message-ID: Sorry I didn't mentioned this earlier but when I deploy my project below are few errors I get :- INFO ClasspathKieProject - Found kmodule: jar:file:/C:/Users/Sumit%20Dhaniya/.m2/repository/com/demo/FirstDemo/1.0/FirstDemo-1.0.jar!/META-INF/kmodule.xml ERROR ClasspathKieProject - Unable to load pom.properties from/C:/Users/Sumit Dhaniya/.m2/repository/com/demo/FirstDemo/1.0/FirstDemo-1.0.jar as jarPath cannot be found /Users/Sumit Dhaniya/.m2/repository/com/demo/FirstDemo/1.0/FirstDemo-1.0.jar ERROR ClasspathKieProject - Unable to load pom.properties from/C:/Users/Sumit Dhaniya/.m2/repository/com/demo/FirstDemo/1.0/FirstDemo-1.0.jar \Users\Sumit Dhaniya\.m2\repository\com\demo\FirstDemo\1.0\FirstDemo-1.0.jar (The system cannot find the path specified) ERROR ClasspathKieProject - Unable to build index of kmodule.xml url=jar:file:/C:/Users/Sumit%20Dhaniya/.m2/repository/com/demo/FirstDemo/1.0/FirstDemo-1.0.jar!/META-INF/kmodule.xml Below is the conf. I did for drools in my conf. file :- On Sun, Jul 6, 2014 at 9:39 PM, vinodkiran wrote: > if you are using a spring XML with annotations please ensure that the > following declaration is available in the XML file > > class="org.kie.spring.annotations.KModuleAnnotationPostProcessor"/> > > Sample: > > > https://github.com/droolsjbpm/droolsjbpm-integration/blob/master/kie-spring/src/test/resources/org/kie/spring/annotations/kie-spring-annotations.xml > > > > > > -- > View this message in context: > http://drools.46999.n3.nabble.com/Kie-Spring-integration-tp4030243p4030249.html > Sent from the Drools: User forum mailing list archive at Nabble.com. > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140706/4f089446/attachment.html From vinodkiran at usa.net Sun Jul 6 19:18:47 2014 From: vinodkiran at usa.net (vinodkiran) Date: Sun, 6 Jul 2014 16:18:47 -0700 (PDT) Subject: [rules-users] Kie Spring integration In-Reply-To: References: <1404636403907-4030243.post@n3.nabble.com> <1404662947998-4030249.post@n3.nabble.com> Message-ID: <1404688727247-4030252.post@n3.nabble.com> try changing your kiePostProcessor from org.kie.spring.KModuleBeanFactoryPostProcessor to the following and then check if the @Inject works. -- View this message in context: http://drools.46999.n3.nabble.com/Kie-Spring-integration-tp4030243p4030252.html Sent from the Drools: User forum mailing list archive at Nabble.com. From sumitdhaniya at gmail.com Sun Jul 6 19:57:40 2014 From: sumitdhaniya at gmail.com (Sumit Dhaniya) Date: Sun, 6 Jul 2014 16:57:40 -0700 (PDT) Subject: [rules-users] Unable to build index of kmodule.xml from Kie project jar Message-ID: <1404691060208-4030253.post@n3.nabble.com> I'm trying to use the Kie jar in my spring project. It successfully identifies the Kie jars in my project but give errors listed below :- INFO ClasspathKieProject - Found kmodule: jar:file:/C:/Users/Sumit%20Dhaniya/.m2/repository/com/demo/FirstDemo/1.0/FirstDemo-1.0.jar!/META-INF/kmodule.xml ERROR ClasspathKieProject - Unable to load pom.properties from/C:/Users/Sumit Dhaniya/.m2/repository/com/demo/FirstDemo/1.0/FirstDemo-1.0.jar as jarPath cannot be found /Users/Sumit Dhaniya/.m2/repository/com/demo/FirstDemo/1.0/FirstDemo-1.0.jar ERROR ClasspathKieProject - Unable to load pom.properties from/C:/Users/Sumit Dhaniya/.m2/repository/com/demo/FirstDemo/1.0/FirstDemo-1.0.jar \Users\Sumit Dhaniya\.m2\repository\com\demo\FirstDemo\1.0\FirstDemo-1.0.jar (The system cannot find the path specified) ERROR ClasspathKieProject - Unable to build index of kmodule.xml url=jar:file:/C:/Users/Sumit%20Dhaniya/.m2/repository/com/demo/FirstDemo/1.0/FirstDemo-1.0.jar!/META-INF/kmodule.xml Even if I define kie modules and sessions in my conf file I can't access the drl and rdrl files in my Kie Project. Though if I create my objects using kieServices.getResources().newUrlResource(url); everything works fine. -- View this message in context: http://drools.46999.n3.nabble.com/Unable-to-build-index-of-kmodule-xml-from-Kie-project-jar-tp4030253.html Sent from the Drools: User forum mailing list archive at Nabble.com. From sumitdhaniya at gmail.com Mon Jul 7 00:51:21 2014 From: sumitdhaniya at gmail.com (Sumit Dhaniya) Date: Sun, 6 Jul 2014 21:51:21 -0700 (PDT) Subject: [rules-users] Repositories in Kie-Drools Message-ID: <1404708681066-4030254.post@n3.nabble.com> I want to use a repository hosted on cloud as repository in my kie ide. I tried creating a new repo cloning an existing repo but after cloning kie ide creates a new repo path at localhost and doesn't uses the cloud repo path. Can I achieve this or I'll have to find a way to sync two repositories one linked to kie and another to cloud repo. -- View this message in context: http://drools.46999.n3.nabble.com/Repositories-in-Kie-Drools-tp4030254.html Sent from the Drools: User forum mailing list archive at Nabble.com. From sumitdhaniya at gmail.com Mon Jul 7 03:16:24 2014 From: sumitdhaniya at gmail.com (sumit dhaniya) Date: Mon, 7 Jul 2014 12:46:24 +0530 Subject: [rules-users] Kie Spring integration In-Reply-To: <1404688727247-4030252.post@n3.nabble.com> References: <1404636403907-4030243.post@n3.nabble.com> <1404662947998-4030249.post@n3.nabble.com> <1404688727247-4030252.post@n3.nabble.com> Message-ID: Thanks Vinod it's working now. This class was not present in last Final release(6.0.1.Final) I updated to latest CR(6.1.0.CR1) and it's working now. Thanks for the help. On Mon, Jul 7, 2014 at 4:48 AM, vinodkiran wrote: > try changing your kiePostProcessor from > org.kie.spring.KModuleBeanFactoryPostProcessor to the following and then > check if the @Inject works. > > class="org.kie.spring.annotations.KModuleAnnotationPostProcessor"/> > > > > -- > View this message in context: > http://drools.46999.n3.nabble.com/Kie-Spring-integration-tp4030243p4030252.html > Sent from the Drools: User forum mailing list archive at Nabble.com. > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140707/e53668ee/attachment.html From 384374128 at qq.com Mon Jul 7 03:21:34 2014 From: 384374128 at qq.com (cheapwatches) Date: Mon, 7 Jul 2014 00:21:34 -0700 (PDT) Subject: [rules-users] =?utf-8?q?Pi=C3=A8ces_de_moteur_diesel_apparaissent?= =?utf-8?q?_principalement_parce_que_la_meilleure_option_pour_les_pi=C3=A8?= =?utf-8?q?ces_qui_peuvent_=C3=AAtre_achet=C3=A9s?= Message-ID: <1404717694912-4030256.post@n3.nabble.com> Diesel a commenc? mod?le de montre-bracelet Mp3player, Bras Mp3 footballeur (WMP-1V), qui avait ?t? parmi les nombreuses premi?res sortes de la voir g?n?ralement ?tre construit. Pour une raison qui ?tait initialement une bonne hop dans un avenir proche, offrant aux consommateurs d'?tre contr?l?es par votre chanson ? travers votre si?ge, mais encore ?tre pr?t ? r?v?ler ? la quantit? de temps. Tout procur? morceaux avec apparaissant motif exclusif qui sera nombreux motif, une bonne direction que semblait sont fournis avec choix extr?mement Diesel instantan?ment. Ao?t 08 aura ?t? d'abord un autre pas en avant consid?rable destin? ? moteur diesel dans le monde entier pour les pi?ces d?s qu'ils ont r?v?l? une Riseman G-SHOCK, qui avait eu des premiers 6 multibande diffusion des pi?ces de moteur diesel internationales sur la vente exploit?s voir hors de tout les marques de voir les, moteur diesel a obtenu en continu avec livr?es correctement la qualit? des syst?mes de leurs morceaux les plus profondes et plus loin et ont tendance ? ?tre ?galement parmi les nombreux meneurs internationaux pour les morceaux en ligne, la place de ces ?galement en charge un grand syst?me de la promouvoir. Syst?mes et aussi des possibilit?s de d?veloppement des syst?mes utilisant r?guli?rement, votre avenir imm?diat ne semble vraiment ?tre exaltante pour moteur diesel, en utilisant d'innombrables curieux de savoir ce que pr?cis?ment votre apr?s voir substantielle pourrait atteindre. Pour votre gars norme, ?tant v?tu d'une montre-bracelet est aussi facile en raison principalement d?tendre avec le choix d'une seule chose qui peut vraiment ?tre attach? sur le triceps / biceps. Si elle va r?v?ler au point dans le temps, il est endommag? wthout utilisant notion suivante. Pourtant, ? votre type qui peut ?tre choisi de mani?re ? ce qu'elle va porter, certes, il est souvent un devez ?tre s?r d'une particuli?re devrait obtenir tout id?al. Sa mise en place pourrait id?al sont vendus entre ?tre habill? dans le si?ge appropri? qui gagnent le meilleur appariement en utilisant les pyjamas des pi?ces de moteur diesel dans la robe ils sont juste habill?es po Tr?s souvent, des pi?ces de moteur diesel apparaissent principalement parce que le meilleure option pour les pi?ces qui peuvent ?tre achet?s. Un Montre Diesel point tout moment tr?s puissant ? la recherche d'un si?ge qui habillera en ressort que les moyens au sein de la voir travailler essentiellement. M?me si vous voulez la mani?re dont il amende toute apparence, peut avoir pour ?tre s?r que vous arrive d'?tre l'achat d'un voir le fait que r?ussit merveilleusement bien. Pi?ces de moteur diesel sont reconnus pour vos moyens de parvenir ? la majorit? minutieux des moyens d'ex?cution. Ceux travail merveilleusement bien pour ce type qui peut ?tre excit? ? propos des nombreux morceaux attributs que votre si?ge peut offrir. -- View this message in context: http://drools.46999.n3.nabble.com/Pieces-de-moteur-diesel-apparaissent-principalement-parce-que-la-meilleure-option-pour-les-pieces-qus-tp4030256.html Sent from the Drools: User forum mailing list archive at Nabble.com. From 384374128 at qq.com Mon Jul 7 03:22:51 2014 From: 384374128 at qq.com (cheapwatches) Date: Mon, 7 Jul 2014 00:22:51 -0700 (PDT) Subject: [rules-users] =?utf-8?q?Diesel_montres_courantes_se_pr=C3=A9sente?= =?utf-8?q?nt_tout_simplement_parce_que_votre_meilleure_option_dans_la_ges?= =?utf-8?q?tion_de_montres_que_vous_pouvez_acheter?= Message-ID: <1404717771049-4030257.post@n3.nabble.com> Diesel annonc? cat?gorie des montres I-pod lecteur mp3, st?r?o Main joueur de poker (WMP-1V), ce fut le commencer avec le type il s'asseoir et regarder rester con?u. Quand quelqu'un est une plong?e importante dans le futur potentiel, aider de nombreuses personnes ? ?tre manipul?s par les propri?taires chansons pr?f?r?es en raison de sa propre s'asseoir et regarder tout en ?tant get pour ?clairer la p?riode de temps. L'application continua de courir Diesel Montre store montres ? la suite d'?tre seul objectif principal r?el pour vous aider principal objectif multicouche, un style importante qui n'a effectivement lieu et m?me voyager un peu rapidement. Mai '08 est une autre r?volution gigantesque con?u pour un moteur diesel ? l'?chelle mondiale dans la gestion de montres devraient-ils d?charg?s que G-SHOCK Riseman, ce n'?tait que dans le monde entier ? commencer par 6 multi-bande le diesel des ondes qui fonctionne sous montres ? vendre restreintes s'asseoir et regarder de tous les produits s'asseoir et regarder, moteur diesel contient fr?quemment et m?me syst?matiquement stimul? l'?tat de concept ? leur fonctionnement montres encore plus loin et plus si sont toujours la gestion ? l'?chelle mondiale en ligne de montres de fonctionnement num?rique, ? laquelle certaines personnes accueillent toujours une colossale partie de la publicit?. Gr?ce notion outre, les probabilit?s de concept de restauration assez fr?quemment, demain ne peuvent appara?tre en effet remarquable dans un moteur diesel, ? travers un certain nombre de penser ? tout ce qui les poss?dent alors une grande s'asseoir et regarder vraiment va acqu?rir. En g?n?ral individuel, ayant sur ??une montre-bracelet est vraiment aussi rapide tout simplement parce que r?pondre et m?me la s?lection de toutes sortes de choses qui est boucl?e dans la branche. En supposant que cela pourrait effectivement ?clairer un temps pr?cieux, il est afflig? sans avoir un moment consid?ration. Puis, dans l'individu qui pourrait ?tre individuel de ce qu'il ou elle les v?tements, ? vrai dire, il est connu comme un devoir de s'assurer qu'une personne fait la meilleure application. Obtenir un emploi mieux peut utiliser le pr?sentant sur le sit parfait et regarder pour vous aider ? aider ? faire juste la bonne formule compte tenu de la diesel autres parties aliment? montres courantes appartenant aux v?tements qu'ils sont vraiment avoir sur. Le plus souvent, ? moteur diesel montres courantes se pr?sentent tout simplement parce que votre meilleure option dans la gestion de montres que vous pouvez acheter. Une chose tr?s importante, une fois l'achat s'asseoir et regarder Diesel Montre prix pour vous aider ? ?tre habill? en est certainement l'occasion appartenant ? l'asseoir et regarder faire tout le travail. Toutefois, vous pourriez d?sirer la bonne fa?on attrayante l'application se sent, en plus il est un ?tre de s'assurer que vous serez en appr?ciant un s'asseoir et regarder ce qui fonctionne totalement claire. Diesel montres courantes sont remarquables pour sa propre possibilit? d'accomplir le bon nombre de prudent occasion de l'op?ration. Beaucoup de ces montres courantes faire le travail tout ? fait clairement pour une personne qui pourrait ?tre port? sur la vari?t? d'options du fait que le s'asseoir et regarder des cadeaux. -- View this message in context: http://drools.46999.n3.nabble.com/Diesel-montres-courantes-se-presentent-tout-simplement-parce-que-votre-meilleure-option-dans-la-gestr-tp4030257.html Sent from the Drools: User forum mailing list archive at Nabble.com. From vinodkiran at usa.net Mon Jul 7 07:09:41 2014 From: vinodkiran at usa.net (vinodkiran) Date: Mon, 7 Jul 2014 04:09:41 -0700 (PDT) Subject: [rules-users] Kie Spring integration In-Reply-To: References: <1404636403907-4030243.post@n3.nabble.com> <1404662947998-4030249.post@n3.nabble.com> <1404688727247-4030252.post@n3.nabble.com> Message-ID: <1404731381781-4030259.post@n3.nabble.com> Annotations support for Kie-spring was introduced in 6.1. This was not part of the 6.0 release. -Vinod -- View this message in context: http://drools.46999.n3.nabble.com/Kie-Spring-integration-tp4030243p4030259.html Sent from the Drools: User forum mailing list archive at Nabble.com. From mproctor at codehaus.org Mon Jul 7 09:08:26 2014 From: mproctor at codehaus.org (Mark Proctor) Date: Mon, 7 Jul 2014 14:08:26 +0100 Subject: [rules-users] Repositories in Kie-Drools In-Reply-To: <1404708681066-4030254.post@n3.nabble.com> References: <1404708681066-4030254.post@n3.nabble.com> Message-ID: <1D0AAD82-0464-4EFB-AAF5-6C60F2EB1D91@codehaus.org> For now you?ll need to setup some manual sync between the two. Mar On 7 Jul 2014, at 05:51, Sumit Dhaniya wrote: > I want to use a repository hosted on cloud as repository in my kie ide. > I tried creating a new repo cloning an existing repo but after cloning kie > ide creates a new repo path at localhost and doesn't uses the cloud repo > path. > Can I achieve this or I'll have to find a way to sync two repositories one > linked to kie and another to cloud repo. > > > > -- > View this message in context: http://drools.46999.n3.nabble.com/Repositories-in-Kie-Drools-tp4030254.html > Sent from the Drools: User forum mailing list archive at Nabble.com. > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users From ed.tirelli at gmail.com Mon Jul 7 15:04:18 2014 From: ed.tirelli at gmail.com (Edson Tirelli) Date: Mon, 7 Jul 2014 15:04:18 -0400 Subject: [rules-users] Is protobuf cache actually used? In-Reply-To: <53B81B02.3090104@gmail.com> References: <1403885772808-4030179.post@n3.nabble.com> <1404314280984-4030228.post@n3.nabble.com> <53B81B02.3090104@gmail.com> Message-ID: Federico, Not sure why you say it is not used? Drools tries to use any pre-compiled resource bytecode if it is available in the cache. If it is not available, it falls back to JIT compilation: https://github.com/droolsjbpm/drools/blob/master/drools-compiler/src/main/java/org/drools/compiler/rule/builder/dialect/java/JavaDialect.java#L627 Edson On Sat, Jul 5, 2014 at 11:34 AM, Federico Bertola wrote: > Hi, > from what I see, the protobuf cache that the KnowledgeBuilder produce > and saves as *.cache, is not currently used anywhere, right? If so, what > would it be required to reload the compilation data inside the > KnowledgeBuilder? There's something I'm missing or there is some piece > of code demonstrating this capability? > > Best regards, > Federico. > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users -- Edson Tirelli Principal Software Engineer Red Hat Business Systems and Intelligence Group From borris at chaos.org.uk Mon Jul 7 17:04:53 2014 From: borris at chaos.org.uk (Borris) Date: Mon, 07 Jul 2014 22:04:53 +0100 Subject: [rules-users] unexpected/spurious ClassCastException Message-ID: <53BB0B75.1010807@chaos.org.uk> I am getting an unexpected cast exception. The backtrace looks like Exception in thread "main" java.lang.ClassCastException: com.tastiereasier.rulez.ContextFoodItem cannot be cast to com.tastiereasier.domain.FoodItem at ConditionEvaluatorb792d1e4169f4ac98945e49e1412d793.evaluate(Unknown Source) at org.drools.core.rule.constraint.MvelConstraint.evaluate(MvelConstraint.java:216) at org.drools.core.rule.constraint.MvelConstraint.isAllowedCachedLeft(MvelConstraint.java:185) at org.drools.core.common.SingleNonIndexSkipBetaConstraints.isAllowedCachedLeft(SingleNonIndexSkipBetaConstraints.java:141) at org.drools.core.phreak.PhreakJoinNode.doLeftInserts(PhreakJoinNode.java:98) at org.drools.core.phreak.PhreakJoinNode.doNode(PhreakJoinNode.java:60) at org.drools.core.phreak.RuleNetworkEvaluator.switchOnDoBetaNode(RuleNetworkEvaluator.java:547) at org.drools.core.phreak.RuleNetworkEvaluator.evalBetaNode(RuleNetworkEvaluator.java:533) at org.drools.core.phreak.RuleNetworkEvaluator.innerEval(RuleNetworkEvaluator.java:334) at org.drools.core.phreak.RuleNetworkEvaluator.evalStackEntry(RuleNetworkEvaluator.java:224) at org.drools.core.phreak.RuleNetworkEvaluator.outerEval(RuleNetworkEvaluator.java:166) at org.drools.core.phreak.RuleNetworkEvaluator.evaluateNetwork(RuleNetworkEvaluator.java:116) at org.drools.core.phreak.RuleExecutor.reEvaluateNetwork(RuleExecutor.java:193) at org.drools.core.phreak.RuleExecutor.evaluateNetworkAndFire(RuleExecutor.java:68) at org.drools.core.common.DefaultAgenda.fireNextItem(DefaultAgenda.java:928) at org.drools.core.common.DefaultAgenda.fireAllRules(DefaultAgenda.java:1193) at org.drools.core.impl.StatefulKnowledgeSessionImpl.fireAllRules(StatefulKnowledgeSessionImpl.java:1202) at org.drools.core.impl.StatefulKnowledgeSessionImpl.fireAllRules(StatefulKnowledgeSessionImpl.java:1175) at com.tastiereasier.rulez.Rulez.insertAndFire(Rulez.java:168) at com.tastiereasier.rulez.Rulez.addDinerToContext(Rulez.java:310) at com.tastiereasier.rulez.Rulez.(Rulez.java:101) at com.tastiereasier.rulez.Rulez.main(Rulez.java:44) The rules that are triggering this are: rule contextDinerDislike enabled true when ContextDiner( $diner; ) DatumPreference ( datumPreferenceType == DatumPreference.Type.PREFERENCE, belief.factor < 0.0, $datum: datum ) from $diner.getDatumPreferences() then insert( new ContextFoodItem( (FoodItem) $datum, true ) ); end rule spotNewContextDinerLike enabled true when ContextDiner( $diner; ) DatumPreference ( datumPreferenceType == DatumPreference.Type.PREFERENCE, belief.factor > 0.0, $datum: datum ) from $diner.getDatumPreferences() then insert( new ContextFoodItem( (FoodItem) $datum, false ) ); end If I disable either rule, then the other proceeds fine and no cast exception happens. I can't see why the cast should ever be asked for - it doesn't make sense. If I changed the boolean parameter in the new in the insert - so both are either true or both are either false, there are no cast exceptions (there must be a clue here). If I put a debug after the insertion, the backtrace actually happens after return from the insert() method - implying it's something on the agenda? I tried using the Audit stuff to see if it gave any clues - but I've never used that before and simply got a heap exhaustion from Eclipse after 1/2 hour trying to ingest something like 200 meg of trace data - I've got a lot of data being initialised into the workspace before these rules get a chance to do anything. It's feeling remarkably like a bug to me, but I don't know how to interpret the backtrace usefully, so it's possible I've got something messed up elsewhere - although I've disabled massive amounts of rules that I can. I grabbed a snapshot last night and it didn't change anything. (I was on a snapshot from early June to fix being able to have Drools editor reference my external jars.) Does this look like a bug or user error? It's going to take some effort to try and extract a test case so I really don't want to spend the effort on that unless it looks the only way. Sage observations most appreciated. Borris From dsotty at gmail.com Mon Jul 7 17:34:10 2014 From: dsotty at gmail.com (Davide Sottara) Date: Mon, 07 Jul 2014 15:34:10 -0600 Subject: [rules-users] unexpected/spurious ClassCastException In-Reply-To: <53BB0B75.1010807@chaos.org.uk> References: <53BB0B75.1010807@chaos.org.uk> Message-ID: <53BB1252.50001@gmail.com> What is the relationship (extends/implements) between the classes/interfaces in your model - ContextFoodItem, FoodItem, ContextDiner, etc.. ? Could you also please specify the version of Drools you are using? Thanks! Davide On 07/07/2014 03:04 PM, Borris wrote: > I am getting an unexpected cast exception. The backtrace looks like > > Exception in thread "main" java.lang.ClassCastException: > com.tastiereasier.rulez.ContextFoodItem cannot be cast to > com.tastiereasier.domain.FoodItem > at > ConditionEvaluatorb792d1e4169f4ac98945e49e1412d793.evaluate(Unknown Source) > at > org.drools.core.rule.constraint.MvelConstraint.evaluate(MvelConstraint.java:216) > at > org.drools.core.rule.constraint.MvelConstraint.isAllowedCachedLeft(MvelConstraint.java:185) > at > org.drools.core.common.SingleNonIndexSkipBetaConstraints.isAllowedCachedLeft(SingleNonIndexSkipBetaConstraints.java:141) > at > org.drools.core.phreak.PhreakJoinNode.doLeftInserts(PhreakJoinNode.java:98) > at org.drools.core.phreak.PhreakJoinNode.doNode(PhreakJoinNode.java:60) > at > org.drools.core.phreak.RuleNetworkEvaluator.switchOnDoBetaNode(RuleNetworkEvaluator.java:547) > at > org.drools.core.phreak.RuleNetworkEvaluator.evalBetaNode(RuleNetworkEvaluator.java:533) > at > org.drools.core.phreak.RuleNetworkEvaluator.innerEval(RuleNetworkEvaluator.java:334) > at > org.drools.core.phreak.RuleNetworkEvaluator.evalStackEntry(RuleNetworkEvaluator.java:224) > at > org.drools.core.phreak.RuleNetworkEvaluator.outerEval(RuleNetworkEvaluator.java:166) > at > org.drools.core.phreak.RuleNetworkEvaluator.evaluateNetwork(RuleNetworkEvaluator.java:116) > at > org.drools.core.phreak.RuleExecutor.reEvaluateNetwork(RuleExecutor.java:193) > at > org.drools.core.phreak.RuleExecutor.evaluateNetworkAndFire(RuleExecutor.java:68) > at > org.drools.core.common.DefaultAgenda.fireNextItem(DefaultAgenda.java:928) > at > org.drools.core.common.DefaultAgenda.fireAllRules(DefaultAgenda.java:1193) > at > org.drools.core.impl.StatefulKnowledgeSessionImpl.fireAllRules(StatefulKnowledgeSessionImpl.java:1202) > at > org.drools.core.impl.StatefulKnowledgeSessionImpl.fireAllRules(StatefulKnowledgeSessionImpl.java:1175) > at com.tastiereasier.rulez.Rulez.insertAndFire(Rulez.java:168) > at com.tastiereasier.rulez.Rulez.addDinerToContext(Rulez.java:310) > at com.tastiereasier.rulez.Rulez.(Rulez.java:101) > at com.tastiereasier.rulez.Rulez.main(Rulez.java:44) > > The rules that are triggering this are: > > rule contextDinerDislike > enabled true > when > ContextDiner( $diner; ) > DatumPreference > ( > datumPreferenceType == DatumPreference.Type.PREFERENCE, > belief.factor < 0.0, > $datum: datum > ) > from $diner.getDatumPreferences() > then > insert( new ContextFoodItem( (FoodItem) $datum, true ) ); > end > > rule spotNewContextDinerLike > enabled true > when > ContextDiner( $diner; ) > DatumPreference > ( > datumPreferenceType == DatumPreference.Type.PREFERENCE, > belief.factor > 0.0, > $datum: datum > ) > from $diner.getDatumPreferences() > then > insert( new ContextFoodItem( (FoodItem) $datum, false ) ); > end > > If I disable either rule, then the other proceeds fine and no cast > exception happens. > > I can't see why the cast should ever be asked for - it doesn't make sense. > > If I changed the boolean parameter in the new in the insert - so both > are either true or both > are either false, there are no cast exceptions (there must be a clue here). > > If I put a debug after the insertion, the backtrace actually happens > after return from the > insert() method - implying it's something on the agenda? > > I tried using the Audit stuff to see if it gave any clues - but I've > never used that before > and simply got a heap exhaustion from Eclipse after 1/2 hour trying to > ingest something like 200 > meg of trace data - I've got a lot of data being initialised into the > workspace before these rules > get a chance to do anything. > > It's feeling remarkably like a bug to me, but I don't know how to > interpret the backtrace usefully, > so it's possible I've got something messed up elsewhere - although I've > disabled massive amounts > of rules that I can. > > I grabbed a snapshot last night and it didn't change anything. (I was on > a snapshot from early June to fix being able to have Drools editor > reference my external jars.) > > Does this look like a bug or user error? It's going to take some effort > to try and extract a test case > so I really don't want to spend the effort on that unless it looks the > only way. > > Sage observations most appreciated. > > Borris > > > > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users > From borris at chaos.org.uk Mon Jul 7 18:09:19 2014 From: borris at chaos.org.uk (Borris) Date: Mon, 07 Jul 2014 23:09:19 +0100 Subject: [rules-users] unexpected/spurious ClassCastException In-Reply-To: <53BB1252.50001@gmail.com> References: <53BB0B75.1010807@chaos.org.uk> <53BB1252.50001@gmail.com> Message-ID: <53BB1A8F.3050108@chaos.org.uk> Hi, Thanks for the response. Version is now 6.1.0.201407061813 (snapshot from last night). Previous version was 6.1.0.201406070605 (snapshot from about a month ago). I was on a snapshot because I wanted the fix for this: https://github.com/droolsjbpm/droolsjbpm-tools/commit/6bc54748e Re "relationships" - hmm, there is a bit happening. ContextDiner is declared in Drools declare ContextDiner diner: Diner @key end ContextFoodItem is declared in Drools and extends an empty declared type: declare ContextRegisterable end I presume an empty declare is legal. declare ContextFoodItem extends ContextRegisterable item: FoodItem @key avoid: boolean @key end FoodItem is declared in Java and extends a small sequence of abstract classes. It is also abstract. The concrete version is for persistence. DatumPreference is declared in Java and is abstract. The concrete version handles item peristence. All instances of $datum are FoodItem - verified with debug print. Anything else I can add that's useful? Borris On Monday 07/07/2014 22:34, Davide Sottara wrote: > What is the relationship (extends/implements) between the classes/interfaces > in your model - ContextFoodItem, FoodItem, ContextDiner, etc.. ? > Could you also please specify the version of Drools you are using? > Thanks! > Davide > > On 07/07/2014 03:04 PM, Borris wrote: >> I am getting an unexpected cast exception. The backtrace looks like >> >> Exception in thread "main" java.lang.ClassCastException: >> com.tastiereasier.rulez.ContextFoodItem cannot be cast to >> com.tastiereasier.domain.FoodItem >> at >> ConditionEvaluatorb792d1e4169f4ac98945e49e1412d793.evaluate(Unknown Source) >> at >> org.drools.core.rule.constraint.MvelConstraint.evaluate(MvelConstraint.java:216) >> at >> org.drools.core.rule.constraint.MvelConstraint.isAllowedCachedLeft(MvelConstraint.java:185) >> at >> org.drools.core.common.SingleNonIndexSkipBetaConstraints.isAllowedCachedLeft(SingleNonIndexSkipBetaConstraints.java:141) >> at >> org.drools.core.phreak.PhreakJoinNode.doLeftInserts(PhreakJoinNode.java:98) >> at org.drools.core.phreak.PhreakJoinNode.doNode(PhreakJoinNode.java:60) >> at >> org.drools.core.phreak.RuleNetworkEvaluator.switchOnDoBetaNode(RuleNetworkEvaluator.java:547) >> at >> org.drools.core.phreak.RuleNetworkEvaluator.evalBetaNode(RuleNetworkEvaluator.java:533) >> at >> org.drools.core.phreak.RuleNetworkEvaluator.innerEval(RuleNetworkEvaluator.java:334) >> at >> org.drools.core.phreak.RuleNetworkEvaluator.evalStackEntry(RuleNetworkEvaluator.java:224) >> at >> org.drools.core.phreak.RuleNetworkEvaluator.outerEval(RuleNetworkEvaluator.java:166) >> at >> org.drools.core.phreak.RuleNetworkEvaluator.evaluateNetwork(RuleNetworkEvaluator.java:116) >> at >> org.drools.core.phreak.RuleExecutor.reEvaluateNetwork(RuleExecutor.java:193) >> at >> org.drools.core.phreak.RuleExecutor.evaluateNetworkAndFire(RuleExecutor.java:68) >> at >> org.drools.core.common.DefaultAgenda.fireNextItem(DefaultAgenda.java:928) >> at >> org.drools.core.common.DefaultAgenda.fireAllRules(DefaultAgenda.java:1193) >> at >> org.drools.core.impl.StatefulKnowledgeSessionImpl.fireAllRules(StatefulKnowledgeSessionImpl.java:1202) >> at >> org.drools.core.impl.StatefulKnowledgeSessionImpl.fireAllRules(StatefulKnowledgeSessionImpl.java:1175) >> at com.tastiereasier.rulez.Rulez.insertAndFire(Rulez.java:168) >> at com.tastiereasier.rulez.Rulez.addDinerToContext(Rulez.java:310) >> at com.tastiereasier.rulez.Rulez.(Rulez.java:101) >> at com.tastiereasier.rulez.Rulez.main(Rulez.java:44) >> >> The rules that are triggering this are: >> >> rule contextDinerDislike >> enabled true >> when >> ContextDiner( $diner; ) >> DatumPreference >> ( >> datumPreferenceType == DatumPreference.Type.PREFERENCE, >> belief.factor < 0.0, >> $datum: datum >> ) >> from $diner.getDatumPreferences() >> then >> insert( new ContextFoodItem( (FoodItem) $datum, true ) ); >> end >> >> rule spotNewContextDinerLike >> enabled true >> when >> ContextDiner( $diner; ) >> DatumPreference >> ( >> datumPreferenceType == DatumPreference.Type.PREFERENCE, >> belief.factor > 0.0, >> $datum: datum >> ) >> from $diner.getDatumPreferences() >> then >> insert( new ContextFoodItem( (FoodItem) $datum, false ) ); >> end >> >> If I disable either rule, then the other proceeds fine and no cast >> exception happens. >> >> I can't see why the cast should ever be asked for - it doesn't make sense. >> >> If I changed the boolean parameter in the new in the insert - so both >> are either true or both >> are either false, there are no cast exceptions (there must be a clue here). >> >> If I put a debug after the insertion, the backtrace actually happens >> after return from the >> insert() method - implying it's something on the agenda? >> >> I tried using the Audit stuff to see if it gave any clues - but I've >> never used that before >> and simply got a heap exhaustion from Eclipse after 1/2 hour trying to >> ingest something like 200 >> meg of trace data - I've got a lot of data being initialised into the >> workspace before these rules >> get a chance to do anything. >> >> It's feeling remarkably like a bug to me, but I don't know how to >> interpret the backtrace usefully, >> so it's possible I've got something messed up elsewhere - although I've >> disabled massive amounts >> of rules that I can. >> >> I grabbed a snapshot last night and it didn't change anything. (I was on >> a snapshot from early June to fix being able to have Drools editor >> reference my external jars.) >> >> Does this look like a bug or user error? It's going to take some effort >> to try and extract a test case >> so I really don't want to spend the effort on that unless it looks the >> only way. >> >> Sage observations most appreciated. >> >> Borris >> >> >> >> _______________________________________________ >> rules-users mailing list >> rules-users at lists.jboss.org >> https://lists.jboss.org/mailman/listinfo/rules-users >> > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users From borris at chaos.org.uk Mon Jul 7 18:24:14 2014 From: borris at chaos.org.uk (Borris) Date: Mon, 07 Jul 2014 23:24:14 +0100 Subject: [rules-users] unexpected/spurious ClassCastException In-Reply-To: <53BB1A8F.3050108@chaos.org.uk> References: <53BB0B75.1010807@chaos.org.uk> <53BB1252.50001@gmail.com> <53BB1A8F.3050108@chaos.org.uk> Message-ID: <53BB1E0E.5090803@chaos.org.uk> On Monday 07/07/2014 23:09, Borris wrote: > Hi, > > Thanks for the response. > > Version is now 6.1.0.201407061813 (snapshot from last night). Previous > version was 6.1.0.201406070605 (snapshot from about a month ago). I was > on a snapshot because I wanted the fix for this: > https://github.com/droolsjbpm/droolsjbpm-tools/commit/6bc54748e Slight "my bad" - I'd forgoten to do a new runtime and use that. Fixed. Still get the same issue, but some of the line numbers are slightly different, in case that's relevant. Exception in thread "main" java.lang.ClassCastException: com.tastiereasier.rulez.ContextFoodItem cannot be cast to com.tastiereasier.domain.FoodItem at ConditionEvaluator3754d879fb5b46a3b2cfbe61326ba9f5.evaluate(Unknown Source) at org.drools.core.rule.constraint.MvelConstraint.evaluate(MvelConstraint.java:216) at org.drools.core.rule.constraint.MvelConstraint.isAllowedCachedLeft(MvelConstraint.java:185) at org.drools.core.common.SingleNonIndexSkipBetaConstraints.isAllowedCachedLeft(SingleNonIndexSkipBetaConstraints.java:141) at org.drools.core.phreak.PhreakJoinNode.doLeftInserts(PhreakJoinNode.java:98) at org.drools.core.phreak.PhreakJoinNode.doNode(PhreakJoinNode.java:60) at org.drools.core.phreak.RuleNetworkEvaluator.switchOnDoBetaNode(RuleNetworkEvaluator.java:547) at org.drools.core.phreak.RuleNetworkEvaluator.evalBetaNode(RuleNetworkEvaluator.java:533) at org.drools.core.phreak.RuleNetworkEvaluator.innerEval(RuleNetworkEvaluator.java:334) at org.drools.core.phreak.RuleNetworkEvaluator.evalStackEntry(RuleNetworkEvaluator.java:224) at org.drools.core.phreak.RuleNetworkEvaluator.outerEval(RuleNetworkEvaluator.java:166) at org.drools.core.phreak.RuleNetworkEvaluator.evaluateNetwork(RuleNetworkEvaluator.java:116) at org.drools.core.phreak.RuleExecutor.reEvaluateNetwork(RuleExecutor.java:216) at org.drools.core.phreak.RuleExecutor.evaluateNetworkAndFire(RuleExecutor.java:91) at org.drools.core.common.DefaultAgenda.fireNextItem(DefaultAgenda.java:964) at org.drools.core.common.DefaultAgenda.fireAllRules(DefaultAgenda.java:1234) at org.drools.core.impl.StatefulKnowledgeSessionImpl.fireAllRules(StatefulKnowledgeSessionImpl.java:1239) at org.drools.core.impl.StatefulKnowledgeSessionImpl.fireAllRules(StatefulKnowledgeSessionImpl.java:1212) at com.tastiereasier.rulez.Rulez.insertAndFire(Rulez.java:168) at com.tastiereasier.rulez.Rulez.addDinerToContext(Rulez.java:310) at com.tastiereasier.rulez.Rulez.(Rulez.java:101) at com.tastiereasier.rulez.Rulez.main(Rulez.java:44) From dsotty at gmail.com Mon Jul 7 18:26:53 2014 From: dsotty at gmail.com (Davide Sottara) Date: Mon, 07 Jul 2014 16:26:53 -0600 Subject: [rules-users] unexpected/spurious ClassCastException In-Reply-To: <53BB1E0E.5090803@chaos.org.uk> References: <53BB0B75.1010807@chaos.org.uk> <53BB1252.50001@gmail.com> <53BB1A8F.3050108@chaos.org.uk> <53BB1E0E.5090803@chaos.org.uk> Message-ID: <53BB1EAD.2070801@gmail.com> I'll try to reproduce the exception with the rule and the data model. Meanwhile, could you share a self-contained unit test that reproduces the problem? That would speed up the fix process Thanks! Davide On 07/07/2014 04:24 PM, Borris wrote: > On Monday 07/07/2014 23:09, Borris wrote: >> Hi, >> >> Thanks for the response. >> >> Version is now 6.1.0.201407061813 (snapshot from last night). Previous >> version was 6.1.0.201406070605 (snapshot from about a month ago). I was >> on a snapshot because I wanted the fix for this: >> https://github.com/droolsjbpm/droolsjbpm-tools/commit/6bc54748e > Slight "my bad" - I'd forgoten to do a new runtime and use that. Fixed. > Still get the same issue, but some of the line numbers are slightly > different, in case that's relevant. > > Exception in thread "main" java.lang.ClassCastException: > com.tastiereasier.rulez.ContextFoodItem cannot be cast to > com.tastiereasier.domain.FoodItem > at > ConditionEvaluator3754d879fb5b46a3b2cfbe61326ba9f5.evaluate(Unknown Source) > at > org.drools.core.rule.constraint.MvelConstraint.evaluate(MvelConstraint.java:216) > at > org.drools.core.rule.constraint.MvelConstraint.isAllowedCachedLeft(MvelConstraint.java:185) > at > org.drools.core.common.SingleNonIndexSkipBetaConstraints.isAllowedCachedLeft(SingleNonIndexSkipBetaConstraints.java:141) > at > org.drools.core.phreak.PhreakJoinNode.doLeftInserts(PhreakJoinNode.java:98) > at org.drools.core.phreak.PhreakJoinNode.doNode(PhreakJoinNode.java:60) > at > org.drools.core.phreak.RuleNetworkEvaluator.switchOnDoBetaNode(RuleNetworkEvaluator.java:547) > at > org.drools.core.phreak.RuleNetworkEvaluator.evalBetaNode(RuleNetworkEvaluator.java:533) > at > org.drools.core.phreak.RuleNetworkEvaluator.innerEval(RuleNetworkEvaluator.java:334) > at > org.drools.core.phreak.RuleNetworkEvaluator.evalStackEntry(RuleNetworkEvaluator.java:224) > at > org.drools.core.phreak.RuleNetworkEvaluator.outerEval(RuleNetworkEvaluator.java:166) > at > org.drools.core.phreak.RuleNetworkEvaluator.evaluateNetwork(RuleNetworkEvaluator.java:116) > at > org.drools.core.phreak.RuleExecutor.reEvaluateNetwork(RuleExecutor.java:216) > at > org.drools.core.phreak.RuleExecutor.evaluateNetworkAndFire(RuleExecutor.java:91) > at > org.drools.core.common.DefaultAgenda.fireNextItem(DefaultAgenda.java:964) > at > org.drools.core.common.DefaultAgenda.fireAllRules(DefaultAgenda.java:1234) > at > org.drools.core.impl.StatefulKnowledgeSessionImpl.fireAllRules(StatefulKnowledgeSessionImpl.java:1239) > at > org.drools.core.impl.StatefulKnowledgeSessionImpl.fireAllRules(StatefulKnowledgeSessionImpl.java:1212) > at com.tastiereasier.rulez.Rulez.insertAndFire(Rulez.java:168) > at com.tastiereasier.rulez.Rulez.addDinerToContext(Rulez.java:310) > at com.tastiereasier.rulez.Rulez.(Rulez.java:101) > at com.tastiereasier.rulez.Rulez.main(Rulez.java:44) > > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users > From borris at chaos.org.uk Mon Jul 7 18:38:30 2014 From: borris at chaos.org.uk (Borris) Date: Mon, 07 Jul 2014 23:38:30 +0100 Subject: [rules-users] unexpected/spurious ClassCastException In-Reply-To: <53BB1EAD.2070801@gmail.com> References: <53BB0B75.1010807@chaos.org.uk> <53BB1252.50001@gmail.com> <53BB1A8F.3050108@chaos.org.uk> <53BB1E0E.5090803@chaos.org.uk> <53BB1EAD.2070801@gmail.com> Message-ID: <53BB2166.1090809@chaos.org.uk> On Monday 07/07/2014 23:26, Davide Sottara wrote: > I'll try to reproduce the exception with the rule and the data model. > Meanwhile, could you share a self-contained unit test that reproduces > the problem? > That would speed up the fix process > Thanks! > Davide > I'll give it a go! Gonna take a lot of frobbing I suspect, but I understand the value of self-contained test cases, so I'll try if you're thinking it is likely a bug. Borris From federico.bertola88 at gmail.com Mon Jul 7 19:01:09 2014 From: federico.bertola88 at gmail.com (Federico Bertola) Date: Tue, 08 Jul 2014 01:01:09 +0200 Subject: [rules-users] Is protobuf cache actually used? In-Reply-To: References: <1403885772808-4030179.post@n3.nabble.com> <1404314280984-4030228.post@n3.nabble.com> <53B81B02.3090104@gmail.com> Message-ID: <53BB26B5.8090308@gmail.com> Hi Edson, yes I saw that the JavaDialect class retrieve the compilation cache from the conf, but after a quick search it seems no one use the setCompilationCache method of KnowledgeBuilderConfigurationImpl, not even in the tests. So I was wondering what was the best way to use it... Maybe I get something wrong, in that case, I apologize :) Federico. On 07/07/2014 21:04, Edson Tirelli wrote: > Federico, > > Not sure why you say it is not used? > > Drools tries to use any pre-compiled resource bytecode if it is > available in the cache. If it is not available, it falls back to JIT > compilation: > > https://github.com/droolsjbpm/drools/blob/master/drools-compiler/src/main/java/org/drools/compiler/rule/builder/dialect/java/JavaDialect.java#L627 > > Edson > > On Sat, Jul 5, 2014 at 11:34 AM, Federico Bertola > wrote: >> Hi, >> from what I see, the protobuf cache that the KnowledgeBuilder produce >> and saves as *.cache, is not currently used anywhere, right? If so, what >> would it be required to reload the compilation data inside the >> KnowledgeBuilder? There's something I'm missing or there is some piece >> of code demonstrating this capability? >> >> Best regards, >> Federico. >> _______________________________________________ >> rules-users mailing list >> rules-users at lists.jboss.org >> https://lists.jboss.org/mailman/listinfo/rules-users > > From borris at chaos.org.uk Mon Jul 7 20:11:53 2014 From: borris at chaos.org.uk (Borris) Date: Tue, 08 Jul 2014 01:11:53 +0100 Subject: [rules-users] unexpected/spurious ClassCastException In-Reply-To: <53BB1EAD.2070801@gmail.com> References: <53BB0B75.1010807@chaos.org.uk> <53BB1252.50001@gmail.com> <53BB1A8F.3050108@chaos.org.uk> <53BB1E0E.5090803@chaos.org.uk> <53BB1EAD.2070801@gmail.com> Message-ID: <53BB3749.30908@chaos.org.uk> On Monday 07/07/2014 23:26, Davide Sottara wrote: > I'll try to reproduce the exception with the rule and the data model. > Meanwhile, could you share a self-contained unit test that reproduces > the problem? > That would speed up the fix process > Thanks! > Davide Hmm. Worked out what is happening. The exception is triggered by these: rule handleComplexFoodItemClash enabled false when $first: ContextFoodItem( $item, true; ) $second: ContextFoodItem( this != $item, avoid == false ) isExampleOf( $second, $first; ) then retract($second); end query isExampleOf (FoodItem $subject, FoodItem $category) ( eval($subject == $category) ) or ( BroaderNarrower($broader, $subject;) and ?isExampleOf($broader, $category;) ) end This is the last thing I was playing with, so maybe not surprising there's an error (the exception arises because of the isExampleOf query and is a simple bug for me to fix). BUT BUT BUT I have "enabled false" as a rule attribute. Am I missing something - I expected this to mean that the when part is never evaluated, but it looks more like the when part is evaluated but consequences are not added to the agenda. The documentation is sufficiently terse that both viewpoints could be argued :( Borris From zahid.ahmed at emirates.com Tue Jul 8 03:17:12 2014 From: zahid.ahmed at emirates.com (Zahid Ahmed) Date: Tue, 8 Jul 2014 07:17:12 +0000 Subject: [rules-users] Repositories in Kie-Drools In-Reply-To: <1D0AAD82-0464-4EFB-AAF5-6C60F2EB1D91@codehaus.org> References: <1404708681066-4030254.post@n3.nabble.com> <1D0AAD82-0464-4EFB-AAF5-6C60F2EB1D91@codehaus.org> Message-ID: Hi Mark, I am facing a repository sync issue in WB configured with ZooKeeper and Helix. But the syncing is not happening. Kindly view the following question posted on drools forum. "Drools Workbench - VFS Repository Clustering - Workbench Assets Not synched" Regards,? Zahid Ahmed -----Original Message----- From: rules-users-bounces at lists.jboss.org [mailto:rules-users-bounces at lists.jboss.org] On Behalf Of Mark Proctor Sent: 07 July 2014 17:08 To: Rules Users List Subject: Re: [rules-users] Repositories in Kie-Drools For now you'll need to setup some manual sync between the two. Mar On 7 Jul 2014, at 05:51, Sumit Dhaniya wrote: > I want to use a repository hosted on cloud as repository in my kie ide. > I tried creating a new repo cloning an existing repo but after cloning > kie ide creates a new repo path at localhost and doesn't uses the > cloud repo path. > Can I achieve this or I'll have to find a way to sync two repositories > one linked to kie and another to cloud repo. > > > > -- > View this message in context: > http://drools.46999.n3.nabble.com/Repositories-in-Kie-Drools-tp4030254 > .html Sent from the Drools: User forum mailing list archive at > Nabble.com. > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users _______________________________________________ rules-users mailing list rules-users at lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users From ed.tirelli at gmail.com Tue Jul 8 08:13:01 2014 From: ed.tirelli at gmail.com (Edson Tirelli) Date: Tue, 8 Jul 2014 08:13:01 -0400 Subject: [rules-users] Is protobuf cache actually used? In-Reply-To: <53BB26B5.8090308@gmail.com> References: <1403885772808-4030179.post@n3.nabble.com> <1404314280984-4030228.post@n3.nabble.com> <53B81B02.3090104@gmail.com> <53BB26B5.8090308@gmail.com> Message-ID: It is a bit convoluted, indeed, but AFAIK, it is using the cache and working fine. The cache is populated here: https://github.com/droolsjbpm/drools/blob/master/drools-compiler/src/main/java/org/drools/compiler/kie/builder/impl/AbstractKieModule.java#L301 It is set here: https://github.com/droolsjbpm/drools/blob/master/drools-compiler/src/main/java/org/drools/compiler/kie/builder/impl/AbstractKieModule.java#L180 And we have some tests here: https://github.com/droolsjbpm/drools/blob/master/drools-compiler/src/test/java/org/drools/compiler/integrationtests/KieCompilationCacheTest.java Edson On Mon, Jul 7, 2014 at 7:01 PM, Federico Bertola wrote: > Hi Edson, > yes I saw that the JavaDialect class retrieve the compilation cache from > the conf, but after a quick search it seems no one use the > setCompilationCache method of KnowledgeBuilderConfigurationImpl, not > even in the tests. So I was wondering what was the best way to use it... > > Maybe I get something wrong, in that case, I apologize :) > > Federico. > > On 07/07/2014 21:04, Edson Tirelli wrote: >> Federico, >> >> Not sure why you say it is not used? >> >> Drools tries to use any pre-compiled resource bytecode if it is >> available in the cache. If it is not available, it falls back to JIT >> compilation: >> >> https://github.com/droolsjbpm/drools/blob/master/drools-compiler/src/main/java/org/drools/compiler/rule/builder/dialect/java/JavaDialect.java#L627 >> >> Edson >> >> On Sat, Jul 5, 2014 at 11:34 AM, Federico Bertola >> wrote: >>> Hi, >>> from what I see, the protobuf cache that the KnowledgeBuilder produce >>> and saves as *.cache, is not currently used anywhere, right? If so, what >>> would it be required to reload the compilation data inside the >>> KnowledgeBuilder? There's something I'm missing or there is some piece >>> of code demonstrating this capability? >>> >>> Best regards, >>> Federico. >>> _______________________________________________ >>> rules-users mailing list >>> rules-users at lists.jboss.org >>> https://lists.jboss.org/mailman/listinfo/rules-users >> >> > > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users -- Edson Tirelli Principal Software Engineer Red Hat Business Systems and Intelligence Group From federico.bertola88 at gmail.com Tue Jul 8 09:31:03 2014 From: federico.bertola88 at gmail.com (Federico Bertola) Date: Tue, 08 Jul 2014 15:31:03 +0200 Subject: [rules-users] Is protobuf cache actually used? In-Reply-To: References: <1403885772808-4030179.post@n3.nabble.com> <1404314280984-4030228.post@n3.nabble.com> <53B81B02.3090104@gmail.com> <53BB26B5.8090308@gmail.com> Message-ID: <53BBF297.9090302@gmail.com> Hi Edson, now I figured that out! Thanks for your patience :) Federico. On 07/08/2014 02:13 PM, Edson Tirelli wrote: > It is a bit convoluted, indeed, but AFAIK, it is using the cache > and working fine. The cache is populated here: > > https://github.com/droolsjbpm/drools/blob/master/drools-compiler/src/main/java/org/drools/compiler/kie/builder/impl/AbstractKieModule.java#L301 > > It is set here: > > https://github.com/droolsjbpm/drools/blob/master/drools-compiler/src/main/java/org/drools/compiler/kie/builder/impl/AbstractKieModule.java#L180 > > And we have some tests here: > > https://github.com/droolsjbpm/drools/blob/master/drools-compiler/src/test/java/org/drools/compiler/integrationtests/KieCompilationCacheTest.java > > > Edson > > On Mon, Jul 7, 2014 at 7:01 PM, Federico Bertola > wrote: >> Hi Edson, >> yes I saw that the JavaDialect class retrieve the compilation cache from >> the conf, but after a quick search it seems no one use the >> setCompilationCache method of KnowledgeBuilderConfigurationImpl, not >> even in the tests. So I was wondering what was the best way to use it... >> >> Maybe I get something wrong, in that case, I apologize :) >> >> Federico. >> >> On 07/07/2014 21:04, Edson Tirelli wrote: >>> Federico, >>> >>> Not sure why you say it is not used? >>> >>> Drools tries to use any pre-compiled resource bytecode if it is >>> available in the cache. If it is not available, it falls back to JIT >>> compilation: >>> >>> https://github.com/droolsjbpm/drools/blob/master/drools-compiler/src/main/java/org/drools/compiler/rule/builder/dialect/java/JavaDialect.java#L627 >>> >>> Edson >>> >>> On Sat, Jul 5, 2014 at 11:34 AM, Federico Bertola >>> wrote: >>>> Hi, >>>> from what I see, the protobuf cache that the KnowledgeBuilder produce >>>> and saves as *.cache, is not currently used anywhere, right? If so, what >>>> would it be required to reload the compilation data inside the >>>> KnowledgeBuilder? There's something I'm missing or there is some piece >>>> of code demonstrating this capability? >>>> >>>> Best regards, >>>> Federico. >>>> _______________________________________________ >>>> rules-users mailing list >>>> rules-users at lists.jboss.org >>>> https://lists.jboss.org/mailman/listinfo/rules-users >>> >> _______________________________________________ >> rules-users mailing list >> rules-users at lists.jboss.org >> https://lists.jboss.org/mailman/listinfo/rules-users > > From borris at chaos.org.uk Wed Jul 9 07:23:28 2014 From: borris at chaos.org.uk (Borris) Date: Wed, 09 Jul 2014 12:23:28 +0100 Subject: [rules-users] unexpected/spurious ClassCastException In-Reply-To: <53BB3749.30908@chaos.org.uk> References: <53BB0B75.1010807@chaos.org.uk> <53BB1252.50001@gmail.com> <53BB1A8F.3050108@chaos.org.uk> <53BB1E0E.5090803@chaos.org.uk> <53BB1EAD.2070801@gmail.com> <53BB3749.30908@chaos.org.uk> Message-ID: <53BD2630.9080304@chaos.org.uk> > BUT BUT BUT I have "enabled false" as a rule attribute. What is the meaning of "enabled false" as a rule attribute please? Thanks, Borris From jps at jps.ch Wed Jul 9 10:46:19 2014 From: jps at jps.ch (jps) Date: Wed, 9 Jul 2014 07:46:19 -0700 (PDT) Subject: [rules-users] drools-wb 6.1.0.CR1-wildfly - error when upload jar M2 Repo Message-ID: <1404917178976-4030276.post@n3.nabble.com> Hello, I've installed kie-drools-wb-distribution-wars-6.1.0.CR1-wildfly with all the defaults - i.e m2 repo is in WIDLFLY_HOME/bin/repositories/kie) and everything works fine so, except that I can't manage to upload a JAR. The JAR I'm trying to upload is a mavenized JAR, it has no dependencies but a parent pom. I get this Exception in the logs : 16:33:54,459 ERROR [io.undertow.request] (default task-9) UT005023: Exception handling request to /kie-drools-wb-distribution-wars-6.1.0.CR1-wildfly/org.kie.workbench.drools.KIEDroolsWebapp/m2repo/file: java.lang.LinkageError: com/ning/http/client/providers/netty/NettyAsyncHttpProvider at org.sonatype.maven.wagon.AhcWagon.openConnectionInternal(AhcWagon.java:150) [wagon-ahc-1.2.1.jar:] at org.apache.maven.wagon.AbstractWagon.openConnection(AbstractWagon.java:105) [wagon-provider-api-1.0.jar:1.0] at org.apache.maven.wagon.AbstractWagon.connect(AbstractWagon.java:207) [wagon-provider-api-1.0.jar:1.0] at org.sonatype.aether.connector.wagon.WagonRepositoryConnector.connectWagon(WagonRepositoryConnector.java:345) [aether-connector-wagon-1.13.1.jar:] at org.sonatype.aether.connector.wagon.WagonRepositoryConnector.pollWagon(WagonRepositoryConnector.java:385) [aether-connector-wagon-1.13.1.jar:] at org.sonatype.aether.connector.wagon.WagonRepositoryConnector$GetTask.run(WagonRepositoryConnector.java:571) [aether-connector-wagon-1.13.1.jar:] at org.sonatype.aether.util.concurrency.RunnableErrorForwarder$1.run(RunnableErrorForwarder.java:60) [aether-util-1.13.1.jar:] at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110) [rt.jar:1.7.0_11] at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603) [rt.jar:1.7.0_11] at java.lang.Thread.run(Thread.java:722) [rt.jar:1.7.0_11] 16:33:54,463 ERROR [stderr] (pool-14-thread-1) Exception in thread "pool-14-thread-1" java.lang.LinkageError: com/ning/http/client/providers/netty/NettyAsyncHttpProvider 16:33:54,464 ERROR [stderr] (pool-14-thread-1) at org.sonatype.maven.wagon.AhcWagon.openConnectionInternal(AhcWagon.java:150) 16:33:54,464 ERROR [stderr] (pool-14-thread-1) at org.apache.maven.wagon.AbstractWagon.openConnection(AbstractWagon.java:105) 16:33:54,471 ERROR [stderr] (pool-14-thread-1) at org.apache.maven.wagon.AbstractWagon.connect(AbstractWagon.java:207) 16:33:54,472 ERROR [stderr] (pool-14-thread-1) at org.sonatype.aether.connector.wagon.WagonRepositoryConnector.connectWagon(WagonRepositoryConnector.java:345) 16:33:54,473 ERROR [stderr] (pool-14-thread-1) at org.sonatype.aether.connector.wagon.WagonRepositoryConnector.pollWagon(WagonRepositoryConnector.java:385) 16:33:54,473 ERROR [stderr] (pool-14-thread-1) at org.sonatype.aether.connector.wagon.WagonRepositoryConnector$GetTask.run(WagonRepositoryConnector.java:571) 16:33:54,474 ERROR [stderr] (pool-14-thread-1) at org.sonatype.aether.util.concurrency.RunnableErrorForwarder$1.run(RunnableErrorForwarder.java:60) 16:33:54,474 ERROR [stderr] (pool-14-thread-1) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110) 16:33:54,474 ERROR [stderr] (pool-14-thread-1) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603) 16:33:54,475 ERROR [stderr] (pool-14-thread-1) at java.lang.Thread.run(Thread.java:722) I also try to upload my parent pom ... but I get an error message "The JAR does not contain a valid pom" ... of course it's not a JAR, it's just a pom.xml Can someone give me some hints on how to do this ? Can I workaround and do a "mvn install" to put the JAR in the REPO under WIDLFLY_HOME/bin/repositories/kie ? Any help or hint would be appreciated. Regards -JPS -- View this message in context: http://drools.46999.n3.nabble.com/drools-wb-6-1-0-CR1-wildfly-error-when-upload-jar-M2-Repo-tp4030276.html Sent from the Drools: User forum mailing list archive at Nabble.com. From jps at jps.ch Wed Jul 9 10:47:30 2014 From: jps at jps.ch (jps) Date: Wed, 9 Jul 2014 07:47:30 -0700 (PDT) Subject: [rules-users] kie-drools-wb-6.0.1 : view "artifact repository" is empty In-Reply-To: <1395753718345-4028957.post@n3.nabble.com> References: <1395753718345-4028957.post@n3.nabble.com> Message-ID: <1404917250908-4030277.post@n3.nabble.com> Reinstalled ok ! -- View this message in context: http://drools.46999.n3.nabble.com/kie-drools-wb-6-0-1-view-artifact-repository-is-empty-tp4028957p4030277.html Sent from the Drools: User forum mailing list archive at Nabble.com. From michael.anstis at gmail.com Wed Jul 9 11:27:30 2014 From: michael.anstis at gmail.com (Michael Anstis) Date: Wed, 9 Jul 2014 16:27:30 +0100 Subject: [rules-users] drools-wb 6.1.0.CR1-wildfly - error when upload jar M2 Repo In-Reply-To: <1404917178976-4030276.post@n3.nabble.com> References: <1404917178976-4030276.post@n3.nabble.com> Message-ID: 6.1.0.CR2 is now released. I tried uploading a JAR to the Artifact Repository using this version and it was OK (JDK1.7.0_51 and Wildfly 8.1.0.Final). Can you re-test with the latest CR? On 9 July 2014 15:46, jps wrote: > Hello, > > I've installed kie-drools-wb-distribution-wars-6.1.0.CR1-wildfly with all > the defaults - i.e m2 repo is in WIDLFLY_HOME/bin/repositories/kie) and > everything works fine so, except that I can't manage to upload a JAR. > > The JAR I'm trying to upload is a mavenized JAR, it has no dependencies but > a parent pom. I get this Exception in the logs : > > 16:33:54,459 ERROR [io.undertow.request] (default task-9) UT005023: > Exception handling request to > > /kie-drools-wb-distribution-wars-6.1.0.CR1-wildfly/org.kie.workbench.drools.KIEDroolsWebapp/m2repo/file: > java.lang.LinkageError: > com/ning/http/client/providers/netty/NettyAsyncHttpProvider > at > org.sonatype.maven.wagon.AhcWagon.openConnectionInternal(AhcWagon.java:150) > [wagon-ahc-1.2.1.jar:] > at > org.apache.maven.wagon.AbstractWagon.openConnection(AbstractWagon.java:105) > [wagon-provider-api-1.0.jar:1.0] > at > org.apache.maven.wagon.AbstractWagon.connect(AbstractWagon.java:207) > [wagon-provider-api-1.0.jar:1.0] > at > > org.sonatype.aether.connector.wagon.WagonRepositoryConnector.connectWagon(WagonRepositoryConnector.java:345) > [aether-connector-wagon-1.13.1.jar:] > at > > org.sonatype.aether.connector.wagon.WagonRepositoryConnector.pollWagon(WagonRepositoryConnector.java:385) > [aether-connector-wagon-1.13.1.jar:] > at > > org.sonatype.aether.connector.wagon.WagonRepositoryConnector$GetTask.run(WagonRepositoryConnector.java:571) > [aether-connector-wagon-1.13.1.jar:] > at > > org.sonatype.aether.util.concurrency.RunnableErrorForwarder$1.run(RunnableErrorForwarder.java:60) > [aether-util-1.13.1.jar:] > at > > java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110) > [rt.jar:1.7.0_11] > at > > java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603) > [rt.jar:1.7.0_11] > at java.lang.Thread.run(Thread.java:722) [rt.jar:1.7.0_11] > > 16:33:54,463 ERROR [stderr] (pool-14-thread-1) Exception in thread > "pool-14-thread-1" java.lang.LinkageError: > com/ning/http/client/providers/netty/NettyAsyncHttpProvider > 16:33:54,464 ERROR [stderr] (pool-14-thread-1) at > org.sonatype.maven.wagon.AhcWagon.openConnectionInternal(AhcWagon.java:150) > 16:33:54,464 ERROR [stderr] (pool-14-thread-1) at > org.apache.maven.wagon.AbstractWagon.openConnection(AbstractWagon.java:105) > 16:33:54,471 ERROR [stderr] (pool-14-thread-1) at > org.apache.maven.wagon.AbstractWagon.connect(AbstractWagon.java:207) > 16:33:54,472 ERROR [stderr] (pool-14-thread-1) at > > org.sonatype.aether.connector.wagon.WagonRepositoryConnector.connectWagon(WagonRepositoryConnector.java:345) > 16:33:54,473 ERROR [stderr] (pool-14-thread-1) at > > org.sonatype.aether.connector.wagon.WagonRepositoryConnector.pollWagon(WagonRepositoryConnector.java:385) > 16:33:54,473 ERROR [stderr] (pool-14-thread-1) at > > org.sonatype.aether.connector.wagon.WagonRepositoryConnector$GetTask.run(WagonRepositoryConnector.java:571) > 16:33:54,474 ERROR [stderr] (pool-14-thread-1) at > > org.sonatype.aether.util.concurrency.RunnableErrorForwarder$1.run(RunnableErrorForwarder.java:60) > 16:33:54,474 ERROR [stderr] (pool-14-thread-1) at > > java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110) > 16:33:54,474 ERROR [stderr] (pool-14-thread-1) at > > java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603) > 16:33:54,475 ERROR [stderr] (pool-14-thread-1) at > java.lang.Thread.run(Thread.java:722) > > > I also try to upload my parent pom ... but I get an error message "The JAR > does not contain a valid pom" ... of course it's not a JAR, it's just a > pom.xml > > Can someone give me some hints on how to do this ? > > Can I workaround and do a "mvn install" to put the JAR in the REPO under > WIDLFLY_HOME/bin/repositories/kie ? > > Any help or hint would be appreciated. > > > Regards > -JPS > > > > > -- > View this message in context: > http://drools.46999.n3.nabble.com/drools-wb-6-1-0-CR1-wildfly-error-when-upload-jar-M2-Repo-tp4030276.html > Sent from the Drools: User forum mailing list archive at Nabble.com. > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140709/60c920be/attachment-0001.html From dsotty at gmail.com Wed Jul 9 09:41:10 2014 From: dsotty at gmail.com (Davide Sottara) Date: Wed, 09 Jul 2014 07:41:10 -0600 Subject: [rules-users] unexpected/spurious ClassCastException In-Reply-To: <53BB3749.30908@chaos.org.uk> References: <53BB0B75.1010807@chaos.org.uk> <53BB1252.50001@gmail.com> <53BB1A8F.3050108@chaos.org.uk> <53BB1E0E.5090803@chaos.org.uk> <53BB1EAD.2070801@gmail.com> <53BB3749.30908@chaos.org.uk> Message-ID: <53BD4676.5040907@gmail.com> Sorry for not being able to get back to you again earlier. Yes, the rule / query you are showing makes sense - I would have asked you for something similar :) It is definitely a bug in the resolution of the class that defines an attribute, we could really use the reproducer to fix it quickly. I'll check the "enabled" attribute's behavior in 6.x Thanks Davide On 07/07/2014 06:11 PM, Borris wrote: > On Monday 07/07/2014 23:26, Davide Sottara wrote: >> I'll try to reproduce the exception with the rule and the data model. >> Meanwhile, could you share a self-contained unit test that reproduces >> the problem? >> That would speed up the fix process >> Thanks! >> Davide > Hmm. Worked out what is happening. The exception is triggered by these: > > rule handleComplexFoodItemClash > enabled false > when > $first: ContextFoodItem( $item, true; ) > $second: ContextFoodItem( this != $item, avoid == false ) > isExampleOf( $second, $first; ) > then > retract($second); > end > > query isExampleOf (FoodItem $subject, FoodItem $category) > ( > eval($subject == $category) > ) > or > ( > BroaderNarrower($broader, $subject;) > and > ?isExampleOf($broader, $category;) > ) > end > > This is the last thing I was playing with, so maybe not surprising > there's an error (the exception arises because of the isExampleOf query > and is a simple bug for me to fix). > > BUT BUT BUT I have "enabled false" as a rule attribute. Am I missing > something - I expected this to mean that the when part is never > evaluated, but it looks more like the when part is evaluated but > consequences are not added to the agenda. The documentation is > sufficiently terse that both viewpoints could be argued :( > > Borris > > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users > From borris at chaos.org.uk Wed Jul 9 13:49:37 2014 From: borris at chaos.org.uk (Borris) Date: Wed, 09 Jul 2014 18:49:37 +0100 Subject: [rules-users] unexpected/spurious ClassCastException In-Reply-To: <53BD4676.5040907@gmail.com> References: <53BB0B75.1010807@chaos.org.uk> <53BB1252.50001@gmail.com> <53BB1A8F.3050108@chaos.org.uk> <53BB1E0E.5090803@chaos.org.uk> <53BB1EAD.2070801@gmail.com> <53BB3749.30908@chaos.org.uk> <53BD4676.5040907@gmail.com> Message-ID: <53BD80B1.5040702@chaos.org.uk> On Wednesday 09/07/2014 14:41, Davide Sottara wrote: > Sorry for not being able to get back to you again earlier. > Yes, the rule / query you are showing makes sense - I would have asked > you for something similar :) It is definitely a bug in the resolution of > the class that defines an attribute, we could really use the reproducer > to fix it quickly. > > I'll check the "enabled" attribute's behavior in 6.x > Thanks > Davide I'll tidy up the the test case I've generated and email it to you. Just to be clear, the cast exception was caused by a mistake on my part in the when part of a rule, but in a rule with an "enabled false" attribute. I had done the standard thing of gradually disabling bits until the error went away, but had not allowed for the exception being triggered with enabled false, so had assumed (not unreasonably I argue :) ) that the initially supplied rules must be the cause of the problem. At least, that's my conclusion - but the test case will let you decide independently. Borris From sumitdhaniya at gmail.com Wed Jul 9 14:20:03 2014 From: sumitdhaniya at gmail.com (Sumit Dhaniya) Date: Wed, 9 Jul 2014 11:20:03 -0700 (PDT) Subject: [rules-users] condition on size of list Message-ID: <1404930003793-4030283.post@n3.nabble.com> I know we can check size of list if we write free form drl but is it possible to use size of the list as condition in guided decision table? -- View this message in context: http://drools.46999.n3.nabble.com/condition-on-size-of-list-tp4030283.html Sent from the Drools: User forum mailing list archive at Nabble.com. From michael.anstis at gmail.com Wed Jul 9 14:22:56 2014 From: michael.anstis at gmail.com (Michael Anstis) Date: Wed, 9 Jul 2014 19:22:56 +0100 Subject: [rules-users] condition on size of list In-Reply-To: <1404930003793-4030283.post@n3.nabble.com> References: <1404930003793-4030283.post@n3.nabble.com> Message-ID: Yes. Create a BRL Condition column and use an expression on the List pattern. Sent on the move On 9 Jul 2014 19:21, "Sumit Dhaniya" wrote: > I know we can check size of list if we write free form drl but is it > possible > to use size of the list as condition in guided decision table? > > > > -- > View this message in context: > http://drools.46999.n3.nabble.com/condition-on-size-of-list-tp4030283.html > Sent from the Drools: User forum mailing list archive at Nabble.com. > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140709/7461da5a/attachment.html From dsotty at gmail.com Wed Jul 9 20:15:52 2014 From: dsotty at gmail.com (Davide Sottara) Date: Wed, 09 Jul 2014 18:15:52 -0600 Subject: [rules-users] unexpected/spurious ClassCastException In-Reply-To: <53BD80B1.5040702@chaos.org.uk> References: <53BB0B75.1010807@chaos.org.uk> <53BB1252.50001@gmail.com> <53BB1A8F.3050108@chaos.org.uk> <53BB1E0E.5090803@chaos.org.uk> <53BB1EAD.2070801@gmail.com> <53BB3749.30908@chaos.org.uk> <53BD4676.5040907@gmail.com> <53BD80B1.5040702@chaos.org.uk> Message-ID: <53BDDB38.2040802@gmail.com> Ok, so there is indeed a problem in the way the query is invoked The input arguments are of type ContextFoodItem, while the formal arguments of the query are FoodItem. The compiler should do a type check (which is probably missing) and report an error at compile time. This throws an exception in the query body, and this is the exception I see when I run your test case. java.lang.RuntimeException: com.sample.Rule_isExampleOf0Eval0Invoker at 152d453a : java.lang.ClassCastException: com.sample.ContextFoodItem cannot be cast to com.sample.FoodItem at org.drools.core.rule.EvalCondition.isAllowed(EvalCondition.java:123) at org.drools.core.phreak.PhreakEvalNode.doLeftInserts(PhreakEvalNode.java:55) Actually, the exception you reported initially was Exception in thread "main" java.lang.ClassCastException: com.tastiereasier.rulez.ContextFoodItem cannot be cast to com.tastiereasier.domain.FoodItem at ConditionEvaluator3754d879fb5b46a3b2cfbe61326ba9f5.evaluate(Unknown Source) at org.drools.core.rule.constraint.MvelConstraint.evaluate(MvelConstraint.java:216) at org.drools.core.rule.constraint.MvelConstraint.isAllowedCachedLeft(MvelConstraint.java:185) at .... but it probably happens if the second part of the query - the join with the recursive call - is triggered. As for the "enabled" flag, it does not prevent the evaluation of the LHS. It only disables the actual execution of the RHS. Let me investigate some more Davide On 07/09/2014 11:49 AM, Borris wrote: > On Wednesday 09/07/2014 14:41, Davide Sottara wrote: >> Sorry for not being able to get back to you again earlier. >> Yes, the rule / query you are showing makes sense - I would have asked >> you for something similar :) It is definitely a bug in the resolution of >> the class that defines an attribute, we could really use the reproducer >> to fix it quickly. >> >> I'll check the "enabled" attribute's behavior in 6.x >> Thanks >> Davide > I'll tidy up the the test case I've generated and email it to you. > > Just to be clear, the cast exception was caused by a mistake on my part > in the when part of a rule, but in a rule with an "enabled false" > attribute. I had done the standard thing of gradually disabling bits > until the error went away, but had not allowed for the exception being > triggered with enabled false, so had assumed (not unreasonably I argue > :) ) that the initially supplied rules must be the cause of the problem. > > At least, that's my conclusion - but the test case will let you decide > independently. > > Borris > > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users > From sumitdhaniya at gmail.com Thu Jul 10 08:10:04 2014 From: sumitdhaniya at gmail.com (sumit dhaniya) Date: Thu, 10 Jul 2014 17:40:04 +0530 Subject: [rules-users] condition on size of list In-Reply-To: References: <1404930003793-4030283.post@n3.nabble.com> Message-ID: listIf I use model classes created in JAVA with some java.util.List it identifies them as Collection(superclass of List) and then list options like size,first,last doesn't show up. Is there any way I can force these objects as type of List. On Wed, Jul 9, 2014 at 11:52 PM, Michael Anstis wrote: > Yes. > > Create a BRL Condition column and use an expression on the List pattern. > > Sent on the move > On 9 Jul 2014 19:21, "Sumit Dhaniya" wrote: > >> I know we can check size of list if we write free form drl but is it >> possible >> to use size of the list as condition in guided decision table? >> >> >> >> -- >> View this message in context: >> http://drools.46999.n3.nabble.com/condition-on-size-of-list-tp4030283.html >> Sent from the Drools: User forum mailing list archive at Nabble.com. >> _______________________________________________ >> rules-users mailing list >> rules-users at lists.jboss.org >> https://lists.jboss.org/mailman/listinfo/rules-users >> > > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140710/2eaa3924/attachment.html From sumitdhaniya at gmail.com Thu Jul 10 08:48:57 2014 From: sumitdhaniya at gmail.com (Sumit Dhaniya) Date: Thu, 10 Jul 2014 05:48:57 -0700 (PDT) Subject: [rules-users] retainAll function on collections Message-ID: <1404996537108-4030288.post@n3.nabble.com> Is there anything complementary to retainAll() in JAVA. Is there any way I could apply a condition on number of elements common in two lists. -- View this message in context: http://drools.46999.n3.nabble.com/retainAll-function-on-collections-tp4030288.html Sent from the Drools: User forum mailing list archive at Nabble.com. From michael.anstis at gmail.com Thu Jul 10 09:38:09 2014 From: michael.anstis at gmail.com (Michael Anstis) Date: Thu, 10 Jul 2014 14:38:09 +0100 Subject: [rules-users] condition on size of list In-Reply-To: References: <1404930003793-4030283.post@n3.nabble.com> Message-ID: Did you import java.util.List (in Project Editor's "Import suggestions" and then on the editor's "Config" tab)? On 10 July 2014 13:10, sumit dhaniya wrote: > listIf I use model classes created in JAVA with some java.util.List it > identifies them as Collection(superclass of List) and then list options > like size,first,last doesn't show up. Is there any way I can force these > objects as type of List. > > > On Wed, Jul 9, 2014 at 11:52 PM, Michael Anstis > wrote: > >> Yes. >> >> Create a BRL Condition column and use an expression on the List pattern. >> >> Sent on the move >> On 9 Jul 2014 19:21, "Sumit Dhaniya" wrote: >> >>> I know we can check size of list if we write free form drl but is it >>> possible >>> to use size of the list as condition in guided decision table? >>> >>> >>> >>> -- >>> View this message in context: >>> http://drools.46999.n3.nabble.com/condition-on-size-of-list-tp4030283.html >>> Sent from the Drools: User forum mailing list archive at Nabble.com. >>> _______________________________________________ >>> rules-users mailing list >>> rules-users at lists.jboss.org >>> https://lists.jboss.org/mailman/listinfo/rules-users >>> >> >> _______________________________________________ >> rules-users mailing list >> rules-users at lists.jboss.org >> https://lists.jboss.org/mailman/listinfo/rules-users >> > > > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140710/0f1221ee/attachment-0001.html From sumitdhaniya at gmail.com Thu Jul 10 09:43:12 2014 From: sumitdhaniya at gmail.com (sumit dhaniya) Date: Thu, 10 Jul 2014 19:13:12 +0530 Subject: [rules-users] condition on size of list In-Reply-To: References: <1404930003793-4030283.post@n3.nabble.com> Message-ID: It doesn't shows java.util.List in import suggestions On Thu, Jul 10, 2014 at 7:08 PM, Michael Anstis wrote: > Did you import java.util.List (in Project Editor's "Import suggestions" > and then on the editor's "Config" tab)? > > > On 10 July 2014 13:10, sumit dhaniya wrote: > >> listIf I use model classes created in JAVA with some java.util.List it >> identifies them as Collection(superclass of List) and then list options >> like size,first,last doesn't show up. Is there any way I can force these >> objects as type of List. >> >> >> On Wed, Jul 9, 2014 at 11:52 PM, Michael Anstis > > wrote: >> >>> Yes. >>> >>> Create a BRL Condition column and use an expression on the List pattern. >>> >>> Sent on the move >>> On 9 Jul 2014 19:21, "Sumit Dhaniya" wrote: >>> >>>> I know we can check size of list if we write free form drl but is it >>>> possible >>>> to use size of the list as condition in guided decision table? >>>> >>>> >>>> >>>> -- >>>> View this message in context: >>>> http://drools.46999.n3.nabble.com/condition-on-size-of-list-tp4030283.html >>>> Sent from the Drools: User forum mailing list archive at Nabble.com. >>>> _______________________________________________ >>>> rules-users mailing list >>>> rules-users at lists.jboss.org >>>> https://lists.jboss.org/mailman/listinfo/rules-users >>>> >>> >>> _______________________________________________ >>> rules-users mailing list >>> rules-users at lists.jboss.org >>> https://lists.jboss.org/mailman/listinfo/rules-users >>> >> >> >> _______________________________________________ >> rules-users mailing list >> rules-users at lists.jboss.org >> https://lists.jboss.org/mailman/listinfo/rules-users >> > > > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140710/5d1be8aa/attachment.html From michael.anstis at gmail.com Thu Jul 10 09:45:16 2014 From: michael.anstis at gmail.com (Michael Anstis) Date: Thu, 10 Jul 2014 14:45:16 +0100 Subject: [rules-users] condition on size of list In-Reply-To: References: <1404930003793-4030283.post@n3.nabble.com> Message-ID: You need to add it. On 10 July 2014 14:43, sumit dhaniya wrote: > It doesn't shows java.util.List in import suggestions > > > On Thu, Jul 10, 2014 at 7:08 PM, Michael Anstis > wrote: > >> Did you import java.util.List (in Project Editor's "Import suggestions" >> and then on the editor's "Config" tab)? >> >> >> On 10 July 2014 13:10, sumit dhaniya wrote: >> >>> listIf I use model classes created in JAVA with some java.util.List it >>> identifies them as Collection(superclass of List) and then list options >>> like size,first,last doesn't show up. Is there any way I can force these >>> objects as type of List. >>> >>> >>> On Wed, Jul 9, 2014 at 11:52 PM, Michael Anstis < >>> michael.anstis at gmail.com> wrote: >>> >>>> Yes. >>>> >>>> Create a BRL Condition column and use an expression on the List pattern. >>>> >>>> Sent on the move >>>> On 9 Jul 2014 19:21, "Sumit Dhaniya" wrote: >>>> >>>>> I know we can check size of list if we write free form drl but is it >>>>> possible >>>>> to use size of the list as condition in guided decision table? >>>>> >>>>> >>>>> >>>>> -- >>>>> View this message in context: >>>>> http://drools.46999.n3.nabble.com/condition-on-size-of-list-tp4030283.html >>>>> Sent from the Drools: User forum mailing list archive at Nabble.com. >>>>> _______________________________________________ >>>>> rules-users mailing list >>>>> rules-users at lists.jboss.org >>>>> https://lists.jboss.org/mailman/listinfo/rules-users >>>>> >>>> >>>> _______________________________________________ >>>> rules-users mailing list >>>> rules-users at lists.jboss.org >>>> https://lists.jboss.org/mailman/listinfo/rules-users >>>> >>> >>> >>> _______________________________________________ >>> rules-users mailing list >>> rules-users at lists.jboss.org >>> https://lists.jboss.org/mailman/listinfo/rules-users >>> >> >> >> _______________________________________________ >> rules-users mailing list >> rules-users at lists.jboss.org >> https://lists.jboss.org/mailman/listinfo/rules-users >> > > > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140710/249805ba/attachment.html From sumitdhaniya at gmail.com Thu Jul 10 10:11:31 2014 From: sumitdhaniya at gmail.com (sumit dhaniya) Date: Thu, 10 Jul 2014 19:41:31 +0530 Subject: [rules-users] condition on size of list In-Reply-To: References: <1404930003793-4030283.post@n3.nabble.com> Message-ID: First I tried by adding java.util.List, it didn't showed as import type in config of the file. Then I thought it might not pick interfaces so I also imported java.util.ArrayList but still it doesn't shows it. I tried building project but still no luck. On Thu, Jul 10, 2014 at 7:15 PM, Michael Anstis wrote: > You need to add it. > > > On 10 July 2014 14:43, sumit dhaniya wrote: > >> It doesn't shows java.util.List in import suggestions >> >> >> On Thu, Jul 10, 2014 at 7:08 PM, Michael Anstis > > wrote: >> >>> Did you import java.util.List (in Project Editor's "Import suggestions" >>> and then on the editor's "Config" tab)? >>> >>> >>> On 10 July 2014 13:10, sumit dhaniya wrote: >>> >>>> listIf I use model classes created in JAVA with some java.util.List it >>>> identifies them as Collection(superclass of List) and then list options >>>> like size,first,last doesn't show up. Is there any way I can force these >>>> objects as type of List. >>>> >>>> >>>> On Wed, Jul 9, 2014 at 11:52 PM, Michael Anstis < >>>> michael.anstis at gmail.com> wrote: >>>> >>>>> Yes. >>>>> >>>>> Create a BRL Condition column and use an expression on the List >>>>> pattern. >>>>> >>>>> Sent on the move >>>>> On 9 Jul 2014 19:21, "Sumit Dhaniya" wrote: >>>>> >>>>>> I know we can check size of list if we write free form drl but is it >>>>>> possible >>>>>> to use size of the list as condition in guided decision table? >>>>>> >>>>>> >>>>>> >>>>>> -- >>>>>> View this message in context: >>>>>> http://drools.46999.n3.nabble.com/condition-on-size-of-list-tp4030283.html >>>>>> Sent from the Drools: User forum mailing list archive at Nabble.com. >>>>>> _______________________________________________ >>>>>> rules-users mailing list >>>>>> rules-users at lists.jboss.org >>>>>> https://lists.jboss.org/mailman/listinfo/rules-users >>>>>> >>>>> >>>>> _______________________________________________ >>>>> rules-users mailing list >>>>> rules-users at lists.jboss.org >>>>> https://lists.jboss.org/mailman/listinfo/rules-users >>>>> >>>> >>>> >>>> _______________________________________________ >>>> rules-users mailing list >>>> rules-users at lists.jboss.org >>>> https://lists.jboss.org/mailman/listinfo/rules-users >>>> >>> >>> >>> _______________________________________________ >>> rules-users mailing list >>> rules-users at lists.jboss.org >>> https://lists.jboss.org/mailman/listinfo/rules-users >>> >> >> >> _______________________________________________ >> rules-users mailing list >> rules-users at lists.jboss.org >> https://lists.jboss.org/mailman/listinfo/rules-users >> > > > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140710/2f8e5ae1/attachment.html From sumitdhaniya at gmail.com Thu Jul 10 10:23:37 2014 From: sumitdhaniya at gmail.com (sumit dhaniya) Date: Thu, 10 Jul 2014 19:53:37 +0530 Subject: [rules-users] condition on size of list In-Reply-To: References: <1404930003793-4030283.post@n3.nabble.com> Message-ID: I already tried building the project do I need to do something else to get java.util.List get listed in the import suggestions of my file because even when I removed java.lang.Number from the project imports it still shows it in the import suggestion in config of my rule files. On Thu, Jul 10, 2014 at 7:41 PM, sumit dhaniya wrote: > First I tried by adding java.util.List, it didn't showed as import type in > config of the file. > Then I thought it might not pick interfaces so I also > imported java.util.ArrayList but still it doesn't shows it. > > I tried building project but still no luck. > > > On Thu, Jul 10, 2014 at 7:15 PM, Michael Anstis > wrote: > >> You need to add it. >> >> >> On 10 July 2014 14:43, sumit dhaniya wrote: >> >>> It doesn't shows java.util.List in import suggestions >>> >>> >>> On Thu, Jul 10, 2014 at 7:08 PM, Michael Anstis < >>> michael.anstis at gmail.com> wrote: >>> >>>> Did you import java.util.List (in Project Editor's "Import suggestions" >>>> and then on the editor's "Config" tab)? >>>> >>>> >>>> On 10 July 2014 13:10, sumit dhaniya wrote: >>>> >>>>> listIf I use model classes created in JAVA with some java.util.List it >>>>> identifies them as Collection(superclass of List) and then list options >>>>> like size,first,last doesn't show up. Is there any way I can force these >>>>> objects as type of List. >>>>> >>>>> >>>>> On Wed, Jul 9, 2014 at 11:52 PM, Michael Anstis < >>>>> michael.anstis at gmail.com> wrote: >>>>> >>>>>> Yes. >>>>>> >>>>>> Create a BRL Condition column and use an expression on the List >>>>>> pattern. >>>>>> >>>>>> Sent on the move >>>>>> On 9 Jul 2014 19:21, "Sumit Dhaniya" wrote: >>>>>> >>>>>>> I know we can check size of list if we write free form drl but is it >>>>>>> possible >>>>>>> to use size of the list as condition in guided decision table? >>>>>>> >>>>>>> >>>>>>> >>>>>>> -- >>>>>>> View this message in context: >>>>>>> http://drools.46999.n3.nabble.com/condition-on-size-of-list-tp4030283.html >>>>>>> Sent from the Drools: User forum mailing list archive at Nabble.com. >>>>>>> _______________________________________________ >>>>>>> rules-users mailing list >>>>>>> rules-users at lists.jboss.org >>>>>>> https://lists.jboss.org/mailman/listinfo/rules-users >>>>>>> >>>>>> >>>>>> _______________________________________________ >>>>>> rules-users mailing list >>>>>> rules-users at lists.jboss.org >>>>>> https://lists.jboss.org/mailman/listinfo/rules-users >>>>>> >>>>> >>>>> >>>>> _______________________________________________ >>>>> rules-users mailing list >>>>> rules-users at lists.jboss.org >>>>> https://lists.jboss.org/mailman/listinfo/rules-users >>>>> >>>> >>>> >>>> _______________________________________________ >>>> rules-users mailing list >>>> rules-users at lists.jboss.org >>>> https://lists.jboss.org/mailman/listinfo/rules-users >>>> >>> >>> >>> _______________________________________________ >>> rules-users mailing list >>> rules-users at lists.jboss.org >>> https://lists.jboss.org/mailman/listinfo/rules-users >>> >> >> >> _______________________________________________ >> rules-users mailing list >> rules-users at lists.jboss.org >> https://lists.jboss.org/mailman/listinfo/rules-users >> > > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140710/156f0518/attachment-0001.html From kent.anderson at psware.com Thu Jul 10 17:50:48 2014 From: kent.anderson at psware.com (Kent Anderson) Date: Thu, 10 Jul 2014 14:50:48 -0700 Subject: [rules-users] EventFactHandle retained in memory after FactCount reaches 0 for temporal-based rule Message-ID: The following rule produces a memory leak in Drools 6.1.0-SNAPSHOT: (Stream mode) declare MyEvent @role(event) @timestamp(timestamp) end /* If a RAISE is buffered for N seconds, send it out */ rule "forward raise" no-loop duration (3s) when $raise : MyEvent(eventState == EventState.RAISE, $raiseId : eventId) then System.out.println("Forwarding RAISE(" + $raiseId + ")"); delete($raise); end I see the rule fire as expected, printing out the message 3 seconds after the event is added into the session. While the event is waiting, I see a FactCount of 1 in the session. After the rule fires, the fact count goes to 0. However, using JVisualVm, querying the heap dump shows 1 instance of MyEvent, referenced by an EventFactHandle and several other Drools objects. Is this a bug, or is there a better way to write this rule so Drools? internals let go of the object after it is no longer a fact? -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140710/ade14bcc/attachment-0001.html -------------- next part -------------- A non-text attachment was scrubbed... Name: PastedGraphic-1.png Type: image/png Size: 132484 bytes Desc: not available Url : http://lists.jboss.org/pipermail/rules-users/attachments/20140710/ade14bcc/attachment-0002.png -------------- next part -------------- A non-text attachment was scrubbed... Name: PastedGraphic-2.png Type: image/png Size: 157522 bytes Desc: not available Url : http://lists.jboss.org/pipermail/rules-users/attachments/20140710/ade14bcc/attachment-0003.png From kent.anderson at psware.com Thu Jul 10 18:54:56 2014 From: kent.anderson at psware.com (Kent Anderson) Date: Thu, 10 Jul 2014 15:54:56 -0700 Subject: [rules-users] EventFactHandle retained in memory after FactCount reaches 0 for temporal-based rule In-Reply-To: References: Message-ID: <5BD2B8A2-53FE-4319-AB57-48015E9D6A9F@psware.com> Correction: The original post did not include another rule that exists in the stream. The memory leak does not appear unless both rules are active in the stream. declare MyEvent @role(event) @timestamp(timestamp) end /* If a RAISE is buffered for N seconds, send it out */ rule "forward raise" no-loop duration (3s) when $raise : MyEvent(eventState == EventState.RAISE, $raiseId : eventId) then System.out.println("Forwarding RAISE(" + $raiseId + ")"); delete($raise); end /* When CLEAR, and buffered, clear them both out */ rule "forget it ever happened" no-loop when $clear : MyEvent(eventState == EventState.CLEAR, $clearId : eventId) $raise : MyEvent(eventState == EventState.RAISE, eventId == $clearId) then System.out.println("Forgetting RAISE/CLEAR(" + $clearId + ")"); delete($clear); delete($raise); end On Jul 10, 2014, at 2:50 PM, Kent Anderson wrote: > The following rule produces a memory leak in Drools 6.1.0-SNAPSHOT: > > (Stream mode) > > declare MyEvent > @role(event) > @timestamp(timestamp) > end > > /* If a RAISE is buffered for N seconds, send it out */ > rule "forward raise" > no-loop > duration (3s) > when > $raise : MyEvent(eventState == EventState.RAISE, $raiseId : eventId) > then > System.out.println("Forwarding RAISE(" + $raiseId + ")"); > delete($raise); > end > > > I see the rule fire as expected, printing out the message 3 seconds after the event is added into the session. While the event is waiting, I see a FactCount of 1 in the session. After the rule fires, the fact count goes to 0. However, using JVisualVm, querying the heap dump shows 1 instance of MyEvent, referenced by an EventFactHandle and several other Drools objects. > > Is this a bug, or is there a better way to write this rule so Drools? internals let go of the object after it is no longer a fact? > > > > > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140710/910f3c87/attachment.html From sumitdhaniya at gmail.com Fri Jul 11 05:08:24 2014 From: sumitdhaniya at gmail.com (sumit dhaniya) Date: Fri, 11 Jul 2014 14:38:24 +0530 Subject: [rules-users] condition on size of list In-Reply-To: References: <1404930003793-4030283.post@n3.nabble.com> Message-ID: After restarting the server it started showing list in import suggestions but still it doesn't shows size and other list operation on the list's in my object. For eg. class A { List bList = new ArrayList(); } now it shows bList as a variable but it doesn't shows size and related list function instead shows collection functions like contains etc. Can't I use it like both a collection as well as List? On Thu, Jul 10, 2014 at 7:53 PM, sumit dhaniya wrote: > I already tried building the project do I need to do something else to > get java.util.List get listed in the import suggestions of my file because > even when I removed java.lang.Number from the project imports it still > shows it in the import suggestion in config of my rule files. > > > On Thu, Jul 10, 2014 at 7:41 PM, sumit dhaniya > wrote: > >> First I tried by adding java.util.List, it didn't showed as import type >> in config of the file. >> Then I thought it might not pick interfaces so I also >> imported java.util.ArrayList but still it doesn't shows it. >> >> I tried building project but still no luck. >> >> >> On Thu, Jul 10, 2014 at 7:15 PM, Michael Anstis > > wrote: >> >>> You need to add it. >>> >>> >>> On 10 July 2014 14:43, sumit dhaniya wrote: >>> >>>> It doesn't shows java.util.List in import suggestions >>>> >>>> >>>> On Thu, Jul 10, 2014 at 7:08 PM, Michael Anstis < >>>> michael.anstis at gmail.com> wrote: >>>> >>>>> Did you import java.util.List (in Project Editor's "Import >>>>> suggestions" and then on the editor's "Config" tab)? >>>>> >>>>> >>>>> On 10 July 2014 13:10, sumit dhaniya wrote: >>>>> >>>>>> listIf I use model classes created in JAVA with some java.util.List >>>>>> it identifies them as Collection(superclass of List) and then list options >>>>>> like size,first,last doesn't show up. Is there any way I can force these >>>>>> objects as type of List. >>>>>> >>>>>> >>>>>> On Wed, Jul 9, 2014 at 11:52 PM, Michael Anstis < >>>>>> michael.anstis at gmail.com> wrote: >>>>>> >>>>>>> Yes. >>>>>>> >>>>>>> Create a BRL Condition column and use an expression on the List >>>>>>> pattern. >>>>>>> >>>>>>> Sent on the move >>>>>>> On 9 Jul 2014 19:21, "Sumit Dhaniya" wrote: >>>>>>> >>>>>>>> I know we can check size of list if we write free form drl but is >>>>>>>> it possible >>>>>>>> to use size of the list as condition in guided decision table? >>>>>>>> >>>>>>>> >>>>>>>> >>>>>>>> -- >>>>>>>> View this message in context: >>>>>>>> http://drools.46999.n3.nabble.com/condition-on-size-of-list-tp4030283.html >>>>>>>> Sent from the Drools: User forum mailing list archive at Nabble.com. >>>>>>>> _______________________________________________ >>>>>>>> rules-users mailing list >>>>>>>> rules-users at lists.jboss.org >>>>>>>> https://lists.jboss.org/mailman/listinfo/rules-users >>>>>>>> >>>>>>> >>>>>>> _______________________________________________ >>>>>>> rules-users mailing list >>>>>>> rules-users at lists.jboss.org >>>>>>> https://lists.jboss.org/mailman/listinfo/rules-users >>>>>>> >>>>>> >>>>>> >>>>>> _______________________________________________ >>>>>> rules-users mailing list >>>>>> rules-users at lists.jboss.org >>>>>> https://lists.jboss.org/mailman/listinfo/rules-users >>>>>> >>>>> >>>>> >>>>> _______________________________________________ >>>>> rules-users mailing list >>>>> rules-users at lists.jboss.org >>>>> https://lists.jboss.org/mailman/listinfo/rules-users >>>>> >>>> >>>> >>>> _______________________________________________ >>>> rules-users mailing list >>>> rules-users at lists.jboss.org >>>> https://lists.jboss.org/mailman/listinfo/rules-users >>>> >>> >>> >>> _______________________________________________ >>> rules-users mailing list >>> rules-users at lists.jboss.org >>> https://lists.jboss.org/mailman/listinfo/rules-users >>> >> >> > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140711/42670db5/attachment.html From sumitdhaniya at gmail.com Fri Jul 11 07:02:13 2014 From: sumitdhaniya at gmail.com (Sumit Dhaniya) Date: Fri, 11 Jul 2014 04:02:13 -0700 (PDT) Subject: [rules-users] Project Authoring in kie ide Message-ID: <1405076533601-4030298.post@n3.nabble.com> I updated the POJO's which were getting used in rules due to which some of the rules started throwing error and the left hand side panel consisting of Organisational Unit, repository and project was no longer visible. I tried restarting the server and then even deleting and creating a new repository but left hand side panel of project authoring perspective is still not getting displayed. -- View this message in context: http://drools.46999.n3.nabble.com/Project-Authoring-in-kie-ide-tp4030298.html Sent from the Drools: User forum mailing list archive at Nabble.com. From michael.anstis at gmail.com Fri Jul 11 07:09:26 2014 From: michael.anstis at gmail.com (Michael Anstis) Date: Fri, 11 Jul 2014 12:09:26 +0100 Subject: [rules-users] Project Authoring in kie ide In-Reply-To: <1405076533601-4030298.post@n3.nabble.com> References: <1405076533601-4030298.post@n3.nabble.com> Message-ID: You can delete /bin/.niogit/System.git to restore the workbench. I'd be more interested in what "rules started throwing error" means (the workbench is an authoring environment, so I don't see how rules started to throw errors). Also steps to reproduce would be nice to have, otherwise we'll never know what caused it and whether we should fix it. On 11 July 2014 12:02, Sumit Dhaniya wrote: > I updated the POJO's which were getting used in rules due to which some of > the rules started throwing error and the left hand side panel consisting of > Organisational Unit, repository and project was no longer visible. > I tried restarting the server and then even deleting and creating a new > repository but left hand side panel of project authoring perspective is > still not getting displayed. > > > > -- > View this message in context: > http://drools.46999.n3.nabble.com/Project-Authoring-in-kie-ide-tp4030298.html > Sent from the Drools: User forum mailing list archive at Nabble.com. > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140711/04b2bc12/attachment-0001.html From sumitdhaniya at gmail.com Fri Jul 11 07:18:51 2014 From: sumitdhaniya at gmail.com (sumit dhaniya) Date: Fri, 11 Jul 2014 16:48:51 +0530 Subject: [rules-users] Project Authoring in kie ide In-Reply-To: References: <1405076533601-4030298.post@n3.nabble.com> Message-ID: I was checking the logs on apache console and there were errors like can't find a method or field in class. I thought I'll be able to modify the rules after updating the POJO which are in a maven project. On Fri, Jul 11, 2014 at 4:39 PM, Michael Anstis wrote: > You can delete /bin/.niogit/System.git to restore the workbench. > > I'd be more interested in what "rules started throwing error" means (the > workbench is an authoring environment, so I don't see how rules started to > throw errors). > > Also steps to reproduce would be nice to have, otherwise we'll never know > what caused it and whether we should fix it. > > > On 11 July 2014 12:02, Sumit Dhaniya wrote: > >> I updated the POJO's which were getting used in rules due to which some of >> the rules started throwing error and the left hand side panel consisting >> of >> Organisational Unit, repository and project was no longer visible. >> I tried restarting the server and then even deleting and creating a new >> repository but left hand side panel of project authoring perspective is >> still not getting displayed. >> >> >> >> -- >> View this message in context: >> http://drools.46999.n3.nabble.com/Project-Authoring-in-kie-ide-tp4030298.html >> Sent from the Drools: User forum mailing list archive at Nabble.com. >> _______________________________________________ >> rules-users mailing list >> rules-users at lists.jboss.org >> https://lists.jboss.org/mailman/listinfo/rules-users >> > > > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140711/2bddf4fa/attachment.html From shrinath.managuli at aspiresys.com Fri Jul 11 09:32:23 2014 From: shrinath.managuli at aspiresys.com (Shrinath Managuli) Date: Fri, 11 Jul 2014 13:32:23 +0000 Subject: [rules-users] Confusion on choosing Listeners Message-ID: <22cf3916c54c4dd9b176af121f1654ed@HKNPR02MB019.apcprd02.prod.outlook.com> Hi Drools, I'm not completely sure about choosing Listener from which package either from drools-core or kie-api. I do see Listeners are available as below in kie-api and drools-core api. kie-api org.kie.api.event.rule AgendaEventListener.java RuleRuntimeEventListener.java WorkingMemoryEventListener.java kie-api org.kie.api.event.rule.process ProcessEventListener.java drools-core org.drools.core.event AgendaEventListener WorkingMemoryEventListener RuleBaseEventListener KieSession accepts listener from kie-api. In which we can configure drools-core listeners? What Listeners are preferred to use? Please share your thoughts. Thanks, Shrinath. -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140711/85887430/attachment.html From sumitdhaniya at gmail.com Fri Jul 11 10:14:59 2014 From: sumitdhaniya at gmail.com (Sumit Dhaniya) Date: Fri, 11 Jul 2014 07:14:59 -0700 (PDT) Subject: [rules-users] check list size Message-ID: <1405088099538-4030303.post@n3.nabble.com> I have a class which contains some lists, I want to apply rules on size of list and want to use functions like first(), last() but list objects which are in my class are identified as collections and only collection related functions are shown. For eg. class A { java.util.List bList = new ArrayList(); } now it shows bList as collection type and it doesn't shows size and related list function instead shows collection functions like contains etc. Can't I use it like both a collection as well as List? I tried importing java.util.List but it still don't recognize my List objects as List -- View this message in context: http://drools.46999.n3.nabble.com/check-list-size-tp4030303.html Sent from the Drools: User forum mailing list archive at Nabble.com. From sumitdhaniya at gmail.com Fri Jul 11 13:33:48 2014 From: sumitdhaniya at gmail.com (Sumit Dhaniya) Date: Fri, 11 Jul 2014 10:33:48 -0700 (PDT) Subject: [rules-users] Error due to same class name Message-ID: <1405100028684-4030304.post@n3.nabble.com> I've two classes with same name but in different packages. I created several guided rules which use these classes when I validate individual rules they get validated but when I try to Build and Deploy the project it fails cause it try to find a field in another class. Unable to create Field Extractor for 'isPH'Field/method 'isPH' not found for cla ss 'com.****.****.db.user.TmSlot' : [Rule name='ProducerHour'] org.drools.core.RuntimeDroolsException: Field/method 'isPH' not found for class 'com.****.****.db.user.TmSlot' Unable to Analyse Expression isPH == true: [Error: unable to resolve method using strict-mode: com.****.****.db.user.TmSlot.isPH()] [Near : {... isPH == true ....}] -- View this message in context: http://drools.46999.n3.nabble.com/Error-due-to-same-class-name-tp4030304.html Sent from the Drools: User forum mailing list archive at Nabble.com. From michael.anstis at gmail.com Fri Jul 11 13:46:39 2014 From: michael.anstis at gmail.com (Michael Anstis) Date: Fri, 11 Jul 2014 18:46:39 +0100 Subject: [rules-users] Error due to same class name In-Reply-To: <1405100028684-4030304.post@n3.nabble.com> References: <1405100028684-4030304.post@n3.nabble.com> Message-ID: The guided rule editors really, really, I mean really, do not handle multiple classes with the same simple name in different packages at all well. Even if you only use a single class in a single rule (I.e. do not attempt to use x.y.z.MyClass and a.b.c.MyClass) the overall DRL being compiled can lead to issues as you're effectively creating: "import x.y.z.MyClass rule a when MyClass (...) ... end" and "import a.b.c.MyClass rule b when MyClass (...) ... end" I suspect issues to arise with class FQCN resolution in at least one of those rules. If you cannot use different simple names then my advice is to use free-form DRL for these classes; using the FQCN in the rule and exclude the imports (from the "Config" tab). Sent on the move On 11 Jul 2014 18:37, "Sumit Dhaniya" wrote: > I've two classes with same name but in different packages. > I created several guided rules which use these classes when I validate > individual rules they get validated but when I try to Build and Deploy the > project it fails cause it try to find a field in another class. > > Unable to create Field Extractor for 'isPH'Field/method 'isPH' not found > for > cla > ss 'com.****.****.db.user.TmSlot' > : [Rule name='ProducerHour'] > org.drools.core.RuntimeDroolsException: Field/method 'isPH' not found for > class > 'com.****.****.db.user.TmSlot' > > Unable to Analyse Expression isPH == true: > [Error: unable to resolve method using strict-mode: > com.****.****.db.user.TmSlot.isPH()] > [Near : {... isPH == true ....}] > > > > -- > View this message in context: > http://drools.46999.n3.nabble.com/Error-due-to-same-class-name-tp4030304.html > Sent from the Drools: User forum mailing list archive at Nabble.com. > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140711/39871977/attachment.html From sumitdhaniya at gmail.com Fri Jul 11 13:59:20 2014 From: sumitdhaniya at gmail.com (sumit dhaniya) Date: Fri, 11 Jul 2014 23:29:20 +0530 Subject: [rules-users] Error due to same class name In-Reply-To: References: <1405100028684-4030304.post@n3.nabble.com> Message-ID: Thanks Mike On Fri, Jul 11, 2014 at 11:16 PM, Michael Anstis wrote: > The guided rule editors really, really, I mean really, do not handle > multiple classes with the same simple name in different packages at all > well. > > Even if you only use a single class in a single rule (I.e. do not attempt > to use x.y.z.MyClass and a.b.c.MyClass) the overall DRL being compiled can > lead to issues as you're effectively creating: > > "import x.y.z.MyClass > > rule a > when > MyClass (...) > ... > end" > > and > > "import a.b.c.MyClass > > rule b > when > MyClass (...) > ... > end" > > I suspect issues to arise with class FQCN resolution in at least one of > those rules. > > If you cannot use different simple names then my advice is to use > free-form DRL for these classes; using the FQCN in the rule and exclude the > imports (from the "Config" tab). > > Sent on the move > On 11 Jul 2014 18:37, "Sumit Dhaniya" wrote: > >> I've two classes with same name but in different packages. >> I created several guided rules which use these classes when I validate >> individual rules they get validated but when I try to Build and Deploy the >> project it fails cause it try to find a field in another class. >> >> Unable to create Field Extractor for 'isPH'Field/method 'isPH' not found >> for >> cla >> ss 'com.****.****.db.user.TmSlot' >> : [Rule name='ProducerHour'] >> org.drools.core.RuntimeDroolsException: Field/method 'isPH' not found for >> class >> 'com.****.****.db.user.TmSlot' >> >> Unable to Analyse Expression isPH == true: >> [Error: unable to resolve method using strict-mode: >> com.****.****.db.user.TmSlot.isPH()] >> [Near : {... isPH == true ....}] >> >> >> >> -- >> View this message in context: >> http://drools.46999.n3.nabble.com/Error-due-to-same-class-name-tp4030304.html >> Sent from the Drools: User forum mailing list archive at Nabble.com. >> _______________________________________________ >> rules-users mailing list >> rules-users at lists.jboss.org >> https://lists.jboss.org/mailman/listinfo/rules-users >> > > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140711/6ff8368f/attachment-0001.html From kent.anderson at psware.com Fri Jul 11 15:38:09 2014 From: kent.anderson at psware.com (Kent Anderson) Date: Fri, 11 Jul 2014 12:38:09 -0700 Subject: [rules-users] Workaround: EventFactHandle retained in memory after FactCount reaches 0 for temporal-based rule In-Reply-To: <5BD2B8A2-53FE-4319-AB57-48015E9D6A9F@psware.com> References: <5BD2B8A2-53FE-4319-AB57-48015E9D6A9F@psware.com> Message-ID: <749AF81F-EB48-458A-8457-735CA44DD7D6@psware.com> We have found a workaround that eliminates the leftover event (gone from Working Memory, but not from the JVM memory): The rule ?forget it ever happened? (seen below) causes the problem. Re-writing it to remove the check for RAISE in the LHS eliminated the memory leak. Of course, our application requires the check for RAISE, so it can be accomplished by manually querying working memory from the RHS. It?s ugly, but it resolved the issue. query existsRaise($id) $raise : MyEvent( eventState == EventState.RAISE, eventId == $id ) end rule "process clear" no-loop when $clear : MyEvent(eventState == EventState.CLEAR, $clearId : eventId) then QueryResults results = kcontext.getKieRuntime().getQueryResults( "existsRaise", $clearId ); if (results.size() == 0) { System.out.println( "Forwarding CLEAR(" + $clearId + ")" ); } else { System.out.println("Forgetting RAISE/CLEAR(" + $clearId + ")"); for (QueryResultsRow row : results){ MyEvent raise = (MyEvent) row.get ("$raise"); delete(raise); } } delete($clear); end This appears to be a similar situation to https://issues.jboss.org/browse/DROOLS-498. On Jul 10, 2014, at 3:54 PM, Kent Anderson wrote: > Correction: The original post did not include another rule that exists in the stream. The memory leak does not appear unless both rules are active in the stream. > > declare MyEvent > @role(event) > @timestamp(timestamp) > end > > /* If a RAISE is buffered for N seconds, send it out */ > rule "forward raise" > no-loop > duration (3s) > when > $raise : MyEvent(eventState == EventState.RAISE, $raiseId : eventId) > then > System.out.println("Forwarding RAISE(" + $raiseId + ")"); > delete($raise); > end > > /* When CLEAR, and buffered, clear them both out */ > rule "forget it ever happened" > no-loop > when > $clear : MyEvent(eventState == EventState.CLEAR, $clearId : eventId) > $raise : MyEvent(eventState == EventState.RAISE, eventId == $clearId) > then > System.out.println("Forgetting RAISE/CLEAR(" + $clearId + ")"); > delete($clear); > delete($raise); > end > > > On Jul 10, 2014, at 2:50 PM, Kent Anderson wrote: > >> The following rule produces a memory leak in Drools 6.1.0-SNAPSHOT: >> >> (Stream mode) >> >> declare MyEvent >> @role(event) >> @timestamp(timestamp) >> end >> >> /* If a RAISE is buffered for N seconds, send it out */ >> rule "forward raise" >> no-loop >> duration (3s) >> when >> $raise : MyEvent(eventState == EventState.RAISE, $raiseId : eventId) >> then >> System.out.println("Forwarding RAISE(" + $raiseId + ")"); >> delete($raise); >> end >> >> >> I see the rule fire as expected, printing out the message 3 seconds after the event is added into the session. While the event is waiting, I see a FactCount of 1 in the session. After the rule fires, the fact count goes to 0. However, using JVisualVm, querying the heap dump shows 1 instance of MyEvent, referenced by an EventFactHandle and several other Drools objects. >> >> Is this a bug, or is there a better way to write this rule so Drools? internals let go of the object after it is no longer a fact? >> >> >> >> >> _______________________________________________ >> rules-users mailing list >> rules-users at lists.jboss.org >> https://lists.jboss.org/mailman/listinfo/rules-users > > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140711/48c10bb7/attachment.html From sumitdhaniya at gmail.com Fri Jul 11 16:23:12 2014 From: sumitdhaniya at gmail.com (Sumit Dhaniya) Date: Fri, 11 Jul 2014 13:23:12 -0700 (PDT) Subject: [rules-users] conditions getting removed from Guided Rule Message-ID: <1405110192572-4030308.post@n3.nabble.com> I'm creating a rule in which I'm comparing properties of two objects. All works well I'm able to compare their properties and rule gets validated as well and then I close the rule, but when I open the rule again properties of second object in condition don't show up in guided editor however they are present if I check the source of the guided rule. Moreover it also doesn't allows me to use _id variable which is present in my class whereas there is no issue if I use any other variable name id this due to "_"? -- View this message in context: http://drools.46999.n3.nabble.com/conditions-getting-removed-from-Guided-Rule-tp4030308.html Sent from the Drools: User forum mailing list archive at Nabble.com. From michael.anstis at gmail.com Fri Jul 11 16:31:08 2014 From: michael.anstis at gmail.com (Michael Anstis) Date: Fri, 11 Jul 2014 21:31:08 +0100 Subject: [rules-users] conditions getting removed from Guided Rule In-Reply-To: <1405110192572-4030308.post@n3.nabble.com> References: <1405110192572-4030308.post@n3.nabble.com> Message-ID: What version? Have you tried 6.1.CR2 there were lots of improvements in this area. The issue is guided rules are stored as DRL and we need to reverse engineer the model used by the UI from the DRL. Failing that we'll need your DRL so we can fix whatever issue exists in your scenario. Thanks Sent on the move On 11 Jul 2014 21:27, "Sumit Dhaniya" wrote: > I'm creating a rule in which I'm comparing properties of two objects. All > works well I'm able to compare their properties and rule gets validated as > well and then I close the rule, but when I open the rule again properties > of > second object in condition don't show up in guided editor however they are > present if I check the source of the guided rule. > Moreover it also doesn't allows me to use _id variable which is present in > my class whereas there is no issue if I use any other variable name id this > due to "_"? > > > > -- > View this message in context: > http://drools.46999.n3.nabble.com/conditions-getting-removed-from-Guided-Rule-tp4030308.html > Sent from the Drools: User forum mailing list archive at Nabble.com. > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140711/cfe368e7/attachment.html From sumitdhaniya at gmail.com Fri Jul 11 16:43:38 2014 From: sumitdhaniya at gmail.com (sumit dhaniya) Date: Sat, 12 Jul 2014 02:13:38 +0530 Subject: [rules-users] conditions getting removed from Guided Rule In-Reply-To: References: <1405110192572-4030308.post@n3.nabble.com> Message-ID: Thanks Mike I'll try with 6.1 and if issue still comes I'll share the drl. Can you please also confirm if I can use variables whose names start with "_" cause it seems it doesn't allows me to use _id On Sat, Jul 12, 2014 at 2:01 AM, Michael Anstis wrote: > What version? > > Have you tried 6.1.CR2 there were lots of improvements in this area. > > The issue is guided rules are stored as DRL and we need to reverse > engineer the model used by the UI from the DRL. > > Failing that we'll need your DRL so we can fix whatever issue exists in > your scenario. > > Thanks > > Sent on the move > On 11 Jul 2014 21:27, "Sumit Dhaniya" wrote: > >> I'm creating a rule in which I'm comparing properties of two objects. All >> works well I'm able to compare their properties and rule gets validated as >> well and then I close the rule, but when I open the rule again properties >> of >> second object in condition don't show up in guided editor however they are >> present if I check the source of the guided rule. >> Moreover it also doesn't allows me to use _id variable which is present in >> my class whereas there is no issue if I use any other variable name id >> this >> due to "_"? >> >> >> >> -- >> View this message in context: >> http://drools.46999.n3.nabble.com/conditions-getting-removed-from-Guided-Rule-tp4030308.html >> Sent from the Drools: User forum mailing list archive at Nabble.com. >> _______________________________________________ >> rules-users mailing list >> rules-users at lists.jboss.org >> https://lists.jboss.org/mailman/listinfo/rules-users >> > > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140712/82b56259/attachment-0001.html From michael.anstis at gmail.com Fri Jul 11 17:00:02 2014 From: michael.anstis at gmail.com (Michael Anstis) Date: Fri, 11 Jul 2014 22:00:02 +0100 Subject: [rules-users] conditions getting removed from Guided Rule In-Reply-To: References: <1405110192572-4030308.post@n3.nabble.com> Message-ID: When you say "it doesn't allow me to use" can you be a little more descriptive? Does the UI prevent it (I am thinking this is the case) or does the DRL generate errors? Sent on the move On 11 Jul 2014 21:44, "sumit dhaniya" wrote: > Thanks Mike I'll try with 6.1 and if issue still comes I'll share the drl. > > Can you please also confirm if I can use variables whose names start with > "_" cause it seems it doesn't allows me to use _id > > > On Sat, Jul 12, 2014 at 2:01 AM, Michael Anstis > wrote: > >> What version? >> >> Have you tried 6.1.CR2 there were lots of improvements in this area. >> >> The issue is guided rules are stored as DRL and we need to reverse >> engineer the model used by the UI from the DRL. >> >> Failing that we'll need your DRL so we can fix whatever issue exists in >> your scenario. >> >> Thanks >> >> Sent on the move >> On 11 Jul 2014 21:27, "Sumit Dhaniya" wrote: >> >>> I'm creating a rule in which I'm comparing properties of two objects. All >>> works well I'm able to compare their properties and rule gets validated >>> as >>> well and then I close the rule, but when I open the rule again >>> properties of >>> second object in condition don't show up in guided editor however they >>> are >>> present if I check the source of the guided rule. >>> Moreover it also doesn't allows me to use _id variable which is present >>> in >>> my class whereas there is no issue if I use any other variable name id >>> this >>> due to "_"? >>> >>> >>> >>> -- >>> View this message in context: >>> http://drools.46999.n3.nabble.com/conditions-getting-removed-from-Guided-Rule-tp4030308.html >>> Sent from the Drools: User forum mailing list archive at Nabble.com. >>> _______________________________________________ >>> rules-users mailing list >>> rules-users at lists.jboss.org >>> https://lists.jboss.org/mailman/listinfo/rules-users >>> >> >> _______________________________________________ >> rules-users mailing list >> rules-users at lists.jboss.org >> https://lists.jboss.org/mailman/listinfo/rules-users >> > > > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140711/99c2050e/attachment.html From sumitdhaniya at gmail.com Fri Jul 11 17:12:49 2014 From: sumitdhaniya at gmail.com (sumit dhaniya) Date: Sat, 12 Jul 2014 02:42:49 +0530 Subject: [rules-users] conditions getting removed from Guided Rule In-Reply-To: References: <1405110192572-4030308.post@n3.nabble.com> Message-ID: I can create rule by selecting the field from fields dropdown but when I try to validate it throws error given below :- 2014-07-12 02:36:24,203 [http-bio-8080-exec-3] ERROR Unable to build KieBaseMode l:defaultKieBase Unable to Analyse Expression _id == $searchContext.lastThreeProducerId: [Error: no such identifier: _id] [Near : {... _id == $searchContext.lastThre ....}] ^ : [Rule name='EateryRepeatUsage'] data type of _id is string and same rule gets successfully validated if I use any other variable of string type. On Sat, Jul 12, 2014 at 2:30 AM, Michael Anstis wrote: > When you say "it doesn't allow me to use" can you be a little more > descriptive? Does the UI prevent it (I am thinking this is the case) or > does the DRL generate errors? > > Sent on the move > On 11 Jul 2014 21:44, "sumit dhaniya" wrote: > >> Thanks Mike I'll try with 6.1 and if issue still comes I'll share the drl. >> >> Can you please also confirm if I can use variables whose names start with >> "_" cause it seems it doesn't allows me to use _id >> >> >> On Sat, Jul 12, 2014 at 2:01 AM, Michael Anstis > > wrote: >> >>> What version? >>> >>> Have you tried 6.1.CR2 there were lots of improvements in this area. >>> >>> The issue is guided rules are stored as DRL and we need to reverse >>> engineer the model used by the UI from the DRL. >>> >>> Failing that we'll need your DRL so we can fix whatever issue exists in >>> your scenario. >>> >>> Thanks >>> >>> Sent on the move >>> On 11 Jul 2014 21:27, "Sumit Dhaniya" wrote: >>> >>>> I'm creating a rule in which I'm comparing properties of two objects. >>>> All >>>> works well I'm able to compare their properties and rule gets validated >>>> as >>>> well and then I close the rule, but when I open the rule again >>>> properties of >>>> second object in condition don't show up in guided editor however they >>>> are >>>> present if I check the source of the guided rule. >>>> Moreover it also doesn't allows me to use _id variable which is present >>>> in >>>> my class whereas there is no issue if I use any other variable name id >>>> this >>>> due to "_"? >>>> >>>> >>>> >>>> -- >>>> View this message in context: >>>> http://drools.46999.n3.nabble.com/conditions-getting-removed-from-Guided-Rule-tp4030308.html >>>> Sent from the Drools: User forum mailing list archive at Nabble.com. >>>> _______________________________________________ >>>> rules-users mailing list >>>> rules-users at lists.jboss.org >>>> https://lists.jboss.org/mailman/listinfo/rules-users >>>> >>> >>> _______________________________________________ >>> rules-users mailing list >>> rules-users at lists.jboss.org >>> https://lists.jboss.org/mailman/listinfo/rules-users >>> >> >> >> _______________________________________________ >> rules-users mailing list >> rules-users at lists.jboss.org >> https://lists.jboss.org/mailman/listinfo/rules-users >> > > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140712/ce4509ee/attachment.html From michael.anstis at gmail.com Fri Jul 11 17:21:42 2014 From: michael.anstis at gmail.com (Michael Anstis) Date: Fri, 11 Jul 2014 22:21:42 +0100 Subject: [rules-users] conditions getting removed from Guided Rule In-Reply-To: References: <1405110192572-4030308.post@n3.nabble.com> Message-ID: I don't have access to the code here, but it sounds like _ prefixes are invalid, which means we have a potential bug. Where/how did you manage to set _id binding? Sent on the move On 11 Jul 2014 22:13, "sumit dhaniya" wrote: > I can create rule by selecting the field from fields dropdown but when I > try to validate it throws error given below :- > > 2014-07-12 02:36:24,203 [http-bio-8080-exec-3] ERROR Unable to build > KieBaseMode > l:defaultKieBase > Unable to Analyse Expression _id == $searchContext.lastThreeProducerId: > [Error: no such identifier: _id] > [Near : {... _id == $searchContext.lastThre ....}] > ^ : [Rule name='EateryRepeatUsage'] > > data type of _id is string and same rule gets successfully validated if I > use any other variable of string type. > > > On Sat, Jul 12, 2014 at 2:30 AM, Michael Anstis > wrote: > >> When you say "it doesn't allow me to use" can you be a little more >> descriptive? Does the UI prevent it (I am thinking this is the case) or >> does the DRL generate errors? >> >> Sent on the move >> On 11 Jul 2014 21:44, "sumit dhaniya" wrote: >> >>> Thanks Mike I'll try with 6.1 and if issue still comes I'll share the >>> drl. >>> >>> Can you please also confirm if I can use variables whose names start >>> with "_" cause it seems it doesn't allows me to use _id >>> >>> >>> On Sat, Jul 12, 2014 at 2:01 AM, Michael Anstis < >>> michael.anstis at gmail.com> wrote: >>> >>>> What version? >>>> >>>> Have you tried 6.1.CR2 there were lots of improvements in this area. >>>> >>>> The issue is guided rules are stored as DRL and we need to reverse >>>> engineer the model used by the UI from the DRL. >>>> >>>> Failing that we'll need your DRL so we can fix whatever issue exists in >>>> your scenario. >>>> >>>> Thanks >>>> >>>> Sent on the move >>>> On 11 Jul 2014 21:27, "Sumit Dhaniya" wrote: >>>> >>>>> I'm creating a rule in which I'm comparing properties of two objects. >>>>> All >>>>> works well I'm able to compare their properties and rule gets >>>>> validated as >>>>> well and then I close the rule, but when I open the rule again >>>>> properties of >>>>> second object in condition don't show up in guided editor however they >>>>> are >>>>> present if I check the source of the guided rule. >>>>> Moreover it also doesn't allows me to use _id variable which is >>>>> present in >>>>> my class whereas there is no issue if I use any other variable name id >>>>> this >>>>> due to "_"? >>>>> >>>>> >>>>> >>>>> -- >>>>> View this message in context: >>>>> http://drools.46999.n3.nabble.com/conditions-getting-removed-from-Guided-Rule-tp4030308.html >>>>> Sent from the Drools: User forum mailing list archive at Nabble.com. >>>>> _______________________________________________ >>>>> rules-users mailing list >>>>> rules-users at lists.jboss.org >>>>> https://lists.jboss.org/mailman/listinfo/rules-users >>>>> >>>> >>>> _______________________________________________ >>>> rules-users mailing list >>>> rules-users at lists.jboss.org >>>> https://lists.jboss.org/mailman/listinfo/rules-users >>>> >>> >>> >>> _______________________________________________ >>> rules-users mailing list >>> rules-users at lists.jboss.org >>> https://lists.jboss.org/mailman/listinfo/rules-users >>> >> >> _______________________________________________ >> rules-users mailing list >> rules-users at lists.jboss.org >> https://lists.jboss.org/mailman/listinfo/rules-users >> > > > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140711/b3865fb3/attachment-0001.html From sumitdhaniya at gmail.com Sat Jul 12 02:39:58 2014 From: sumitdhaniya at gmail.com (sumit dhaniya) Date: Sat, 12 Jul 2014 12:09:58 +0530 Subject: [rules-users] conditions getting removed from Guided Rule In-Reply-To: References: <1405110192572-4030308.post@n3.nabble.com> Message-ID: added a maven project as dependency in my project which contains mode pojo -> Create a guided rule -> In config of guided rule add the class which contains _id variable -> add a condition to the rule (the class object which contains _id) -> apply restriction on the fields (_id will be listed as one of the options to apply restriction on) On Sat, Jul 12, 2014 at 2:51 AM, Michael Anstis wrote: > I don't have access to the code here, but it sounds like _ prefixes are > invalid, which means we have a potential bug. > > Where/how did you manage to set _id binding? > > Sent on the move > On 11 Jul 2014 22:13, "sumit dhaniya" wrote: > >> I can create rule by selecting the field from fields dropdown but when I >> try to validate it throws error given below :- >> >> 2014-07-12 02:36:24,203 [http-bio-8080-exec-3] ERROR Unable to build >> KieBaseMode >> l:defaultKieBase >> Unable to Analyse Expression _id == $searchContext.lastThreeProducerId: >> [Error: no such identifier: _id] >> [Near : {... _id == $searchContext.lastThre ....}] >> ^ : [Rule name='EateryRepeatUsage'] >> >> data type of _id is string and same rule gets successfully validated if I >> use any other variable of string type. >> >> >> On Sat, Jul 12, 2014 at 2:30 AM, Michael Anstis > > wrote: >> >>> When you say "it doesn't allow me to use" can you be a little more >>> descriptive? Does the UI prevent it (I am thinking this is the case) or >>> does the DRL generate errors? >>> >>> Sent on the move >>> On 11 Jul 2014 21:44, "sumit dhaniya" wrote: >>> >>>> Thanks Mike I'll try with 6.1 and if issue still comes I'll share the >>>> drl. >>>> >>>> Can you please also confirm if I can use variables whose names start >>>> with "_" cause it seems it doesn't allows me to use _id >>>> >>>> >>>> On Sat, Jul 12, 2014 at 2:01 AM, Michael Anstis < >>>> michael.anstis at gmail.com> wrote: >>>> >>>>> What version? >>>>> >>>>> Have you tried 6.1.CR2 there were lots of improvements in this area. >>>>> >>>>> The issue is guided rules are stored as DRL and we need to reverse >>>>> engineer the model used by the UI from the DRL. >>>>> >>>>> Failing that we'll need your DRL so we can fix whatever issue exists >>>>> in your scenario. >>>>> >>>>> Thanks >>>>> >>>>> Sent on the move >>>>> On 11 Jul 2014 21:27, "Sumit Dhaniya" wrote: >>>>> >>>>>> I'm creating a rule in which I'm comparing properties of two objects. >>>>>> All >>>>>> works well I'm able to compare their properties and rule gets >>>>>> validated as >>>>>> well and then I close the rule, but when I open the rule again >>>>>> properties of >>>>>> second object in condition don't show up in guided editor however >>>>>> they are >>>>>> present if I check the source of the guided rule. >>>>>> Moreover it also doesn't allows me to use _id variable which is >>>>>> present in >>>>>> my class whereas there is no issue if I use any other variable name >>>>>> id this >>>>>> due to "_"? >>>>>> >>>>>> >>>>>> >>>>>> -- >>>>>> View this message in context: >>>>>> http://drools.46999.n3.nabble.com/conditions-getting-removed-from-Guided-Rule-tp4030308.html >>>>>> Sent from the Drools: User forum mailing list archive at Nabble.com. >>>>>> _______________________________________________ >>>>>> rules-users mailing list >>>>>> rules-users at lists.jboss.org >>>>>> https://lists.jboss.org/mailman/listinfo/rules-users >>>>>> >>>>> >>>>> _______________________________________________ >>>>> rules-users mailing list >>>>> rules-users at lists.jboss.org >>>>> https://lists.jboss.org/mailman/listinfo/rules-users >>>>> >>>> >>>> >>>> _______________________________________________ >>>> rules-users mailing list >>>> rules-users at lists.jboss.org >>>> https://lists.jboss.org/mailman/listinfo/rules-users >>>> >>> >>> _______________________________________________ >>> rules-users mailing list >>> rules-users at lists.jboss.org >>> https://lists.jboss.org/mailman/listinfo/rules-users >>> >> >> >> _______________________________________________ >> rules-users mailing list >> rules-users at lists.jboss.org >> https://lists.jboss.org/mailman/listinfo/rules-users >> > > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140712/978a5ea1/attachment.html From sumitdhaniya at gmail.com Sat Jul 12 02:40:58 2014 From: sumitdhaniya at gmail.com (sumit dhaniya) Date: Sat, 12 Jul 2014 12:10:58 +0530 Subject: [rules-users] conditions getting removed from Guided Rule In-Reply-To: References: <1405110192572-4030308.post@n3.nabble.com> Message-ID: Hi Michael can you confirm the download link for 6.1.CR2 http://downloads.jboss.org/drools/release/snapshot/6.1.x/kie-drools-wb-6.1.0-SNAPSHOT-tomcat7.0.war On Sat, Jul 12, 2014 at 12:09 PM, sumit dhaniya wrote: > added a maven project as dependency in my project which contains mode pojo > -> Create a guided rule -> In config of guided rule add the class which > contains _id variable -> add a condition to the rule (the class object > which contains _id) -> apply restriction on the fields (_id will be listed > as one of the options to apply restriction on) > > > On Sat, Jul 12, 2014 at 2:51 AM, Michael Anstis > wrote: > >> I don't have access to the code here, but it sounds like _ prefixes are >> invalid, which means we have a potential bug. >> >> Where/how did you manage to set _id binding? >> >> Sent on the move >> On 11 Jul 2014 22:13, "sumit dhaniya" wrote: >> >>> I can create rule by selecting the field from fields dropdown but when I >>> try to validate it throws error given below :- >>> >>> 2014-07-12 02:36:24,203 [http-bio-8080-exec-3] ERROR Unable to build >>> KieBaseMode >>> l:defaultKieBase >>> Unable to Analyse Expression _id == $searchContext.lastThreeProducerId: >>> [Error: no such identifier: _id] >>> [Near : {... _id == $searchContext.lastThre ....}] >>> ^ : [Rule name='EateryRepeatUsage'] >>> >>> data type of _id is string and same rule gets successfully validated if >>> I use any other variable of string type. >>> >>> >>> On Sat, Jul 12, 2014 at 2:30 AM, Michael Anstis < >>> michael.anstis at gmail.com> wrote: >>> >>>> When you say "it doesn't allow me to use" can you be a little more >>>> descriptive? Does the UI prevent it (I am thinking this is the case) or >>>> does the DRL generate errors? >>>> >>>> Sent on the move >>>> On 11 Jul 2014 21:44, "sumit dhaniya" wrote: >>>> >>>>> Thanks Mike I'll try with 6.1 and if issue still comes I'll share the >>>>> drl. >>>>> >>>>> Can you please also confirm if I can use variables whose names start >>>>> with "_" cause it seems it doesn't allows me to use _id >>>>> >>>>> >>>>> On Sat, Jul 12, 2014 at 2:01 AM, Michael Anstis < >>>>> michael.anstis at gmail.com> wrote: >>>>> >>>>>> What version? >>>>>> >>>>>> Have you tried 6.1.CR2 there were lots of improvements in this area. >>>>>> >>>>>> The issue is guided rules are stored as DRL and we need to reverse >>>>>> engineer the model used by the UI from the DRL. >>>>>> >>>>>> Failing that we'll need your DRL so we can fix whatever issue exists >>>>>> in your scenario. >>>>>> >>>>>> Thanks >>>>>> >>>>>> Sent on the move >>>>>> On 11 Jul 2014 21:27, "Sumit Dhaniya" wrote: >>>>>> >>>>>>> I'm creating a rule in which I'm comparing properties of two >>>>>>> objects. All >>>>>>> works well I'm able to compare their properties and rule gets >>>>>>> validated as >>>>>>> well and then I close the rule, but when I open the rule again >>>>>>> properties of >>>>>>> second object in condition don't show up in guided editor however >>>>>>> they are >>>>>>> present if I check the source of the guided rule. >>>>>>> Moreover it also doesn't allows me to use _id variable which is >>>>>>> present in >>>>>>> my class whereas there is no issue if I use any other variable name >>>>>>> id this >>>>>>> due to "_"? >>>>>>> >>>>>>> >>>>>>> >>>>>>> -- >>>>>>> View this message in context: >>>>>>> http://drools.46999.n3.nabble.com/conditions-getting-removed-from-Guided-Rule-tp4030308.html >>>>>>> Sent from the Drools: User forum mailing list archive at Nabble.com. >>>>>>> _______________________________________________ >>>>>>> rules-users mailing list >>>>>>> rules-users at lists.jboss.org >>>>>>> https://lists.jboss.org/mailman/listinfo/rules-users >>>>>>> >>>>>> >>>>>> _______________________________________________ >>>>>> rules-users mailing list >>>>>> rules-users at lists.jboss.org >>>>>> https://lists.jboss.org/mailman/listinfo/rules-users >>>>>> >>>>> >>>>> >>>>> _______________________________________________ >>>>> rules-users mailing list >>>>> rules-users at lists.jboss.org >>>>> https://lists.jboss.org/mailman/listinfo/rules-users >>>>> >>>> >>>> _______________________________________________ >>>> rules-users mailing list >>>> rules-users at lists.jboss.org >>>> https://lists.jboss.org/mailman/listinfo/rules-users >>>> >>> >>> >>> _______________________________________________ >>> rules-users mailing list >>> rules-users at lists.jboss.org >>> https://lists.jboss.org/mailman/listinfo/rules-users >>> >> >> _______________________________________________ >> rules-users mailing list >> rules-users at lists.jboss.org >> https://lists.jboss.org/mailman/listinfo/rules-users >> > > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140712/e0488986/attachment.html From mario.fusco at gmail.com Sat Jul 12 04:05:49 2014 From: mario.fusco at gmail.com (Mario Fusco) Date: Sat, 12 Jul 2014 01:05:49 -0700 (PDT) Subject: [rules-users] conditions getting removed from Guided Rule In-Reply-To: References: <1405110192572-4030308.post@n3.nabble.com> Message-ID: <1405152349814-4030318.post@n3.nabble.com> Hi, This seems more a problem of the drools compiler. I'll try to reproduce it and check what happens. Just one more question: is the field public or is it accessed through a getter method in your Java class? In case you're using a getter did you named it get_id or get_Id ? Thanks, Mario -- View this message in context: http://drools.46999.n3.nabble.com/conditions-getting-removed-from-Guided-Rule-tp4030308p4030318.html Sent from the Drools: User forum mailing list archive at Nabble.com. From sumitdhaniya at gmail.com Sat Jul 12 04:24:41 2014 From: sumitdhaniya at gmail.com (sumit dhaniya) Date: Sat, 12 Jul 2014 13:54:41 +0530 Subject: [rules-users] conditions getting removed from Guided Rule In-Reply-To: <1405152349814-4030318.post@n3.nabble.com> References: <1405110192572-4030308.post@n3.nabble.com> <1405152349814-4030318.post@n3.nabble.com> Message-ID: field is private and below are getter and setter :- private String _id; public String get_id() { return _id; } public void set_id(String _id) { this._id = _id; } On Sat, Jul 12, 2014 at 1:35 PM, Mario Fusco wrote: > Hi, > > This seems more a problem of the drools compiler. I'll try to reproduce it > and check what happens. Just one more question: is the field public or is > it > accessed through a getter method in your Java class? In case you're using a > getter did you named it get_id or get_Id ? > > Thanks, > Mario > > > > -- > View this message in context: > http://drools.46999.n3.nabble.com/conditions-getting-removed-from-Guided-Rule-tp4030308p4030318.html > Sent from the Drools: User forum mailing list archive at Nabble.com. > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140712/23c3d90c/attachment.html From sumitdhaniya at gmail.com Sat Jul 12 04:27:48 2014 From: sumitdhaniya at gmail.com (sumit dhaniya) Date: Sat, 12 Jul 2014 13:57:48 +0530 Subject: [rules-users] conditions getting removed from Guided Rule In-Reply-To: References: <1405110192572-4030308.post@n3.nabble.com> <1405152349814-4030318.post@n3.nabble.com> Message-ID: Can you please provide me the link to download 6.1.CR2 tomcat war On Sat, Jul 12, 2014 at 1:54 PM, sumit dhaniya wrote: > field is private and below are getter and setter :- > > private String _id; > > public String get_id() { > return _id; > } > > public void set_id(String _id) { > this._id = _id; > } > > > > > On Sat, Jul 12, 2014 at 1:35 PM, Mario Fusco > wrote: > >> Hi, >> >> This seems more a problem of the drools compiler. I'll try to reproduce it >> and check what happens. Just one more question: is the field public or is >> it >> accessed through a getter method in your Java class? In case you're using >> a >> getter did you named it get_id or get_Id ? >> >> Thanks, >> Mario >> >> >> >> -- >> View this message in context: >> http://drools.46999.n3.nabble.com/conditions-getting-removed-from-Guided-Rule-tp4030308p4030318.html >> Sent from the Drools: User forum mailing list archive at Nabble.com. >> _______________________________________________ >> rules-users mailing list >> rules-users at lists.jboss.org >> https://lists.jboss.org/mailman/listinfo/rules-users >> > > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140712/fa97e392/attachment.html From sumitdhaniya at gmail.com Sat Jul 12 05:04:04 2014 From: sumitdhaniya at gmail.com (Sumit Dhaniya) Date: Sat, 12 Jul 2014 02:04:04 -0700 (PDT) Subject: [rules-users] kie-wb 6.1.CR2 Message-ID: <1405155844506-4030321.post@n3.nabble.com> Is there any link from where I can download kie-wb6.1.CR2 or I'll have to clone the project and create war. I tried the nightly build but unfortunately it doesn't works. When I deploy it in tomcat 7 I can't access index page. -- View this message in context: http://drools.46999.n3.nabble.com/kie-wb-6-1-CR2-tp4030321.html Sent from the Drools: User forum mailing list archive at Nabble.com. From sumitdhaniya at gmail.com Sat Jul 12 05:53:28 2014 From: sumitdhaniya at gmail.com (Sumit Dhaniya) Date: Sat, 12 Jul 2014 02:53:28 -0700 (PDT) Subject: [rules-users] conditions getting removed from Guided Rule In-Reply-To: References: <1405110192572-4030308.post@n3.nabble.com> Message-ID: <1405158808834-4030322.post@n3.nabble.com> I create the rule by comparing properties of two objects as shown in image attached. Till I don't close the window generated source looks fine but when I open this rule after closing it. But when I open the rule next time it removes the highlighted condition from the rule and also removes them from drl. Just wondering is there anything I'm doing wrong or issue is something else. -- View this message in context: http://drools.46999.n3.nabble.com/conditions-getting-removed-from-Guided-Rule-tp4030308p4030322.html Sent from the Drools: User forum mailing list archive at Nabble.com. From michael.anstis at gmail.com Sat Jul 12 06:10:48 2014 From: michael.anstis at gmail.com (Michael Anstis) Date: Sat, 12 Jul 2014 11:10:48 +0100 Subject: [rules-users] conditions getting removed from Guided Rule In-Reply-To: <1405158808834-4030322.post@n3.nabble.com> References: <1405110192572-4030308.post@n3.nabble.com> <1405158808834-4030322.post@n3.nabble.com> Message-ID: Asking (at least) three questions at the same time on the same thread is really going to annoy people. It's the weekend; most people are not working and you are not paying for our support. When I am at my computer on Monday I will be happy to answer more. For now; please provide the DRL for the rule that does not reopen correctly and your object model. Sent on the move On 12 Jul 2014 10:54, "Sumit Dhaniya" wrote: > I create the rule by comparing properties of two objects as shown in image > attached. Till I don't close the window generated source looks fine but > when > I open this rule after closing it. > But when I open the rule next time it removes the highlighted condition > from > the rule and also removes them from drl. Just wondering is there anything > I'm doing wrong or issue is something else. > > > > > -- > View this message in context: > http://drools.46999.n3.nabble.com/conditions-getting-removed-from-Guided-Rule-tp4030308p4030322.html > Sent from the Drools: User forum mailing list archive at Nabble.com. > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140712/0f43b0bc/attachment.html From sumitdhaniya at gmail.com Sat Jul 12 07:17:37 2014 From: sumitdhaniya at gmail.com (sumit dhaniya) Date: Sat, 12 Jul 2014 16:47:37 +0530 Subject: [rules-users] conditions getting removed from Guided Rule In-Reply-To: References: <1405110192572-4030308.post@n3.nabble.com> <1405158808834-4030322.post@n3.nabble.com> Message-ID: Michael I really appreciate all the help from the forum and the time invested by the people to answer the queries. I'm working as a freelance developer so if support is something affordable then please let me know. DRL :- 2.|3.|import java.lang.Number;4.|import com.sophic.foodeemee.offers.dto.SearchContext;5.|import com.sophic.foodeemee.offers.dto.ProducerMasterForRules;6.|import com.sophic.foodeemee.offers.dto.RuleFactor;7.|8.|rule "SecondaryCuisineRepeatUsage"9.| dialect "mvel"10.| when11.| $searchContext : SearchContext( lastThreeCuisines != null )12.| ProducerMasterForRules( primaryCuisine != null , primaryCuisine != $searchContext.lastThreeCuisines , secondaryCuisine != null , secondaryCuisine == $searchContext.lastThreeCuisines )13.| $secondaryCuisineRepeatUsageFactor : RuleFactor( )14.| then15.| $secondaryCuisineRepeatUsageFactor.setWeightageImpact( -30 );16.| update( $secondaryCuisineRepeatUsageFactor );17.|end object models are attached. On Sat, Jul 12, 2014 at 3:40 PM, Michael Anstis wrote: > Asking (at least) three questions at the same time on the same thread is > really going to annoy people. > > It's the weekend; most people are not working and you are not paying for > our support. > > When I am at my computer on Monday I will be happy to answer more. For > now; please provide the DRL for the rule that does not reopen correctly and > your object model. > > Sent on the move > On 12 Jul 2014 10:54, "Sumit Dhaniya" wrote: > >> I create the rule by comparing properties of two objects as shown in image >> attached. Till I don't close the window generated source looks fine but >> when >> I open this rule after closing it. >> But when I open the rule next time it removes the highlighted condition >> from >> the rule and also removes them from drl. Just wondering is there anything >> I'm doing wrong or issue is something else. >> >> >> >> >> -- >> View this message in context: >> http://drools.46999.n3.nabble.com/conditions-getting-removed-from-Guided-Rule-tp4030308p4030322.html >> Sent from the Drools: User forum mailing list archive at Nabble.com. >> _______________________________________________ >> rules-users mailing list >> rules-users at lists.jboss.org >> https://lists.jboss.org/mailman/listinfo/rules-users >> > > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140712/80dd6cf6/attachment-0001.html -------------- next part -------------- A non-text attachment was scrubbed... Name: SearchContext.java Type: application/octet-stream Size: 2873 bytes Desc: not available Url : http://lists.jboss.org/pipermail/rules-users/attachments/20140712/80dd6cf6/attachment-0003.obj -------------- next part -------------- A non-text attachment was scrubbed... Name: RuleFactor.java Type: application/octet-stream Size: 1105 bytes Desc: not available Url : http://lists.jboss.org/pipermail/rules-users/attachments/20140712/80dd6cf6/attachment-0004.obj -------------- next part -------------- A non-text attachment was scrubbed... Name: ProducerMasterForRules.java Type: application/octet-stream Size: 2010 bytes Desc: not available Url : http://lists.jboss.org/pipermail/rules-users/attachments/20140712/80dd6cf6/attachment-0005.obj From dsotty at gmail.com Sat Jul 12 12:30:08 2014 From: dsotty at gmail.com (Davide Sottara) Date: Sat, 12 Jul 2014 17:30:08 +0100 Subject: [rules-users] Workaround: EventFactHandle retained in memory after FactCount reaches 0 for temporal-based rule In-Reply-To: <749AF81F-EB48-458A-8457-735CA44DD7D6@psware.com> References: <5BD2B8A2-53FE-4319-AB57-48015E9D6A9F@psware.com> <749AF81F-EB48-458A-8457-735CA44DD7D6@psware.com> Message-ID: <53C16290.5000507@gmail.com> Thanks for reporting, we'll investigate both this and 498 Davide On 07/11/2014 08:38 PM, Kent Anderson wrote: > We have found a workaround that eliminates the leftover event (gone > from Working Memory, but not from the JVM memory): > > The rule "forget it ever happened" (seen below) causes the problem. > Re-writing it to remove the check for RAISE in the LHS eliminated the > memory leak. Of course, our application requires the check for RAISE, > so it can be accomplished by manually querying working memory from the > RHS. It's ugly, but it resolved the issue. > > query existsRaise($id) > $raise : MyEvent( eventState == EventState.RAISE, eventId == $id ) > end > > rule"process clear" > no-loop > when > $clear : MyEvent(eventState == EventState.CLEAR, $clearId : eventId) > then > QueryResults results = kcontext.getKieRuntime().getQueryResults( > "existsRaise", $clearId ); > if (results.size() == 0) { > System.out.println( "Forwarding CLEAR(" + $clearId + ")" ); > } else { > System.out.println("Forgetting RAISE/CLEAR(" + $clearId + ")"); > for (QueryResultsRow row : results){ > MyEvent raise = (MyEvent) row.get ("$raise"); > delete(raise); > } > } > delete($clear); > end > > This appears to be a similar situation > to https://issues.jboss.org/browse/DROOLS-498. > > > > On Jul 10, 2014, at 3:54 PM, Kent Anderson > wrote: > >> Correction: The original post did not include another rule that >> exists in the stream. The memory leak does not appear unless both >> rules are active in the stream. >> >> declare MyEvent >> @role(event) >> @timestamp(timestamp) >> end >> >> /* If a RAISE is buffered for N seconds, send it out */ >> rule"forward raise" >> no-loop >> duration(3s) >> when >> $raise : MyEvent(eventState == EventState.RAISE, $raiseId : eventId) >> then >> System.out.println("Forwarding RAISE(" + $raiseId + ")"); >> delete($raise); >> end >> >> /* When CLEAR, and buffered, clear them both out */ >> rule"forget it ever happened" >> no-loop >> when >> $clear : MyEvent(eventState == EventState.CLEAR, $clearId : eventId) >> $raise : MyEvent(eventState == EventState.RAISE, eventId == $clearId) >> then >> System.out.println("Forgetting RAISE/CLEAR(" + $clearId + ")"); >> delete($clear); >> delete($raise); >> end >> >> >> On Jul 10, 2014, at 2:50 PM, Kent Anderson > > wrote: >> >>> The following rule produces a memory leak in Drools 6.1.0-SNAPSHOT: >>> >>> (Stream mode) >>> >>> declare MyEvent >>> @role(event) >>> @timestamp(timestamp) >>> end >>> >>> /* If a RAISE is buffered for N seconds, send it out */ >>> rule"forward raise" >>> no-loop >>> duration(3s) >>> when >>> $raise : MyEvent(eventState == EventState.RAISE, $raiseId : eventId) >>> then >>> System.out.println("Forwarding RAISE(" + $raiseId + ")"); >>> delete($raise); >>> end >>> >>> >>> I see the rule fire as expected, printing out the message 3 seconds >>> after the event is added into the session. While the event is >>> waiting, I see a FactCount of 1 in the session. After the rule >>> fires, the fact count goes to 0. However, using JVisualVm, querying >>> the heap dump shows 1 instance of MyEvent, referenced by an >>> EventFactHandle and several other Drools objects. >>> >>> Is this a bug, or is there a better way to write this rule so >>> Drools' internals let go of the object after it is no longer a fact? >>> >>> >>> >>> >>> _______________________________________________ >>> rules-users mailing list >>> rules-users at lists.jboss.org >>> https://lists.jboss.org/mailman/listinfo/rules-users >> >> _______________________________________________ >> rules-users mailing list >> rules-users at lists.jboss.org >> https://lists.jboss.org/mailman/listinfo/rules-users > > > > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140712/4b17c142/attachment.html From borris at chaos.org.uk Sun Jul 13 12:26:38 2014 From: borris at chaos.org.uk (Borris) Date: Sun, 13 Jul 2014 17:26:38 +0100 Subject: [rules-users] Hang in Drools Builder during Building Workspace with Eclipse Message-ID: <53C2B33E.7080308@chaos.org.uk> If I have global java.util.List > countsList; then Drools Builder never finishes. If I have global java.util.List countsList; Then the problem does not occur. So it's the diamond brackets <> causing the hang. I'm not claiming this is the code I want - I was part way through changing some stuff between Drools and Java and ended up with the <> present whilst I was thinking. Either auto-save or my fingers doing the equivalent a bit later triggered the hang. The impact is massive, unfortunately, as Eclipse tries to build the workspace (by default) on starting, and you need to have finished workspace building before you can get the the dlg to disable the automatic workspace building or the use of Drools Builder. This happens in 6.1.0.201407130611 - but I was using 6.1.0.201407061813 when it went wrong. Is there anything else I can add to be helpful? Borris From mproctor at codehaus.org Sun Jul 13 22:31:29 2014 From: mproctor at codehaus.org (Mark Proctor) Date: Mon, 14 Jul 2014 03:31:29 +0100 Subject: [rules-users] Workaround: EventFactHandle retained in memory after FactCount reaches 0 for temporal-based rule In-Reply-To: <749AF81F-EB48-458A-8457-735CA44DD7D6@psware.com> References: <5BD2B8A2-53FE-4319-AB57-48015E9D6A9F@psware.com> <749AF81F-EB48-458A-8457-735CA44DD7D6@psware.com> Message-ID: <053D2B3B-B818-4FF2-B001-94E16CF16171@codehaus.org> Could you submit a unit test as a pull request? http://docs.jboss.org/drools/release/5.5.0.Final/droolsjbpm-introduction-docs/html/gettingstarted.html Add it to here, and follow existing conventions: https://github.com/droolsjbpm/drools/blob/master/drools-compiler/src/test/java/org/drools/compiler/integrationtests/CepEspTest.java Mark On 11 Jul 2014, at 20:38, Kent Anderson wrote: > We have found a workaround that eliminates the leftover event (gone from Working Memory, but not from the JVM memory): > > The rule ?forget it ever happened? (seen below) causes the problem. Re-writing it to remove the check for RAISE in the LHS eliminated the memory leak. Of course, our application requires the check for RAISE, so it can be accomplished by manually querying working memory from the RHS. It?s ugly, but it resolved the issue. > > query existsRaise($id) > $raise : MyEvent( eventState == EventState.RAISE, eventId == $id ) > end > > rule "process clear" > no-loop > when > $clear : MyEvent(eventState == EventState.CLEAR, $clearId : eventId) > then > QueryResults results = kcontext.getKieRuntime().getQueryResults( "existsRaise", $clearId ); > if (results.size() == 0) { > System.out.println( "Forwarding CLEAR(" + $clearId + ")" ); > } else { > System.out.println("Forgetting RAISE/CLEAR(" + $clearId + ")"); > for (QueryResultsRow row : results){ > MyEvent raise = (MyEvent) row.get ("$raise"); > delete(raise); > } > } > delete($clear); > end > > This appears to be a similar situation to https://issues.jboss.org/browse/DROOLS-498. > > > > On Jul 10, 2014, at 3:54 PM, Kent Anderson wrote: > >> Correction: The original post did not include another rule that exists in the stream. The memory leak does not appear unless both rules are active in the stream. >> >> declare MyEvent >> @role(event) >> @timestamp(timestamp) >> end >> >> /* If a RAISE is buffered for N seconds, send it out */ >> rule "forward raise" >> no-loop >> duration (3s) >> when >> $raise : MyEvent(eventState == EventState.RAISE, $raiseId : eventId) >> then >> System.out.println("Forwarding RAISE(" + $raiseId + ")"); >> delete($raise); >> end >> >> /* When CLEAR, and buffered, clear them both out */ >> rule "forget it ever happened" >> no-loop >> when >> $clear : MyEvent(eventState == EventState.CLEAR, $clearId : eventId) >> $raise : MyEvent(eventState == EventState.RAISE, eventId == $clearId) >> then >> System.out.println("Forgetting RAISE/CLEAR(" + $clearId + ")"); >> delete($clear); >> delete($raise); >> end >> >> >> On Jul 10, 2014, at 2:50 PM, Kent Anderson wrote: >> >>> The following rule produces a memory leak in Drools 6.1.0-SNAPSHOT: >>> >>> (Stream mode) >>> >>> declare MyEvent >>> @role(event) >>> @timestamp(timestamp) >>> end >>> >>> /* If a RAISE is buffered for N seconds, send it out */ >>> rule "forward raise" >>> no-loop >>> duration (3s) >>> when >>> $raise : MyEvent(eventState == EventState.RAISE, $raiseId : eventId) >>> then >>> System.out.println("Forwarding RAISE(" + $raiseId + ")"); >>> delete($raise); >>> end >>> >>> >>> I see the rule fire as expected, printing out the message 3 seconds after the event is added into the session. While the event is waiting, I see a FactCount of 1 in the session. After the rule fires, the fact count goes to 0. However, using JVisualVm, querying the heap dump shows 1 instance of MyEvent, referenced by an EventFactHandle and several other Drools objects. >>> >>> Is this a bug, or is there a better way to write this rule so Drools? internals let go of the object after it is no longer a fact? >>> >>> >>> >>> >>> _______________________________________________ >>> rules-users mailing list >>> rules-users at lists.jboss.org >>> https://lists.jboss.org/mailman/listinfo/rules-users >> >> _______________________________________________ >> rules-users mailing list >> rules-users at lists.jboss.org >> https://lists.jboss.org/mailman/listinfo/rules-users > > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140714/6bb4e0c2/attachment-0001.html From toni.rikkola at gmail.com Mon Jul 14 01:43:48 2014 From: toni.rikkola at gmail.com (Toni Rikkola) Date: Mon, 14 Jul 2014 08:43:48 +0300 Subject: [rules-users] kie-wb 6.1.CR2 In-Reply-To: <1405155844506-4030321.post@n3.nabble.com> References: <1405155844506-4030321.post@n3.nabble.com> Message-ID: <1405316628.6015.0.camel@localhost.localdomain> You can get 6.1.0.CR2 from Nexus. https://repository.jboss.org/nexus/index.html#nexus-search;quick~kie-wb-dis Toni On la, 2014-07-12 at 02:04 -0700, Sumit Dhaniya wrote: > Is there any link from where I can download kie-wb6.1.CR2 or I'll have to > clone the project and create war. > I tried the nightly build but unfortunately it doesn't works. > When I deploy it in tomcat 7 I can't access index page. > > > > -- > View this message in context: http://drools.46999.n3.nabble.com/kie-wb-6-1-CR2-tp4030321.html > Sent from the Drools: User forum mailing list archive at Nabble.com. > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users From jps at jps.ch Mon Jul 14 05:25:50 2014 From: jps at jps.ch (jps) Date: Mon, 14 Jul 2014 02:25:50 -0700 (PDT) Subject: [rules-users] drools-wb 6.1.0.CR1-wildfly - error when upload jar M2 Repo In-Reply-To: References: <1404917178976-4030276.post@n3.nabble.com> Message-ID: <1405329950140-4030330.post@n3.nabble.com> Hello manstis, Thanks for you reply. Just tried with 6.1.0.CR2 (wildfly-8.1.0.Final + java version "1.7.0_11"), but still the same error :(( 10:42:46,359 INFO [org.guvnor.m2repo.backend.server.M2Servlet] (default task-14) POST request received. 10:42:46,851 ERROR [io.undertow.request] (default task-14) UT005023: Exception handling request to /kie-drools-wb-distribution-wars-6.1.0.CR2-wildfly/maven2: java.lang.LinkageError: com/ning/http/client/providers/netty/NettyAsyncHttpProvider at org.sonatype.maven.wagon.AhcWagon.openConnectionInternal(AhcWagon.java:150) [wagon-ahc-1.2.1.jar:] at org.apache.maven.wagon.AbstractWagon.openConnection(AbstractWagon.java:105) [wagon-provider-api-1.0.jar:1.0] at org.apache.maven.wagon.AbstractWagon.connect(AbstractWagon.java:207) [wagon-provider-api-1.0.jar:1.0] at org.sonatype.aether.connector.wagon.WagonRepositoryConnector.connectWagon(WagonRepositoryConnector.java:345) [aether-connector-wagon-1.13.1.jar:] at org.sonatype.aether.connector.wagon.WagonRepositoryConnector.pollWagon(WagonRepositoryConnector.java:385) [aether-connector-wagon-1.13.1.jar:] at org.sonatype.aether.connector.wagon.WagonRepositoryConnector$GetTask.run(WagonRepositoryConnector.java:571) [aether-connector-wagon-1.13.1.jar:] at org.sonatype.aether.util.concurrency.RunnableErrorForwarder$1.run(RunnableErrorForwarder.java:60) [aether-util-1.13.1.jar:] at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110) [rt.jar:1.7.0_11] at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603) [rt.jar:1.7.0_11] at java.lang.Thread.run(Thread.java:722) [rt.jar:1.7.0_11] 10:42:46,856 ERROR [stderr] (pool-15-thread-1) Exception in thread "pool-15-thread-1" java.lang.LinkageError: com/ning/http/client/providers/netty/NettyAsyncHttpProvider 10:42:46,857 ERROR [stderr] (pool-15-thread-1) at org.sonatype.maven.wagon.AhcWagon.openConnectionInternal(AhcWagon.java:150) 10:42:46,858 ERROR [stderr] (pool-15-thread-1) at org.apache.maven.wagon.AbstractWagon.openConnection(AbstractWagon.java:105) 10:42:46,859 ERROR [stderr] (pool-15-thread-1) at org.apache.maven.wagon.AbstractWagon.connect(AbstractWagon.java:207) 10:42:46,859 ERROR [stderr] (pool-15-thread-1) at org.sonatype.aether.connector.wagon.WagonRepositoryConnector.connectWagon(WagonRepositoryConnector.java:345) 10:42:46,860 ERROR [stderr] (pool-15-thread-1) at org.sonatype.aether.connector.wagon.WagonRepositoryConnector.pollWagon(WagonRepositoryConnector.java:385) 10:42:46,860 ERROR [stderr] (pool-15-thread-1) at org.sonatype.aether.connector.wagon.WagonRepositoryConnector$GetTask.run(WagonRepositoryConnector.java:571) 10:42:46,860 ERROR [stderr] (pool-15-thread-1) at org.sonatype.aether.util.concurrency.RunnableErrorForwarder$1.run(RunnableErrorForwarder.java:60) 10:42:46,861 ERROR [stderr] (pool-15-thread-1) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110) 10:42:46,861 ERROR [stderr] (pool-15-thread-1) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603) 10:42:46,862 ERROR [stderr] (pool-15-thread-1) at java.lang.Thread.run(Thread.java:722) Investigating a little : Uploading a mavenized JAR with one dependency and a two-level parent project => KO (that's my usecase) "java.lang.LinkageError" Uploading a mavenized JAR with several dependencies and no parent project => KO, "java.lang.LinkageError" Uploading a mavenized JAR with no dependency and a single-level pom parent project => upload OK, but with error in log : Caused by: org.apache.maven.model.building.ModelBuildingException: 1 problem was encountered while building the effective model for group-xxx:artifact-xxx:0.31 [ERROR] Invalid packaging for parent POM group-xxx:artifact-xxx:0.31, must be "pom" but is "jar" @ group-xxx:artifact-xxx:0.31 "java.lang.LinkageError" should indicate that there is a version mismatch somewhere with the netty JAR ?? Isn't it ? For now, my workaround is now to manually install the jar into the local repository : mvn install-file -Dfile=path-to-your-artifact-jar \ -DgroupId=your.groupId \ -DartifactId=your-artifactId \ -Dversion=version \ -Dpackaging=jar -DlocalRepositoryPath=*/usr/jboss/wildfly-8.1.0.Final/bin/repositories/kie* Regards, jps -- View this message in context: http://drools.46999.n3.nabble.com/drools-wb-6-1-0-CR1-wildfly-error-when-upload-jar-M2-Repo-tp4030276p4030330.html Sent from the Drools: User forum mailing list archive at Nabble.com. From mario.fusco at gmail.com Mon Jul 14 05:26:57 2014 From: mario.fusco at gmail.com (Mario Fusco) Date: Mon, 14 Jul 2014 02:26:57 -0700 (PDT) Subject: [rules-users] conditions getting removed from Guided Rule In-Reply-To: <1405158808834-4030322.post@n3.nabble.com> References: <1405110192572-4030308.post@n3.nabble.com> <1405158808834-4030322.post@n3.nabble.com> Message-ID: <1405330017517-4030331.post@n3.nabble.com> Thanks for your clarifications. The problem was in mvel. I reproduced and fixed it ( https://github.com/mvel/mvel/commit/874b03a8c5700661b503d96ad5d2ce1397cde18a ). The fix will be available when we will drop another mvel release and integrate it. For now I can only confirm that field names starting with an underscore cannot work with the current release. Thanks again and regards, Mario -- View this message in context: http://drools.46999.n3.nabble.com/conditions-getting-removed-from-Guided-Rule-tp4030308p4030331.html Sent from the Drools: User forum mailing list archive at Nabble.com. From michael.anstis at gmail.com Mon Jul 14 05:52:33 2014 From: michael.anstis at gmail.com (Michael Anstis) Date: Mon, 14 Jul 2014 10:52:33 +0100 Subject: [rules-users] drools-wb 6.1.0.CR1-wildfly - error when upload jar M2 Repo In-Reply-To: <1405329950140-4030330.post@n3.nabble.com> References: <1404917178976-4030276.post@n3.nabble.com> <1405329950140-4030330.post@n3.nabble.com> Message-ID: I've tried AS7 and Wildfly CR2 with a simple JAR (we use to kick the tyres of the M2Repo Upload stuff) and it works fine on both. I have to speculate that the problem you're encountering is something specific to the JAR you're trying to upload. Can you please create a JIRA at https://issues.jboss.org/browse/GUVNOR and attach a minimal JAR I can upload to reproduce the issue? Thanks, Mike On 14 July 2014 10:25, jps wrote: > Hello manstis, > > Thanks for you reply. > > Just tried with 6.1.0.CR2 (wildfly-8.1.0.Final + java version "1.7.0_11"), > but still the same error :(( > > > 10:42:46,359 INFO [org.guvnor.m2repo.backend.server.M2Servlet] (default > task-14) POST request received. > 10:42:46,851 ERROR [io.undertow.request] (default task-14) UT005023: > Exception handling request to > /kie-drools-wb-distribution-wars-6.1.0.CR2-wildfly/maven2: > java.lang.LinkageError: > com/ning/http/client/providers/netty/NettyAsyncHttpProvider > at > org.sonatype.maven.wagon.AhcWagon.openConnectionInternal(AhcWagon.java:150) > [wagon-ahc-1.2.1.jar:] > at > org.apache.maven.wagon.AbstractWagon.openConnection(AbstractWagon.java:105) > [wagon-provider-api-1.0.jar:1.0] > at > org.apache.maven.wagon.AbstractWagon.connect(AbstractWagon.java:207) > [wagon-provider-api-1.0.jar:1.0] > at > > org.sonatype.aether.connector.wagon.WagonRepositoryConnector.connectWagon(WagonRepositoryConnector.java:345) > [aether-connector-wagon-1.13.1.jar:] > at > > org.sonatype.aether.connector.wagon.WagonRepositoryConnector.pollWagon(WagonRepositoryConnector.java:385) > [aether-connector-wagon-1.13.1.jar:] > at > > org.sonatype.aether.connector.wagon.WagonRepositoryConnector$GetTask.run(WagonRepositoryConnector.java:571) > [aether-connector-wagon-1.13.1.jar:] > at > > org.sonatype.aether.util.concurrency.RunnableErrorForwarder$1.run(RunnableErrorForwarder.java:60) > [aether-util-1.13.1.jar:] > at > > java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110) > [rt.jar:1.7.0_11] > at > > java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603) > [rt.jar:1.7.0_11] > at java.lang.Thread.run(Thread.java:722) [rt.jar:1.7.0_11] > > 10:42:46,856 ERROR [stderr] (pool-15-thread-1) Exception in thread > "pool-15-thread-1" java.lang.LinkageError: > com/ning/http/client/providers/netty/NettyAsyncHttpProvider > 10:42:46,857 ERROR [stderr] (pool-15-thread-1) at > org.sonatype.maven.wagon.AhcWagon.openConnectionInternal(AhcWagon.java:150) > 10:42:46,858 ERROR [stderr] (pool-15-thread-1) at > org.apache.maven.wagon.AbstractWagon.openConnection(AbstractWagon.java:105) > 10:42:46,859 ERROR [stderr] (pool-15-thread-1) at > org.apache.maven.wagon.AbstractWagon.connect(AbstractWagon.java:207) > 10:42:46,859 ERROR [stderr] (pool-15-thread-1) at > > org.sonatype.aether.connector.wagon.WagonRepositoryConnector.connectWagon(WagonRepositoryConnector.java:345) > 10:42:46,860 ERROR [stderr] (pool-15-thread-1) at > > org.sonatype.aether.connector.wagon.WagonRepositoryConnector.pollWagon(WagonRepositoryConnector.java:385) > 10:42:46,860 ERROR [stderr] (pool-15-thread-1) at > > org.sonatype.aether.connector.wagon.WagonRepositoryConnector$GetTask.run(WagonRepositoryConnector.java:571) > 10:42:46,860 ERROR [stderr] (pool-15-thread-1) at > > org.sonatype.aether.util.concurrency.RunnableErrorForwarder$1.run(RunnableErrorForwarder.java:60) > 10:42:46,861 ERROR [stderr] (pool-15-thread-1) at > > java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110) > 10:42:46,861 ERROR [stderr] (pool-15-thread-1) at > > java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603) > 10:42:46,862 ERROR [stderr] (pool-15-thread-1) at > java.lang.Thread.run(Thread.java:722) > > > > Investigating a little : > > Uploading a mavenized JAR with one dependency and a two-level parent > project > => KO (that's my usecase) "java.lang.LinkageError" > Uploading a mavenized JAR with several dependencies and no parent project > => > KO, "java.lang.LinkageError" > Uploading a mavenized JAR with no dependency and a single-level pom parent > project => upload OK, but with error in log : > > > Caused by: org.apache.maven.model.building.ModelBuildingException: 1 > problem > was encountered while building the effective model for > group-xxx:artifact-xxx:0.31 > [ERROR] Invalid packaging for parent POM group-xxx:artifact-xxx:0.31, must > be "pom" but is "jar" @ group-xxx:artifact-xxx:0.31 > > > > "java.lang.LinkageError" should indicate that there is a version mismatch > somewhere with the netty JAR ?? Isn't it ? > > > For now, my workaround is now to manually install the jar into the local > repository : > > mvn install-file > -Dfile=path-to-your-artifact-jar \ > -DgroupId=your.groupId \ > -DartifactId=your-artifactId \ > -Dversion=version \ > -Dpackaging=jar > > -DlocalRepositoryPath=*/usr/jboss/wildfly-8.1.0.Final/bin/repositories/kie* > > > Regards, > jps > > > > > > > -- > View this message in context: > http://drools.46999.n3.nabble.com/drools-wb-6-1-0-CR1-wildfly-error-when-upload-jar-M2-Repo-tp4030276p4030330.html > Sent from the Drools: User forum mailing list archive at Nabble.com. > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140714/e45e2f06/attachment.html From michael.anstis at gmail.com Mon Jul 14 07:28:51 2014 From: michael.anstis at gmail.com (Michael Anstis) Date: Mon, 14 Jul 2014 12:28:51 +0100 Subject: [rules-users] check list size In-Reply-To: <1405088099538-4030303.post@n3.nabble.com> References: <1405088099538-4030303.post@n3.nabble.com> Message-ID: I had a look, but was able to use a List without problem (6.1.CR2): 1) Made a Maven-ized JAR containing the following class: package org.anstis; import java.util.List; public class MyListClass { private List myList; public List getMyList() { return myList; } public void setMyList( List myList ) { this.myList = myList; } } 2) Uploaded JAR to the workbench's Artifact Repository 3) Added a project dependency on this artifact 4) Added an Import Suggestion for java.util.List 5) Created a new Guided Rule 6) Imported MyListClass and java.util.List (Config tab) 7) Created the following rule: package org.mortgages; import java.lang.Number; import java.util.List; import org.anstis.MyListClass; rule "r1" dialect "mvel" when MyListClass( myList.size() < 5 ) then end You need to use an "Expression" to use the "size()" method call (as it is not a field, but a method call). Fields are "getXXX" or "setYYY" or public members. With kind regards, Mike On 11 July 2014 15:14, Sumit Dhaniya wrote: > I have a class which contains some lists, I want to apply rules on size of > list and want to use functions like first(), last() but list objects which > are in my class are identified as collections and only collection related > functions are shown. > > For eg. > > class A { > java.util.List bList = new ArrayList(); > } > > now it shows bList as collection type and it doesn't shows size and related > list function instead shows collection functions like contains etc. > > Can't I use it like both a collection as well as List? > > I tried importing java.util.List but it still don't recognize my List > objects as List > > > > -- > View this message in context: > http://drools.46999.n3.nabble.com/check-list-size-tp4030303.html > Sent from the Drools: User forum mailing list archive at Nabble.com. > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140714/061c0f00/attachment-0001.html From michael.anstis at gmail.com Mon Jul 14 07:29:13 2014 From: michael.anstis at gmail.com (Michael Anstis) Date: Mon, 14 Jul 2014 12:29:13 +0100 Subject: [rules-users] condition on size of list In-Reply-To: References: <1404930003793-4030283.post@n3.nabble.com> Message-ID: See my other reply. On 11 July 2014 10:08, sumit dhaniya wrote: > After restarting the server it started showing list in import suggestions > but still it doesn't shows size and other list operation on the list's in > my object. For eg. > > class A { > List bList = new ArrayList(); > } > > now it shows bList as a variable but it doesn't shows size and related > list function instead shows collection functions like contains etc. > > Can't I use it like both a collection as well as List? > > > On Thu, Jul 10, 2014 at 7:53 PM, sumit dhaniya > wrote: > >> I already tried building the project do I need to do something else to >> get java.util.List get listed in the import suggestions of my file because >> even when I removed java.lang.Number from the project imports it still >> shows it in the import suggestion in config of my rule files. >> >> >> On Thu, Jul 10, 2014 at 7:41 PM, sumit dhaniya >> wrote: >> >>> First I tried by adding java.util.List, it didn't showed as import type >>> in config of the file. >>> Then I thought it might not pick interfaces so I also >>> imported java.util.ArrayList but still it doesn't shows it. >>> >>> I tried building project but still no luck. >>> >>> >>> On Thu, Jul 10, 2014 at 7:15 PM, Michael Anstis < >>> michael.anstis at gmail.com> wrote: >>> >>>> You need to add it. >>>> >>>> >>>> On 10 July 2014 14:43, sumit dhaniya wrote: >>>> >>>>> It doesn't shows java.util.List in import suggestions >>>>> >>>>> >>>>> On Thu, Jul 10, 2014 at 7:08 PM, Michael Anstis < >>>>> michael.anstis at gmail.com> wrote: >>>>> >>>>>> Did you import java.util.List (in Project Editor's "Import >>>>>> suggestions" and then on the editor's "Config" tab)? >>>>>> >>>>>> >>>>>> On 10 July 2014 13:10, sumit dhaniya wrote: >>>>>> >>>>>>> listIf I use model classes created in JAVA with some java.util.List >>>>>>> it identifies them as Collection(superclass of List) and then list options >>>>>>> like size,first,last doesn't show up. Is there any way I can force these >>>>>>> objects as type of List. >>>>>>> >>>>>>> >>>>>>> On Wed, Jul 9, 2014 at 11:52 PM, Michael Anstis < >>>>>>> michael.anstis at gmail.com> wrote: >>>>>>> >>>>>>>> Yes. >>>>>>>> >>>>>>>> Create a BRL Condition column and use an expression on the List >>>>>>>> pattern. >>>>>>>> >>>>>>>> Sent on the move >>>>>>>> On 9 Jul 2014 19:21, "Sumit Dhaniya" >>>>>>>> wrote: >>>>>>>> >>>>>>>>> I know we can check size of list if we write free form drl but is >>>>>>>>> it possible >>>>>>>>> to use size of the list as condition in guided decision table? >>>>>>>>> >>>>>>>>> >>>>>>>>> >>>>>>>>> -- >>>>>>>>> View this message in context: >>>>>>>>> http://drools.46999.n3.nabble.com/condition-on-size-of-list-tp4030283.html >>>>>>>>> Sent from the Drools: User forum mailing list archive at >>>>>>>>> Nabble.com. >>>>>>>>> _______________________________________________ >>>>>>>>> rules-users mailing list >>>>>>>>> rules-users at lists.jboss.org >>>>>>>>> https://lists.jboss.org/mailman/listinfo/rules-users >>>>>>>>> >>>>>>>> >>>>>>>> _______________________________________________ >>>>>>>> rules-users mailing list >>>>>>>> rules-users at lists.jboss.org >>>>>>>> https://lists.jboss.org/mailman/listinfo/rules-users >>>>>>>> >>>>>>> >>>>>>> >>>>>>> _______________________________________________ >>>>>>> rules-users mailing list >>>>>>> rules-users at lists.jboss.org >>>>>>> https://lists.jboss.org/mailman/listinfo/rules-users >>>>>>> >>>>>> >>>>>> >>>>>> _______________________________________________ >>>>>> rules-users mailing list >>>>>> rules-users at lists.jboss.org >>>>>> https://lists.jboss.org/mailman/listinfo/rules-users >>>>>> >>>>> >>>>> >>>>> _______________________________________________ >>>>> rules-users mailing list >>>>> rules-users at lists.jboss.org >>>>> https://lists.jboss.org/mailman/listinfo/rules-users >>>>> >>>> >>>> >>>> _______________________________________________ >>>> rules-users mailing list >>>> rules-users at lists.jboss.org >>>> https://lists.jboss.org/mailman/listinfo/rules-users >>>> >>> >>> >> > > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140714/e468d608/attachment.html From jps at jps.ch Mon Jul 14 07:51:12 2014 From: jps at jps.ch (jps) Date: Mon, 14 Jul 2014 04:51:12 -0700 (PDT) Subject: [rules-users] drools-wb 6.1.0.CR1-wildfly - error when upload jar M2 Repo In-Reply-To: References: <1404917178976-4030276.post@n3.nabble.com> <1405329950140-4030330.post@n3.nabble.com> Message-ID: <1405338672683-4030336.post@n3.nabble.com> For reference : https://issues.jboss.org/browse/GUVNOR-2108 -- View this message in context: http://drools.46999.n3.nabble.com/drools-wb-6-1-0-CR1-wildfly-error-when-upload-jar-M2-Repo-tp4030276p4030336.html Sent from the Drools: User forum mailing list archive at Nabble.com. From michael.anstis at gmail.com Mon Jul 14 08:39:05 2014 From: michael.anstis at gmail.com (Michael Anstis) Date: Mon, 14 Jul 2014 13:39:05 +0100 Subject: [rules-users] conditions getting removed from Guided Rule In-Reply-To: References: <1405110192572-4030308.post@n3.nabble.com> <1405158808834-4030322.post@n3.nabble.com> Message-ID: Hello, Class "ProducerMasterForRules" isn't valid; it references "getPCuisines()" that isn't in the class. Since your rule uses the affected public methods "getPrimaryCuisine()" and "getSecondaryCuisine()" can you provide the missing implementation? I could mock something up, but want to be sure to use exactly what you are. With kind regards, Mike On 12 July 2014 12:17, sumit dhaniya wrote: > Michael I really appreciate all the help from the forum and the time > invested by the people to answer the queries. > I'm working as a freelance developer so if support is something affordable > then please let me know. > > > > DRL :- > > > > 2.| 3.|import java.lang.Number;4. |import > com.sophic.foodeemee.offers.dto.SearchContext;5.| import > com.sophic.foodeemee.offers.dto.ProducerMasterForRules;6.|import > com.sophic.foodeemee.offers.dto.RuleFactor; 7.|8.|rule > "SecondaryCuisineRepeatUsage" 9.| dialect "mvel"10. | when11.| $searchContext > : SearchContext( lastThreeCuisines != null ) 12.| ProducerMasterForRules( > primaryCuisine != null , primaryCuisine != > $searchContext.lastThreeCuisines , secondaryCuisine != null , > secondaryCuisine == $searchContext.lastThreeCuisines ) 13.| $secondaryCuisineRepeatUsageFactor > : RuleFactor( )14.| then15.| $secondaryCuisineRepeatUsageFactor.setWeightageImpact( > -30 ); 16.| update( $secondaryCuisineRepeatUsageFactor );17.| end > > object models are attached. > > > On Sat, Jul 12, 2014 at 3:40 PM, Michael Anstis > wrote: > >> Asking (at least) three questions at the same time on the same thread is >> really going to annoy people. >> >> It's the weekend; most people are not working and you are not paying for >> our support. >> >> When I am at my computer on Monday I will be happy to answer more. For >> now; please provide the DRL for the rule that does not reopen correctly and >> your object model. >> >> Sent on the move >> On 12 Jul 2014 10:54, "Sumit Dhaniya" wrote: >> >>> I create the rule by comparing properties of two objects as shown in >>> image >>> attached. Till I don't close the window generated source looks fine but >>> when >>> I open this rule after closing it. >>> But when I open the rule next time it removes the highlighted condition >>> from >>> the rule and also removes them from drl. Just wondering is there anything >>> I'm doing wrong or issue is something else. >>> >>> >>> >>> >>> -- >>> View this message in context: >>> http://drools.46999.n3.nabble.com/conditions-getting-removed-from-Guided-Rule-tp4030308p4030322.html >>> Sent from the Drools: User forum mailing list archive at Nabble.com. >>> _______________________________________________ >>> rules-users mailing list >>> rules-users at lists.jboss.org >>> https://lists.jboss.org/mailman/listinfo/rules-users >>> >> >> _______________________________________________ >> rules-users mailing list >> rules-users at lists.jboss.org >> https://lists.jboss.org/mailman/listinfo/rules-users >> > > > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140714/46322663/attachment-0001.html From michael.anstis at gmail.com Mon Jul 14 08:54:26 2014 From: michael.anstis at gmail.com (Michael Anstis) Date: Mon, 14 Jul 2014 13:54:26 +0100 Subject: [rules-users] conditions getting removed from Guided Rule In-Reply-To: References: <1405110192572-4030308.post@n3.nabble.com> <1405158808834-4030322.post@n3.nabble.com> Message-ID: Hello, I wrote a test that checks the marshalling of the DRL and it passes OK. It could be that the workbench is failing fast midway through trying to marshal due to the MVEL issue Mario mentions (the test doesn't pro grammatically build meta-data from the classes in the model; whereas the workbench does). Can you re-try with alterations to your public getters/setters names (getId instead of get_id)? Thanks, Mike On 14 July 2014 13:39, Michael Anstis wrote: > Hello, > > Class "ProducerMasterForRules" isn't valid; it references "getPCuisines()" > that isn't in the class. > > Since your rule uses the affected public methods "getPrimaryCuisine()" and > "getSecondaryCuisine()" can you provide the missing implementation? > > I could mock something up, but want to be sure to use exactly what you are. > > With kind regards, > > Mike > > > On 12 July 2014 12:17, sumit dhaniya wrote: > >> Michael I really appreciate all the help from the forum and the time >> invested by the people to answer the queries. >> I'm working as a freelance developer so if support is something >> affordable then please let me know. >> >> >> >> DRL :- >> >> >> >> 2.| 3.|import java.lang.Number;4. |import >> com.sophic.foodeemee.offers.dto.SearchContext;5.| import >> com.sophic.foodeemee.offers.dto.ProducerMasterForRules;6.|import >> com.sophic.foodeemee.offers.dto.RuleFactor; 7.|8.|rule >> "SecondaryCuisineRepeatUsage" 9.| dialect "mvel"10. | when11.| $searchContext >> : SearchContext( lastThreeCuisines != null ) 12.| ProducerMasterForRules( >> primaryCuisine != null , primaryCuisine != >> $searchContext.lastThreeCuisines , secondaryCuisine != null , >> secondaryCuisine == $searchContext.lastThreeCuisines ) 13.| $secondaryCuisineRepeatUsageFactor >> : RuleFactor( )14. | then15.| $secondaryCuisineRepeatUsageFactor.setWeightageImpact( >> -30 ); 16.| update( $secondaryCuisineRepeatUsageFactor );17.| end >> >> object models are attached. >> >> >> On Sat, Jul 12, 2014 at 3:40 PM, Michael Anstis > > wrote: >> >>> Asking (at least) three questions at the same time on the same thread is >>> really going to annoy people. >>> >>> It's the weekend; most people are not working and you are not paying for >>> our support. >>> >>> When I am at my computer on Monday I will be happy to answer more. For >>> now; please provide the DRL for the rule that does not reopen correctly and >>> your object model. >>> >>> Sent on the move >>> On 12 Jul 2014 10:54, "Sumit Dhaniya" wrote: >>> >>>> I create the rule by comparing properties of two objects as shown in >>>> image >>>> attached. Till I don't close the window generated source looks fine but >>>> when >>>> I open this rule after closing it. >>>> But when I open the rule next time it removes the highlighted condition >>>> from >>>> the rule and also removes them from drl. Just wondering is there >>>> anything >>>> I'm doing wrong or issue is something else. >>>> >>>> >>>> >>>> >>>> -- >>>> View this message in context: >>>> http://drools.46999.n3.nabble.com/conditions-getting-removed-from-Guided-Rule-tp4030308p4030322.html >>>> Sent from the Drools: User forum mailing list archive at Nabble.com. >>>> _______________________________________________ >>>> rules-users mailing list >>>> rules-users at lists.jboss.org >>>> https://lists.jboss.org/mailman/listinfo/rules-users >>>> >>> >>> _______________________________________________ >>> rules-users mailing list >>> rules-users at lists.jboss.org >>> https://lists.jboss.org/mailman/listinfo/rules-users >>> >> >> >> _______________________________________________ >> rules-users mailing list >> rules-users at lists.jboss.org >> https://lists.jboss.org/mailman/listinfo/rules-users >> > > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140714/ef77b0fa/attachment.html From michael.anstis at gmail.com Mon Jul 14 08:56:11 2014 From: michael.anstis at gmail.com (Michael Anstis) Date: Mon, 14 Jul 2014 13:56:11 +0100 Subject: [rules-users] conditions getting removed from Guided Rule In-Reply-To: References: <1405110192572-4030308.post@n3.nabble.com> <1405158808834-4030322.post@n3.nabble.com> Message-ID: FYI, test http://github.com/droolsjbpm/drools/commit/ee232266c On 14 July 2014 13:54, Michael Anstis wrote: > Hello, > > I wrote a test that checks the marshalling of the DRL and it passes OK. > > It could be that the workbench is failing fast midway through trying to > marshal due to the MVEL issue Mario mentions (the test doesn't pro > grammatically build meta-data from the classes in the model; whereas the > workbench does). > > Can you re-try with alterations to your public getters/setters names > (getId instead of get_id)? > > Thanks, > > Mike > > > On 14 July 2014 13:39, Michael Anstis wrote: > >> Hello, >> >> Class "ProducerMasterForRules" isn't valid; it references >> "getPCuisines()" that isn't in the class. >> >> Since your rule uses the affected public methods "getPrimaryCuisine()" >> and "getSecondaryCuisine()" can you provide the missing implementation? >> >> I could mock something up, but want to be sure to use exactly what you >> are. >> >> With kind regards, >> >> Mike >> >> >> On 12 July 2014 12:17, sumit dhaniya wrote: >> >>> Michael I really appreciate all the help from the forum and the time >>> invested by the people to answer the queries. >>> I'm working as a freelance developer so if support is something >>> affordable then please let me know. >>> >>> >>> >>> DRL :- >>> >>> >>> >>> 2.| 3.|import java.lang.Number;4. |import >>> com.sophic.foodeemee.offers.dto.SearchContext;5.| import >>> com.sophic.foodeemee.offers.dto.ProducerMasterForRules;6.|import >>> com.sophic.foodeemee.offers.dto.RuleFactor; 7.|8.|rule >>> "SecondaryCuisineRepeatUsage" 9.| dialect "mvel"10. | when11.| $searchContext >>> : SearchContext( lastThreeCuisines != null ) 12.| ProducerMasterForRules( >>> primaryCuisine != null , primaryCuisine != >>> $searchContext.lastThreeCuisines , secondaryCuisine != null , >>> secondaryCuisine == $searchContext.lastThreeCuisines ) 13.| $secondaryCuisineRepeatUsageFactor >>> : RuleFactor( )14. | then15.| $secondaryCuisineRepeatUsageFactor.setWeightageImpact( >>> -30 ); 16.| update( $secondaryCuisineRepeatUsageFactor );17.| end >>> >>> object models are attached. >>> >>> >>> On Sat, Jul 12, 2014 at 3:40 PM, Michael Anstis < >>> michael.anstis at gmail.com> wrote: >>> >>>> Asking (at least) three questions at the same time on the same thread >>>> is really going to annoy people. >>>> >>>> It's the weekend; most people are not working and you are not paying >>>> for our support. >>>> >>>> When I am at my computer on Monday I will be happy to answer more. For >>>> now; please provide the DRL for the rule that does not reopen correctly and >>>> your object model. >>>> >>>> Sent on the move >>>> On 12 Jul 2014 10:54, "Sumit Dhaniya" wrote: >>>> >>>>> I create the rule by comparing properties of two objects as shown in >>>>> image >>>>> attached. Till I don't close the window generated source looks fine >>>>> but when >>>>> I open this rule after closing it. >>>>> But when I open the rule next time it removes the highlighted >>>>> condition from >>>>> the rule and also removes them from drl. Just wondering is there >>>>> anything >>>>> I'm doing wrong or issue is something else. >>>>> >>>>> >>>>> >>>>> >>>>> -- >>>>> View this message in context: >>>>> http://drools.46999.n3.nabble.com/conditions-getting-removed-from-Guided-Rule-tp4030308p4030322.html >>>>> Sent from the Drools: User forum mailing list archive at Nabble.com. >>>>> _______________________________________________ >>>>> rules-users mailing list >>>>> rules-users at lists.jboss.org >>>>> https://lists.jboss.org/mailman/listinfo/rules-users >>>>> >>>> >>>> _______________________________________________ >>>> rules-users mailing list >>>> rules-users at lists.jboss.org >>>> https://lists.jboss.org/mailman/listinfo/rules-users >>>> >>> >>> >>> _______________________________________________ >>> rules-users mailing list >>> rules-users at lists.jboss.org >>> https://lists.jboss.org/mailman/listinfo/rules-users >>> >> >> > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140714/f1204d9e/attachment-0001.html From sumitdhaniya at gmail.com Mon Jul 14 09:44:09 2014 From: sumitdhaniya at gmail.com (sumit dhaniya) Date: Mon, 14 Jul 2014 19:14:09 +0530 Subject: [rules-users] kie-wb 6.1.CR2 In-Reply-To: <1405316628.6015.0.camel@localhost.localdomain> References: <1405155844506-4030321.post@n3.nabble.com> <1405316628.6015.0.camel@localhost.localdomain> Message-ID: Thanks Toni On Mon, Jul 14, 2014 at 11:13 AM, Toni Rikkola wrote: > You can get 6.1.0.CR2 from Nexus. > > https://repository.jboss.org/nexus/index.html#nexus-search;quick~kie-wb-dis > > Toni > > On la, 2014-07-12 at 02:04 -0700, Sumit Dhaniya wrote: > > Is there any link from where I can download kie-wb6.1.CR2 or I'll have to > > clone the project and create war. > > I tried the nightly build but unfortunately it doesn't works. > > When I deploy it in tomcat 7 I can't access index page. > > > > > > > > -- > > View this message in context: > http://drools.46999.n3.nabble.com/kie-wb-6-1-CR2-tp4030321.html > > Sent from the Drools: User forum mailing list archive at Nabble.com. > > _______________________________________________ > > rules-users mailing list > > rules-users at lists.jboss.org > > https://lists.jboss.org/mailman/listinfo/rules-users > > > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140714/dd12d770/attachment.html From andrea.pacifico.85 at gmail.com Mon Jul 14 11:43:43 2014 From: andrea.pacifico.85 at gmail.com (braveheart85) Date: Mon, 14 Jul 2014 08:43:43 -0700 (PDT) Subject: [rules-users] Problem when I cleaning the production memory. Message-ID: <1405352623354-4030341.post@n3.nabble.com> Hello guys, I have a very strange behaviour when i execute this fragment of code: private void _clearKnowledge() { try { Collection knowledgePackages = _knowledgeBase.getKnowledgePackages(); for (KnowledgePackage singlePackage : knowledgePackages) { _log.debug("Removing knowledge in drools engine"); _log.debug("package name: " + singlePackage.getName()); _knowledgeBase.removeKnowledgePackage(singlePackage.getName()); } } catch (NullPointerException e) { // TODO An error about a missing package rarely occurs. _log.warn("Drools Engine has tried to remove a missing knowledge package."); } } Sporadically the system raise this ugly exception: Caused by: java.lang.NullPointerException at org.drools.reteoo.ReteooBuilder.removeRule(ReteooBuilder.java:252) at org.drools.reteoo.ReteooRuleBase.removeRule(ReteooRuleBase.java:459) at org.drools.common.AbstractRuleBase.removeRule(AbstractRuleBase.java:1099) at org.drools.common.AbstractRuleBase.removePackage(AbstractRuleBase.java:1017) at org.drools.impl.KnowledgeBaseImpl.removeKnowledgePackage(KnowledgeBaseImpl.java:202) at org.titan.frontend.memory.drools.DroolsEngine._clearKnowledge(DroolsEngine.java:304) I thought about timing issues, but each group of interaction with the engine is protected with a synchronized method on the facade of the module. The try-catch is the unique solution that I have found so far. Thanks Andrea -- View this message in context: http://drools.46999.n3.nabble.com/Problem-when-I-cleaning-the-production-memory-tp4030341.html Sent from the Drools: User forum mailing list archive at Nabble.com. From andrea.pacifico.85 at gmail.com Mon Jul 14 11:54:57 2014 From: andrea.pacifico.85 at gmail.com (braveheart85) Date: Mon, 14 Jul 2014 08:54:57 -0700 (PDT) Subject: [rules-users] Problem when I cleaning the production memory. In-Reply-To: <1405352623354-4030341.post@n3.nabble.com> References: <1405352623354-4030341.post@n3.nabble.com> Message-ID: <1405353297228-4030342.post@n3.nabble.com> I forgot to say what version I'm using. The version of Drools is 5.5. -- View this message in context: http://drools.46999.n3.nabble.com/Problem-when-I-cleaning-the-production-memory-tp4030341p4030342.html Sent from the Drools: User forum mailing list archive at Nabble.com. From dsotty at gmail.com Mon Jul 14 12:10:24 2014 From: dsotty at gmail.com (Davide Sottara) Date: Mon, 14 Jul 2014 17:10:24 +0100 Subject: [rules-users] Problem when I cleaning the production memory. In-Reply-To: <1405353297228-4030342.post@n3.nabble.com> References: <1405352623354-4030341.post@n3.nabble.com> <1405353297228-4030342.post@n3.nabble.com> Message-ID: <53C400F0.4020704@gmail.com> Can you try 5.6 or a later version? That part of logic was improved in 5.6, and rewritten in 6.x Davide On 07/14/2014 04:54 PM, braveheart85 wrote: > I forgot to say what version I'm using. The version of Drools is 5.5. > > > > -- > View this message in context: http://drools.46999.n3.nabble.com/Problem-when-I-cleaning-the-production-memory-tp4030341p4030342.html > Sent from the Drools: User forum mailing list archive at Nabble.com. > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users > From andrea.pacifico.85 at gmail.com Mon Jul 14 14:12:50 2014 From: andrea.pacifico.85 at gmail.com (braveheart85) Date: Mon, 14 Jul 2014 11:12:50 -0700 (PDT) Subject: [rules-users] Problem when I cleaning the production memory. In-Reply-To: <53C400F0.4020704@gmail.com> References: <1405352623354-4030341.post@n3.nabble.com> <1405353297228-4030342.post@n3.nabble.com> <53C400F0.4020704@gmail.com> Message-ID: <1405361570527-4030344.post@n3.nabble.com> Hi Davide, Thanks for the reply. Unfortunately I cannot migrate to version 5.6 or newer. Today I have inspected that part of code, but it is quite huge and complex in the Reeteo part. I have seen the NullPointer is due to the "nodes" retrieved from the "rules" Map (line 250). Moreover, this non-deterministic behaviour complicates everything. 65 private Map rules; 244 public synchronized void More ...removeRule(final Rule rule) { 245 // reset working memories for potential propagation 246 InternalWorkingMemory[] workingMemories = this.ruleBase.getWorkingMemories(); 247 248 final Object object = this.rules.remove( rule ); 249 250 final BaseNode[] nodes = (BaseNode[]) object; 251 final RuleRemovalContext context = new RuleRemovalContext( rule ); 252 for (final BaseNode node : nodes) { 253 node.remove( context, 254 this, 255 null, 256 workingMemories ); 257 } 258 259 resetMasks(context); 260 } I don't know if you can help me in some way... Thanks in all cases. Andrea -- View this message in context: http://drools.46999.n3.nabble.com/Problem-when-I-cleaning-the-production-memory-tp4030341p4030344.html Sent from the Drools: User forum mailing list archive at Nabble.com. From sumantp at yahoo.com Mon Jul 14 14:20:46 2014 From: sumantp at yahoo.com (sumantp) Date: Mon, 14 Jul 2014 11:20:46 -0700 (PDT) Subject: [rules-users] Evaluations are increasingly slower Message-ID: <1405362046300-4030345.post@n3.nabble.com> Hi, I have a rule that looks for 2 consecutive events for the same entity. To stress test it, I inserted 10K consecutive events. I'm calling fireAllRules() after each event is inserted. I'm printing out timestamps after every 100 events. I'm noticing that insertions/evaluations are increasingly slower. Here's the rule : rule "Consecutive events" when $latest : Event($id : id) // newest event not Event(id == $id, this after $latest) // no events after the newest $previous : Event(id == $id, this before $latest) // event before the newest not Event(id == $id, this before $latest, this after $previous) // no events between $latest and $previous then //System.out.println($latest.toString()); end It is my understanding that the above rule should only match the latest 2 events and automatic memory management should remove older events. If so, why are insertions progressively slower? Interestingly, ksession.getObjects() returns all the events inserted and not just the latest 2 events. Is my understanding of the rule incorrect? Does the rule somehow force all events to stay in memory? Thanks, Sumant -- View this message in context: http://drools.46999.n3.nabble.com/Evaluations-are-increasingly-slower-tp4030345.html Sent from the Drools: User forum mailing list archive at Nabble.com. From sumitdhaniya at gmail.com Mon Jul 14 15:16:56 2014 From: sumitdhaniya at gmail.com (sumit dhaniya) Date: Tue, 15 Jul 2014 00:46:56 +0530 Subject: [rules-users] check list size In-Reply-To: References: <1405088099538-4030303.post@n3.nabble.com> Message-ID: Thanks for the example Mike just upgraded to 6.1.CR2 it's working in it. Just need to add a BRL fragment if want to you in a Decision table. Thanks and Regards On Mon, Jul 14, 2014 at 4:58 PM, Michael Anstis wrote: > I had a look, but was able to use a List without problem (6.1.CR2): > > 1) Made a Maven-ized JAR containing the following class: > > package org.anstis; > > import java.util.List; > > public class MyListClass { > > private List myList; > > public List getMyList() { > return myList; > } > > public void setMyList( List myList ) { > this.myList = myList; > } > } > > 2) Uploaded JAR to the workbench's Artifact Repository > > 3) Added a project dependency on this artifact > > 4) Added an Import Suggestion for java.util.List > > 5) Created a new Guided Rule > > 6) Imported MyListClass and java.util.List (Config tab) > > 7) Created the following rule: > > package org.mortgages; > > import java.lang.Number; > import java.util.List; > import org.anstis.MyListClass; > > rule "r1" > dialect "mvel" > when > MyListClass( myList.size() < 5 ) > then > end > > You need to use an "Expression" to use the "size()" method call (as it is > not a field, but a method call). Fields are "getXXX" or "setYYY" or public > members. > > With kind regards, > > Mike > > On 11 July 2014 15:14, Sumit Dhaniya wrote: > >> I have a class which contains some lists, I want to apply rules on size of >> list and want to use functions like first(), last() but list objects which >> are in my class are identified as collections and only collection related >> functions are shown. >> >> For eg. >> >> class A { >> java.util.List bList = new ArrayList(); >> } >> >> now it shows bList as collection type and it doesn't shows size and >> related >> list function instead shows collection functions like contains etc. >> >> Can't I use it like both a collection as well as List? >> >> I tried importing java.util.List but it still don't recognize my List >> objects as List >> >> >> >> -- >> View this message in context: >> http://drools.46999.n3.nabble.com/check-list-size-tp4030303.html >> Sent from the Drools: User forum mailing list archive at Nabble.com. >> _______________________________________________ >> rules-users mailing list >> rules-users at lists.jboss.org >> https://lists.jboss.org/mailman/listinfo/rules-users >> > > > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140715/574a6c07/attachment.html From sumitdhaniya at gmail.com Mon Jul 14 15:19:10 2014 From: sumitdhaniya at gmail.com (sumit dhaniya) Date: Tue, 15 Jul 2014 00:49:10 +0530 Subject: [rules-users] conditions getting removed from Guided Rule In-Reply-To: References: <1405110192572-4030308.post@n3.nabble.com> <1405158808834-4030322.post@n3.nabble.com> Message-ID: Upgraded to 6.1CR2 it's fixed now. On Mon, Jul 14, 2014 at 6:26 PM, Michael Anstis wrote: > FYI, test http://github.com/droolsjbpm/drools/commit/ee232266c > > > On 14 July 2014 13:54, Michael Anstis wrote: > >> Hello, >> >> I wrote a test that checks the marshalling of the DRL and it passes OK. >> >> It could be that the workbench is failing fast midway through trying to >> marshal due to the MVEL issue Mario mentions (the test doesn't pro >> grammatically build meta-data from the classes in the model; whereas the >> workbench does). >> >> Can you re-try with alterations to your public getters/setters names >> (getId instead of get_id)? >> >> Thanks, >> >> Mike >> >> >> On 14 July 2014 13:39, Michael Anstis wrote: >> >>> Hello, >>> >>> Class "ProducerMasterForRules" isn't valid; it references >>> "getPCuisines()" that isn't in the class. >>> >>> Since your rule uses the affected public methods "getPrimaryCuisine()" >>> and "getSecondaryCuisine()" can you provide the missing implementation? >>> >>> I could mock something up, but want to be sure to use exactly what you >>> are. >>> >>> With kind regards, >>> >>> Mike >>> >>> >>> On 12 July 2014 12:17, sumit dhaniya wrote: >>> >>>> Michael I really appreciate all the help from the forum and the time >>>> invested by the people to answer the queries. >>>> I'm working as a freelance developer so if support is something >>>> affordable then please let me know. >>>> >>>> >>>> >>>> DRL :- >>>> >>>> >>>> >>>> 2.| 3.|import java.lang.Number;4. |import >>>> com.sophic.foodeemee.offers.dto.SearchContext;5.| import >>>> com.sophic.foodeemee.offers.dto.ProducerMasterForRules;6.|import >>>> com.sophic.foodeemee.offers.dto.RuleFactor; 7.|8.|rule >>>> "SecondaryCuisineRepeatUsage" 9.| dialect "mvel"10. | when11.| $searchContext >>>> : SearchContext( lastThreeCuisines != null ) 12.| ProducerMasterForRules( >>>> primaryCuisine != null , primaryCuisine != >>>> $searchContext.lastThreeCuisines , secondaryCuisine != null , >>>> secondaryCuisine == $searchContext.lastThreeCuisines ) 13.| $secondaryCuisineRepeatUsageFactor >>>> : RuleFactor( )14. | then15.| $secondaryCuisineRepeatUsageFactor.setWeightageImpact( >>>> -30 ); 16.| update( $secondaryCuisineRepeatUsageFactor );17.| >>>> end >>>> >>>> object models are attached. >>>> >>>> >>>> On Sat, Jul 12, 2014 at 3:40 PM, Michael Anstis < >>>> michael.anstis at gmail.com> wrote: >>>> >>>>> Asking (at least) three questions at the same time on the same thread >>>>> is really going to annoy people. >>>>> >>>>> It's the weekend; most people are not working and you are not paying >>>>> for our support. >>>>> >>>>> When I am at my computer on Monday I will be happy to answer more. For >>>>> now; please provide the DRL for the rule that does not reopen correctly and >>>>> your object model. >>>>> >>>>> Sent on the move >>>>> On 12 Jul 2014 10:54, "Sumit Dhaniya" wrote: >>>>> >>>>>> I create the rule by comparing properties of two objects as shown in >>>>>> image >>>>>> attached. Till I don't close the window generated source looks fine >>>>>> but when >>>>>> I open this rule after closing it. >>>>>> But when I open the rule next time it removes the highlighted >>>>>> condition from >>>>>> the rule and also removes them from drl. Just wondering is there >>>>>> anything >>>>>> I'm doing wrong or issue is something else. >>>>>> >>>>>> >>>>>> >>>>>> >>>>>> -- >>>>>> View this message in context: >>>>>> http://drools.46999.n3.nabble.com/conditions-getting-removed-from-Guided-Rule-tp4030308p4030322.html >>>>>> Sent from the Drools: User forum mailing list archive at Nabble.com. >>>>>> _______________________________________________ >>>>>> rules-users mailing list >>>>>> rules-users at lists.jboss.org >>>>>> https://lists.jboss.org/mailman/listinfo/rules-users >>>>>> >>>>> >>>>> _______________________________________________ >>>>> rules-users mailing list >>>>> rules-users at lists.jboss.org >>>>> https://lists.jboss.org/mailman/listinfo/rules-users >>>>> >>>> >>>> >>>> _______________________________________________ >>>> rules-users mailing list >>>> rules-users at lists.jboss.org >>>> https://lists.jboss.org/mailman/listinfo/rules-users >>>> >>> >>> >> > > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140715/b7009b7c/attachment-0001.html From kent.anderson at psware.com Mon Jul 14 15:33:46 2014 From: kent.anderson at psware.com (Kent Anderson) Date: Mon, 14 Jul 2014 12:33:46 -0700 Subject: [rules-users] Workaround: EventFactHandle retained in memory after FactCount reaches 0 for temporal-based rule In-Reply-To: <053D2B3B-B818-4FF2-B001-94E16CF16171@codehaus.org> References: <5BD2B8A2-53FE-4319-AB57-48015E9D6A9F@psware.com> <749AF81F-EB48-458A-8457-735CA44DD7D6@psware.com> <053D2B3B-B818-4FF2-B001-94E16CF16171@codehaus.org> Message-ID: <01270600-46E6-4E40-8C62-59EE72914126@psware.com> Is there a reliable way to find an EventFactHandle instance buried within the TupleEntryQueue?s and the PhreakPropagationContext?s? The multiple containers of interface/impl?s makes it nearly impossible to write a ?good? test that can peak under the hood where this memory leak is being held. If there is a recommended way to do it, I?d be happy to do so. On Jul 13, 2014, at 7:31 PM, Mark Proctor wrote: > Could you submit a unit test as a pull request? > http://docs.jboss.org/drools/release/5.5.0.Final/droolsjbpm-introduction-docs/html/gettingstarted.html > > Add it to here, and follow existing conventions: > https://github.com/droolsjbpm/drools/blob/master/drools-compiler/src/test/java/org/drools/compiler/integrationtests/CepEspTest.java > > Mark > On 11 Jul 2014, at 20:38, Kent Anderson wrote: > >> We have found a workaround that eliminates the leftover event (gone from Working Memory, but not from the JVM memory): >> >> The rule ?forget it ever happened? (seen below) causes the problem. Re-writing it to remove the check for RAISE in the LHS eliminated the memory leak. Of course, our application requires the check for RAISE, so it can be accomplished by manually querying working memory from the RHS. It?s ugly, but it resolved the issue. >> >> query existsRaise($id) >> $raise : MyEvent( eventState == EventState.RAISE, eventId == $id ) >> end >> >> rule "process clear" >> no-loop >> when >> $clear : MyEvent(eventState == EventState.CLEAR, $clearId : eventId) >> then >> QueryResults results = kcontext.getKieRuntime().getQueryResults( "existsRaise", $clearId ); >> if (results.size() == 0) { >> System.out.println( "Forwarding CLEAR(" + $clearId + ")" ); >> } else { >> System.out.println("Forgetting RAISE/CLEAR(" + $clearId + ")"); >> for (QueryResultsRow row : results){ >> MyEvent raise = (MyEvent) row.get ("$raise"); >> delete(raise); >> } >> } >> delete($clear); >> end >> >> This appears to be a similar situation to https://issues.jboss.org/browse/DROOLS-498. >> >> >> >> On Jul 10, 2014, at 3:54 PM, Kent Anderson wrote: >> >>> Correction: The original post did not include another rule that exists in the stream. The memory leak does not appear unless both rules are active in the stream. >>> >>> declare MyEvent >>> @role(event) >>> @timestamp(timestamp) >>> end >>> >>> /* If a RAISE is buffered for N seconds, send it out */ >>> rule "forward raise" >>> no-loop >>> duration (3s) >>> when >>> $raise : MyEvent(eventState == EventState.RAISE, $raiseId : eventId) >>> then >>> System.out.println("Forwarding RAISE(" + $raiseId + ")"); >>> delete($raise); >>> end >>> >>> /* When CLEAR, and buffered, clear them both out */ >>> rule "forget it ever happened" >>> no-loop >>> when >>> $clear : MyEvent(eventState == EventState.CLEAR, $clearId : eventId) >>> $raise : MyEvent(eventState == EventState.RAISE, eventId == $clearId) >>> then >>> System.out.println("Forgetting RAISE/CLEAR(" + $clearId + ")"); >>> delete($clear); >>> delete($raise); >>> end >>> >>> >>> On Jul 10, 2014, at 2:50 PM, Kent Anderson wrote: >>> >>>> The following rule produces a memory leak in Drools 6.1.0-SNAPSHOT: >>>> >>>> (Stream mode) >>>> >>>> declare MyEvent >>>> @role(event) >>>> @timestamp(timestamp) >>>> end >>>> >>>> /* If a RAISE is buffered for N seconds, send it out */ >>>> rule "forward raise" >>>> no-loop >>>> duration (3s) >>>> when >>>> $raise : MyEvent(eventState == EventState.RAISE, $raiseId : eventId) >>>> then >>>> System.out.println("Forwarding RAISE(" + $raiseId + ")"); >>>> delete($raise); >>>> end >>>> >>>> >>>> I see the rule fire as expected, printing out the message 3 seconds after the event is added into the session. While the event is waiting, I see a FactCount of 1 in the session. After the rule fires, the fact count goes to 0. However, using JVisualVm, querying the heap dump shows 1 instance of MyEvent, referenced by an EventFactHandle and several other Drools objects. >>>> >>>> Is this a bug, or is there a better way to write this rule so Drools? internals let go of the object after it is no longer a fact? >>>> >>>> >>>> >>>> >>>> _______________________________________________ >>>> rules-users mailing list >>>> rules-users at lists.jboss.org >>>> https://lists.jboss.org/mailman/listinfo/rules-users >>> >>> _______________________________________________ >>> rules-users mailing list >>> rules-users at lists.jboss.org >>> https://lists.jboss.org/mailman/listinfo/rules-users >> >> _______________________________________________ >> rules-users mailing list >> rules-users at lists.jboss.org >> https://lists.jboss.org/mailman/listinfo/rules-users > > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140714/7d70773e/attachment-0001.html -------------- next part -------------- A non-text attachment was scrubbed... Name: PastedGraphic-1.png Type: image/png Size: 54629 bytes Desc: not available Url : http://lists.jboss.org/pipermail/rules-users/attachments/20140714/7d70773e/attachment-0001.png From dsotty at gmail.com Mon Jul 14 16:10:14 2014 From: dsotty at gmail.com (Davide Sottara) Date: Mon, 14 Jul 2014 14:10:14 -0600 Subject: [rules-users] Problem when I cleaning the production memory. In-Reply-To: <1405361570527-4030344.post@n3.nabble.com> References: <1405352623354-4030341.post@n3.nabble.com> <1405353297228-4030342.post@n3.nabble.com> <53C400F0.4020704@gmail.com> <1405361570527-4030344.post@n3.nabble.com> Message-ID: I assume you can't recompile the source code of 5.5 either... If not, the only workaround is 1) try to identify which rule or rules cause the problem, 2) rewrite them to increase (or reduce) the node sharing On Jul 14, 2014 2:13 PM, "braveheart85" wrote: > Hi Davide, > > Thanks for the reply. > Unfortunately I cannot migrate to version 5.6 or newer. > Today I have inspected that part of code, but it is quite huge and complex > in the Reeteo part. > I have seen the NullPointer is due to the "nodes" retrieved from the > "rules" > Map (line 250). > Moreover, this non-deterministic behaviour complicates everything. > > 65 private Map rules; > > 244 public synchronized void More ...removeRule(final Rule rule) { > 245 // reset working memories for potential propagation > 246 InternalWorkingMemory[] workingMemories = > this.ruleBase.getWorkingMemories(); > 247 > 248 final Object object = this.rules.remove( rule ); > 249 > 250 final BaseNode[] nodes = (BaseNode[]) object; > 251 final RuleRemovalContext context = new RuleRemovalContext( rule > ); > 252 for (final BaseNode node : nodes) { > 253 node.remove( context, > 254 this, > 255 null, > 256 workingMemories ); > 257 } > 258 > 259 resetMasks(context); > 260 } > > I don't know if you can help me in some way... > Thanks in all cases. > Andrea > > > > -- > View this message in context: > http://drools.46999.n3.nabble.com/Problem-when-I-cleaning-the-production-memory-tp4030341p4030344.html > Sent from the Drools: User forum mailing list archive at Nabble.com. > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140714/7b3b8398/attachment.html From dsotty at gmail.com Mon Jul 14 17:09:51 2014 From: dsotty at gmail.com (Davide Sottara) Date: Mon, 14 Jul 2014 22:09:51 +0100 Subject: [rules-users] Workaround: EventFactHandle retained in memory after FactCount reaches 0 for temporal-based rule In-Reply-To: <01270600-46E6-4E40-8C62-59EE72914126@psware.com> References: <5BD2B8A2-53FE-4319-AB57-48015E9D6A9F@psware.com> <749AF81F-EB48-458A-8457-735CA44DD7D6@psware.com> <053D2B3B-B818-4FF2-B001-94E16CF16171@codehaus.org> <01270600-46E6-4E40-8C62-59EE72914126@psware.com> Message-ID: <53C4471F.60007@gmail.com> I'd need to check, but if you can put together the basics of the test case - the combination of rules and facts that causes the leak, we'll add the checks to ensure it's solved. Mark should have given you enough pointers to the style we use for test cases. We really appreciate your collaboration, and since this is a critical bug we'll fix it asap Thanks!! Davide On 07/14/2014 08:33 PM, Kent Anderson wrote: > Is there a reliable way to find an EventFactHandle instance buried > within the TupleEntryQueue's and the PhreakPropagationContext's? > > The multiple containers of interface/impl's makes it nearly impossible > to write a "good" test that can peak under the hood where this memory > leak is being held. If there is a recommended way to do it, I'd be > happy to do so. > > > > > On Jul 13, 2014, at 7:31 PM, Mark Proctor > wrote: > >> Could you submit a unit test as a pull request? >> http://docs.jboss.org/drools/release/5.5.0.Final/droolsjbpm-introduction-docs/html/gettingstarted.html >> >> Add it to here, and follow existing conventions: >> https://github.com/droolsjbpm/drools/blob/master/drools-compiler/src/test/java/org/drools/compiler/integrationtests/CepEspTest.java >> >> Mark >> On 11 Jul 2014, at 20:38, Kent Anderson > > wrote: >> >>> We have found a workaround that eliminates the leftover event (gone >>> from Working Memory, but not from the JVM memory): >>> >>> The rule "forget it ever happened" (seen below) causes the problem. >>> Re-writing it to remove the check for RAISE in the LHS eliminated >>> the memory leak. Of course, our application requires the check for >>> RAISE, so it can be accomplished by manually querying working memory >>> from the RHS. It's ugly, but it resolved the issue. >>> >>> query existsRaise($id) >>> $raise : MyEvent( eventState == EventState.RAISE, eventId == $id ) >>> end >>> >>> rule"process clear" >>> no-loop >>> when >>> $clear : MyEvent(eventState == EventState.CLEAR, $clearId : eventId) >>> then >>> QueryResults results = kcontext.getKieRuntime().getQueryResults( >>> "existsRaise", $clearId ); >>> if (results.size() == 0) { >>> System.out.println( "Forwarding CLEAR(" + $clearId + ")" ); >>> } else { >>> System.out.println("Forgetting RAISE/CLEAR(" + $clearId + ")"); >>> for (QueryResultsRow row : results){ >>> MyEvent raise = (MyEvent) row.get ("$raise"); >>> delete(raise); >>> } >>> } >>> delete($clear); >>> end >>> >>> This appears to be a similar situation >>> to https://issues.jboss.org/browse/DROOLS-498. >>> >>> >>> >>> On Jul 10, 2014, at 3:54 PM, Kent Anderson >> > wrote: >>> >>>> Correction: The original post did not include another rule that >>>> exists in the stream. The memory leak does not appear unless both >>>> rules are active in the stream. >>>> >>>> declare MyEvent >>>> @role(event) >>>> @timestamp(timestamp) >>>> end >>>> >>>> /* If a RAISE is buffered for N seconds, send it out */ >>>> rule"forward raise" >>>> no-loop >>>> duration(3s) >>>> when >>>> $raise : MyEvent(eventState == EventState.RAISE, $raiseId : eventId) >>>> then >>>> System.out.println("Forwarding RAISE(" + $raiseId + ")"); >>>> delete($raise); >>>> end >>>> >>>> /* When CLEAR, and buffered, clear them both out */ >>>> rule"forget it ever happened" >>>> no-loop >>>> when >>>> $clear : MyEvent(eventState == EventState.CLEAR, $clearId : eventId) >>>> $raise : MyEvent(eventState == EventState.RAISE, eventId == $clearId) >>>> then >>>> System.out.println("Forgetting RAISE/CLEAR(" + $clearId + ")"); >>>> delete($clear); >>>> delete($raise); >>>> end >>>> >>>> >>>> On Jul 10, 2014, at 2:50 PM, Kent Anderson >>>> > wrote: >>>> >>>>> The following rule produces a memory leak in Drools 6.1.0-SNAPSHOT: >>>>> >>>>> (Stream mode) >>>>> >>>>> declare MyEvent >>>>> @role(event) >>>>> @timestamp(timestamp) >>>>> end >>>>> >>>>> /* If a RAISE is buffered for N seconds, send it out */ >>>>> rule"forward raise" >>>>> no-loop >>>>> duration(3s) >>>>> when >>>>> $raise : MyEvent(eventState == EventState.RAISE, $raiseId : eventId) >>>>> then >>>>> System.out.println("Forwarding RAISE(" + $raiseId + ")"); >>>>> delete($raise); >>>>> end >>>>> >>>>> >>>>> I see the rule fire as expected, printing out the message 3 >>>>> seconds after the event is added into the session. While the >>>>> event is waiting, I see a FactCount of 1 in the session. After >>>>> the rule fires, the fact count goes to 0. However, using >>>>> JVisualVm, querying the heap dump shows 1 instance of MyEvent, >>>>> referenced by an EventFactHandle and several other Drools objects. >>>>> >>>>> Is this a bug, or is there a better way to write this rule so >>>>> Drools' internals let go of the object after it is no longer a fact? >>>>> >>>>> >>>>> >>>>> >>>>> _______________________________________________ >>>>> rules-users mailing list >>>>> rules-users at lists.jboss.org >>>>> https://lists.jboss.org/mailman/listinfo/rules-users >>>> >>>> _______________________________________________ >>>> rules-users mailing list >>>> rules-users at lists.jboss.org >>>> https://lists.jboss.org/mailman/listinfo/rules-users >>> >>> _______________________________________________ >>> rules-users mailing list >>> rules-users at lists.jboss.org >>> https://lists.jboss.org/mailman/listinfo/rules-users >> >> _______________________________________________ >> rules-users mailing list >> rules-users at lists.jboss.org >> https://lists.jboss.org/mailman/listinfo/rules-users > > > > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140714/b76de20a/attachment-0001.html -------------- next part -------------- A non-text attachment was scrubbed... Name: not available Type: image/png Size: 54629 bytes Desc: not available Url : http://lists.jboss.org/pipermail/rules-users/attachments/20140714/b76de20a/attachment-0001.png From roubikm at yahoo.com Mon Jul 14 18:09:21 2014 From: roubikm at yahoo.com (roubik) Date: Mon, 14 Jul 2014 15:09:21 -0700 (PDT) Subject: [rules-users] Dynamically loading rules in KieBase Message-ID: <1405375761418-4030351.post@n3.nabble.com> Hi, Before Drools 6.0 I was using the KnowledgeBase.addKnowledgePackages method to dynamically load packages into my knowledge base. Since KnowledgeBase has been deprecated what is the suggested approach to dynamically load rule in KieBase instead of using KnowledgeBase.addKnowledgePackages? Thanks, Roubik -- View this message in context: http://drools.46999.n3.nabble.com/Dynamically-loading-rules-in-KieBase-tp4030351.html Sent from the Drools: User forum mailing list archive at Nabble.com. From kent.anderson at psware.com Mon Jul 14 21:09:37 2014 From: kent.anderson at psware.com (Kent Anderson) Date: Mon, 14 Jul 2014 18:09:37 -0700 Subject: [rules-users] Workaround: EventFactHandle retained in memory after FactCount reaches 0 for temporal-based rule In-Reply-To: <53C4471F.60007@gmail.com> References: <5BD2B8A2-53FE-4319-AB57-48015E9D6A9F@psware.com> <749AF81F-EB48-458A-8457-735CA44DD7D6@psware.com> <053D2B3B-B818-4FF2-B001-94E16CF16171@codehaus.org> <01270600-46E6-4E40-8C62-59EE72914126@psware.com> <53C4471F.60007@gmail.com> Message-ID: <96BEA5D6-9EB5-421C-9655-4F0298DC0163@psware.com> https://github.com/droolsjbpm/drools/pull/358 Per your advice, this pull request sets up the memory leak, but it cannot verify that it exists without diving into internal drools structures. Please let me know what else we can do to facilitate fixing this issue. On Jul 14, 2014, at 2:09 PM, Davide Sottara wrote: > I'd need to check, but if you can put together the basics of the test case - the combination of rules and facts that causes the leak, > we'll add the checks to ensure it's solved. Mark should have given you enough pointers to the style we use for test cases. > We really appreciate your collaboration, and since this is a critical bug we'll fix it asap > Thanks!! > Davide > > On 07/14/2014 08:33 PM, Kent Anderson wrote: >> Is there a reliable way to find an EventFactHandle instance buried within the TupleEntryQueue?s and the PhreakPropagationContext?s? >> >> The multiple containers of interface/impl?s makes it nearly impossible to write a ?good? test that can peak under the hood where this memory leak is being held. If there is a recommended way to do it, I?d be happy to do so. >> >> >> >> >> >> On Jul 13, 2014, at 7:31 PM, Mark Proctor wrote: >> >>> Could you submit a unit test as a pull request? >>> http://docs.jboss.org/drools/release/5.5.0.Final/droolsjbpm-introduction-docs/html/gettingstarted.html >>> >>> Add it to here, and follow existing conventions: >>> https://github.com/droolsjbpm/drools/blob/master/drools-compiler/src/test/java/org/drools/compiler/integrationtests/CepEspTest.java >>> >>> Mark >>> On 11 Jul 2014, at 20:38, Kent Anderson wrote: >>> >>>> We have found a workaround that eliminates the leftover event (gone from Working Memory, but not from the JVM memory): >>>> >>>> The rule ?forget it ever happened? (seen below) causes the problem. Re-writing it to remove the check for RAISE in the LHS eliminated the memory leak. Of course, our application requires the check for RAISE, so it can be accomplished by manually querying working memory from the RHS. It?s ugly, but it resolved the issue. >>>> >>>> query existsRaise($id) >>>> $raise : MyEvent( eventState == EventState.RAISE, eventId == $id ) >>>> end >>>> >>>> rule "process clear" >>>> no-loop >>>> when >>>> $clear : MyEvent(eventState == EventState.CLEAR, $clearId : eventId) >>>> then >>>> QueryResults results = kcontext.getKieRuntime().getQueryResults( "existsRaise", $clearId ); >>>> if (results.size() == 0) { >>>> System.out.println( "Forwarding CLEAR(" + $clearId + ")" ); >>>> } else { >>>> System.out.println("Forgetting RAISE/CLEAR(" + $clearId + ")"); >>>> for (QueryResultsRow row : results){ >>>> MyEvent raise = (MyEvent) row.get ("$raise"); >>>> delete(raise); >>>> } >>>> } >>>> delete($clear); >>>> end >>>> >>>> This appears to be a similar situation to https://issues.jboss.org/browse/DROOLS-498. >>>> >>>> >>>> >>>> On Jul 10, 2014, at 3:54 PM, Kent Anderson wrote: >>>> >>>>> Correction: The original post did not include another rule that exists in the stream. The memory leak does not appear unless both rules are active in the stream. >>>>> >>>>> declare MyEvent >>>>> @role(event) >>>>> @timestamp(timestamp) >>>>> end >>>>> >>>>> /* If a RAISE is buffered for N seconds, send it out */ >>>>> rule "forward raise" >>>>> no-loop >>>>> duration (3s) >>>>> when >>>>> $raise : MyEvent(eventState == EventState.RAISE, $raiseId : eventId) >>>>> then >>>>> System.out.println("Forwarding RAISE(" + $raiseId + ")"); >>>>> delete($raise); >>>>> end >>>>> >>>>> /* When CLEAR, and buffered, clear them both out */ >>>>> rule "forget it ever happened" >>>>> no-loop >>>>> when >>>>> $clear : MyEvent(eventState == EventState.CLEAR, $clearId : eventId) >>>>> $raise : MyEvent(eventState == EventState.RAISE, eventId == $clearId) >>>>> then >>>>> System.out.println("Forgetting RAISE/CLEAR(" + $clearId + ")"); >>>>> delete($clear); >>>>> delete($raise); >>>>> end >>>>> >>>>> >>>>> On Jul 10, 2014, at 2:50 PM, Kent Anderson wrote: >>>>> >>>>>> The following rule produces a memory leak in Drools 6.1.0-SNAPSHOT: >>>>>> >>>>>> (Stream mode) >>>>>> >>>>>> declare MyEvent >>>>>> @role(event) >>>>>> @timestamp(timestamp) >>>>>> end >>>>>> >>>>>> /* If a RAISE is buffered for N seconds, send it out */ >>>>>> rule "forward raise" >>>>>> no-loop >>>>>> duration (3s) >>>>>> when >>>>>> $raise : MyEvent(eventState == EventState.RAISE, $raiseId : eventId) >>>>>> then >>>>>> System.out.println("Forwarding RAISE(" + $raiseId + ")"); >>>>>> delete($raise); >>>>>> end >>>>>> >>>>>> >>>>>> I see the rule fire as expected, printing out the message 3 seconds after the event is added into the session. While the event is waiting, I see a FactCount of 1 in the session. After the rule fires, the fact count goes to 0. However, using JVisualVm, querying the heap dump shows 1 instance of MyEvent, referenced by an EventFactHandle and several other Drools objects. >>>>>> >>>>>> Is this a bug, or is there a better way to write this rule so Drools? internals let go of the object after it is no longer a fact? >>>>>> >>>>>> >>>>>> >>>>>> >>>>>> _______________________________________________ >>>>>> rules-users mailing list >>>>>> rules-users at lists.jboss.org >>>>>> https://lists.jboss.org/mailman/listinfo/rules-users >>>>> >>>>> _______________________________________________ >>>>> rules-users mailing list >>>>> rules-users at lists.jboss.org >>>>> https://lists.jboss.org/mailman/listinfo/rules-users >>>> >>>> _______________________________________________ >>>> rules-users mailing list >>>> rules-users at lists.jboss.org >>>> https://lists.jboss.org/mailman/listinfo/rules-users >>> >>> _______________________________________________ >>> rules-users mailing list >>> rules-users at lists.jboss.org >>> https://lists.jboss.org/mailman/listinfo/rules-users >> >> >> >> _______________________________________________ >> rules-users mailing list >> rules-users at lists.jboss.org >> https://lists.jboss.org/mailman/listinfo/rules-users > > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140714/2a706683/attachment-0001.html From dsotty at gmail.com Mon Jul 14 21:11:20 2014 From: dsotty at gmail.com (Davide Sottara) Date: Tue, 15 Jul 2014 02:11:20 +0100 Subject: [rules-users] Workaround: EventFactHandle retained in memory after FactCount reaches 0 for temporal-based rule In-Reply-To: <96BEA5D6-9EB5-421C-9655-4F0298DC0163@psware.com> References: <5BD2B8A2-53FE-4319-AB57-48015E9D6A9F@psware.com> <749AF81F-EB48-458A-8457-735CA44DD7D6@psware.com> <053D2B3B-B818-4FF2-B001-94E16CF16171@codehaus.org> <01270600-46E6-4E40-8C62-59EE72914126@psware.com> <53C4471F.60007@gmail.com> <96BEA5D6-9EB5-421C-9655-4F0298DC0163@psware.com> Message-ID: <53C47FB8.8000900@gmail.com> Thanks, we'll look at it tomorrow Davide On 07/15/2014 02:09 AM, Kent Anderson wrote: > https://github.com/droolsjbpm/drools/pull/358 > > Per your advice, this pull request sets up the memory leak, but it > cannot verify that it exists without diving into internal drools > structures. > > Please let me know what else we can do to facilitate fixing this issue. > > > On Jul 14, 2014, at 2:09 PM, Davide Sottara wrote: > >> I'd need to check, but if you can put together the basics of the test >> case - the combination of rules and facts that causes the leak, >> we'll add the checks to ensure it's solved. Mark should have given >> you enough pointers to the style we use for test cases. >> We really appreciate your collaboration, and since this is a critical >> bug we'll fix it asap >> Thanks!! >> Davide >> >> On 07/14/2014 08:33 PM, Kent Anderson wrote: >>> Is there a reliable way to find an EventFactHandle instance buried >>> within the TupleEntryQueue's and the PhreakPropagationContext's? >>> >>> The multiple containers of interface/impl's makes it nearly >>> impossible to write a "good" test that can peak under the hood where >>> this memory leak is being held. If there is a recommended way to do >>> it, I'd be happy to do so. >>> >>> >>> >>> >>> >>> On Jul 13, 2014, at 7:31 PM, Mark Proctor >> > wrote: >>> >>>> Could you submit a unit test as a pull request? >>>> http://docs.jboss.org/drools/release/5.5.0.Final/droolsjbpm-introduction-docs/html/gettingstarted.html >>>> >>>> Add it to here, and follow existing conventions: >>>> https://github.com/droolsjbpm/drools/blob/master/drools-compiler/src/test/java/org/drools/compiler/integrationtests/CepEspTest.java >>>> >>>> Mark >>>> On 11 Jul 2014, at 20:38, Kent Anderson >>> > wrote: >>>> >>>>> We have found a workaround that eliminates the leftover event >>>>> (gone from Working Memory, but not from the JVM memory): >>>>> >>>>> The rule "forget it ever happened" (seen below) causes the >>>>> problem. Re-writing it to remove the check for RAISE in the LHS >>>>> eliminated the memory leak. Of course, our application requires >>>>> the check for RAISE, so it can be accomplished by manually >>>>> querying working memory from the RHS. It's ugly, but it resolved >>>>> the issue. >>>>> >>>>> query existsRaise($id) >>>>> $raise : MyEvent( eventState == EventState.RAISE, eventId == $id ) >>>>> end >>>>> >>>>> rule "process clear" >>>>> no-loop >>>>> when >>>>> $clear : MyEvent(eventState == EventState.CLEAR, $clearId : eventId) >>>>> then >>>>> QueryResults results = >>>>> kcontext.getKieRuntime().getQueryResults( "existsRaise", $clearId ); >>>>> if (results.size() == 0) { >>>>> System.out.println( "Forwarding CLEAR(" + $clearId + ")" ); >>>>> } else { >>>>> System.out.println("Forgetting RAISE/CLEAR(" + $clearId >>>>> + ")"); >>>>> for (QueryResultsRow row : results){ >>>>> MyEvent raise = (MyEvent) row.get ("$raise"); >>>>> delete(raise); >>>>> } >>>>> } >>>>> delete($clear); >>>>> end >>>>> >>>>> This appears to be a similar situation >>>>> to https://issues.jboss.org/browse/DROOLS-498. >>>>> >>>>> >>>>> >>>>> On Jul 10, 2014, at 3:54 PM, Kent Anderson >>>>> > wrote: >>>>> >>>>>> Correction: The original post did not include another rule that >>>>>> exists in the stream. The memory leak does not appear unless >>>>>> both rules are active in the stream. >>>>>> >>>>>> declare MyEvent >>>>>> @role(event) >>>>>> @timestamp(timestamp) >>>>>> end >>>>>> >>>>>> /* If a RAISE is buffered for N seconds, send it out */ >>>>>> rule "forward raise" >>>>>> no-loop >>>>>> duration (3s) >>>>>> when >>>>>> $raise : MyEvent(eventState == EventState.RAISE, $raiseId : eventId) >>>>>> then >>>>>> System.out.println("Forwarding RAISE(" + $raiseId + ")"); >>>>>> delete($raise); >>>>>> end >>>>>> >>>>>> /* When CLEAR, and buffered, clear them both out */ >>>>>> rule "forget it ever happened" >>>>>> no-loop >>>>>> when >>>>>> $clear : MyEvent(eventState == EventState.CLEAR, $clearId : eventId) >>>>>> $raise : MyEvent(eventState == EventState.RAISE, eventId == $clearId) >>>>>> then >>>>>> System.out.println("Forgetting RAISE/CLEAR(" + $clearId + ")"); >>>>>> delete($clear); >>>>>> delete($raise); >>>>>> end >>>>>> >>>>>> >>>>>> On Jul 10, 2014, at 2:50 PM, Kent Anderson >>>>>> > wrote: >>>>>> >>>>>>> The following rule produces a memory leak in Drools 6.1.0-SNAPSHOT: >>>>>>> >>>>>>> (Stream mode) >>>>>>> >>>>>>> declare MyEvent >>>>>>> @role(event) >>>>>>> @timestamp(timestamp) >>>>>>> end >>>>>>> >>>>>>> /* If a RAISE is buffered for N seconds, send it out */ >>>>>>> rule "forward raise" >>>>>>> no-loop >>>>>>> duration (3s) >>>>>>> when >>>>>>> $raise : MyEvent(eventState == EventState.RAISE, $raiseId : eventId) >>>>>>> then >>>>>>> System.out.println("Forwarding RAISE(" + $raiseId + ")"); >>>>>>> delete($raise); >>>>>>> end >>>>>>> >>>>>>> >>>>>>> I see the rule fire as expected, printing out the message 3 >>>>>>> seconds after the event is added into the session. >>>>>>> While the event is waiting, I see a >>>>>>> FactCount of 1 in the session. After the rule fires, the fact >>>>>>> count goes to 0. However, using JVisualVm, querying the heap >>>>>>> dump shows 1 instance of MyEvent, referenced by an >>>>>>> EventFactHandle and several other Drools objects. >>>>>>> >>>>>>> Is this a bug, or is there a better way to write this rule so >>>>>>> Drools' internals let go of the object after it is no longer a fact? >>>>>>> >>>>>>> >>>>>>> >>>>>>> >>>>>>> _______________________________________________ >>>>>>> rules-users mailing list >>>>>>> rules-users at lists.jboss.org >>>>>>> https://lists.jboss.org/mailman/listinfo/rules-users >>>>>> >>>>>> _______________________________________________ >>>>>> rules-users mailing list >>>>>> rules-users at lists.jboss.org >>>>>> https://lists.jboss.org/mailman/listinfo/rules-users >>>>> >>>>> _______________________________________________ >>>>> rules-users mailing list >>>>> rules-users at lists.jboss.org >>>>> https://lists.jboss.org/mailman/listinfo/rules-users >>>> >>>> _______________________________________________ >>>> rules-users mailing list >>>> rules-users at lists.jboss.org >>>> https://lists.jboss.org/mailman/listinfo/rules-users >>> >>> >>> >>> _______________________________________________ >>> rules-users mailing list >>> rules-users at lists.jboss.org >>> https://lists.jboss.org/mailman/listinfo/rules-users >> >> _______________________________________________ >> rules-users mailing list >> rules-users at lists.jboss.org >> https://lists.jboss.org/mailman/listinfo/rules-users > > > > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140715/2b2947e3/attachment-0001.html From jps at jps.ch Tue Jul 15 03:51:27 2014 From: jps at jps.ch (jps) Date: Tue, 15 Jul 2014 00:51:27 -0700 (PDT) Subject: [rules-users] drools-wb 6.1.0.CR2-wildfly - Decision table Message-ID: <1405410687196-4030354.post@n3.nabble.com> Hello, I can't create a Decision Table (Guided Editor) in drools-wb 6.1.0.CR2-wildfly. /(was working ok with CR1)/ Steps : - starting with a fresh install, no .niogit, no repostories/kie - upload 2 jars to repositoy - create a organisational unit - create a git repo for the new unit - create a project - add my 2 dependencies to the new project - create a decision table (guided editor) (don't use wizard) => the name of the decision table is listed in the project explorer panel but the main editor is empty ... no error log. (see screenshot) Tries to restart wildfly. No effect. -- View this message in context: http://drools.46999.n3.nabble.com/drools-wb-6-1-0-CR2-wildfly-Decision-table-tp4030354.html Sent from the Drools: User forum mailing list archive at Nabble.com. From andrea.pacifico.85 at gmail.com Tue Jul 15 05:19:13 2014 From: andrea.pacifico.85 at gmail.com (braveheart85) Date: Tue, 15 Jul 2014 02:19:13 -0700 (PDT) Subject: [rules-users] Problem when I cleaning the production memory. In-Reply-To: <1405352623354-4030341.post@n3.nabble.com> References: <1405352623354-4030341.post@n3.nabble.com> Message-ID: <1405415953243-4030355.post@n3.nabble.com> I suppose the problematic query is: query "Get Fixed BusinessEntities" $result : BusinessEntityData( queryable == true ) end What you means with increase and decrease node sharing? Sorry, maybe I didn't study very well the reteeo part of the documentation. -- View this message in context: http://drools.46999.n3.nabble.com/Problem-when-I-cleaning-the-production-memory-tp4030341p4030355.html Sent from the Drools: User forum mailing list archive at Nabble.com. From michael.anstis at gmail.com Tue Jul 15 06:55:54 2014 From: michael.anstis at gmail.com (Michael Anstis) Date: Tue, 15 Jul 2014 11:55:54 +0100 Subject: [rules-users] drools-wb 6.1.0.CR2-wildfly - Decision table In-Reply-To: <1405410687196-4030354.post@n3.nabble.com> References: <1405410687196-4030354.post@n3.nabble.com> Message-ID: Hi, I tried to replicate using your steps (but with a "simple" JAR, no parent, no other transitive dependencies etc) and it worked OK. We have a known issue with Wildfly CR2 (see https://issues.jboss.org/browse/GUVNOR-2108) that means if you try to use a JAR that then requires Maven to attempt to download additional artifacts it'll fail. The Guided Decision Table editor (as do most other editors) tries to load meta-data about the classes, fields etc available for authoring from the model associated with the project (i.e. all JAR dependencies etc). If this fails it's possible the editor will not open. Can you please:- (a) Try with the workaround mentioned in the JIRA (about org.jboss.netty vs io.netty) (b) Try with no JAR dependencies (i.e. create a data model in the workbench itself). Thanks, Mike On 15 July 2014 08:51, jps wrote: > Hello, > > I can't create a Decision Table (Guided Editor) in drools-wb > 6.1.0.CR2-wildfly. > /(was working ok with CR1)/ > > > Steps : > - starting with a fresh install, no .niogit, no repostories/kie > - upload 2 jars to repositoy > - create a organisational unit > - create a git repo for the new unit > - create a project > - add my 2 dependencies to the new project > - create a decision table (guided editor) (don't use wizard) > => the name of the decision table is listed in the project explorer panel > but the main editor is empty ... no error log. (see screenshot) > > Tries to restart wildfly. No effect. > > > > > > > > -- > View this message in context: > http://drools.46999.n3.nabble.com/drools-wb-6-1-0-CR2-wildfly-Decision-table-tp4030354.html > Sent from the Drools: User forum mailing list archive at Nabble.com. > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140715/13c1bc45/attachment.html From ufos at comcast.net Tue Jul 15 07:38:33 2014 From: ufos at comcast.net (J Rose) Date: Tue, 15 Jul 2014 04:38:33 -0700 (PDT) Subject: [rules-users] 5.6 Decision Table VLookup In-Reply-To: <1403034693037-4030086.post@n3.nabble.com> References: <1403019360914-4030082.post@n3.nabble.com> <1403022330863-4030084.post@n3.nabble.com> <1403034693037-4030086.post@n3.nabble.com> Message-ID: <1405424313249-4030357.post@n3.nabble.com> Re: [rules-users] 5.6 Decision Table VLookup. Can you tell me the status on this item please? I need to use a vlookup as well. -- View this message in context: http://drools.46999.n3.nabble.com/5-6-Decision-Table-VLookup-tp4030082p4030357.html Sent from the Drools: User forum mailing list archive at Nabble.com. From dsotty at gmail.com Tue Jul 15 07:51:07 2014 From: dsotty at gmail.com (Davide Sottara) Date: Tue, 15 Jul 2014 12:51:07 +0100 Subject: [rules-users] Problem when I cleaning the production memory. In-Reply-To: <1405415953243-4030355.post@n3.nabble.com> References: <1405352623354-4030341.post@n3.nabble.com> <1405415953243-4030355.post@n3.nabble.com> Message-ID: <53C515AB.3060003@gmail.com> What are you trying to do exactly when you "clear" the knowledge base? If you need to replace all the rules, I'd just create a new KB altogether.. facts would be reasserted into the new rules anyway. If you need to update some of the rules, Drools 5.x had the KnowledgeAgent for this purpose. To be fair, however, in 5.5 it still had some issues that were fixed in 5.6. I may be missing some of the requirements, though. Davide On 07/15/2014 10:19 AM, braveheart85 wrote: > I suppose the problematic query is: > > query "Get Fixed BusinessEntities" > $result : BusinessEntityData( queryable == true ) > end > > What you means with increase and decrease node sharing? > Sorry, maybe I didn't study very well the reteeo part of the documentation. > > > > -- > View this message in context: http://drools.46999.n3.nabble.com/Problem-when-I-cleaning-the-production-memory-tp4030341p4030355.html > Sent from the Drools: User forum mailing list archive at Nabble.com. > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users > From michael.anstis at gmail.com Tue Jul 15 07:53:51 2014 From: michael.anstis at gmail.com (Michael Anstis) Date: Tue, 15 Jul 2014 12:53:51 +0100 Subject: [rules-users] 5.6 Decision Table VLookup In-Reply-To: <1405424313249-4030357.post@n3.nabble.com> References: <1403019360914-4030082.post@n3.nabble.com> <1403022330863-4030084.post@n3.nabble.com> <1403034693037-4030086.post@n3.nabble.com> <1405424313249-4030357.post@n3.nabble.com> Message-ID: No progress. Community contributions always appreciated. http://docs.jboss.org/drools/release/6.0.1.Final/drools-docs/html/Welcome.html#gettingstarted On 15 July 2014 12:38, J Rose wrote: > Re: [rules-users] 5.6 Decision Table VLookup. Can you tell me the status > on > this item please? I need to use a vlookup as well. > > > > -- > View this message in context: > http://drools.46999.n3.nabble.com/5-6-Decision-Table-VLookup-tp4030082p4030357.html > Sent from the Drools: User forum mailing list archive at Nabble.com. > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140715/79c86eed/attachment.html From jps at jps.ch Tue Jul 15 08:55:53 2014 From: jps at jps.ch (jps) Date: Tue, 15 Jul 2014 05:55:53 -0700 (PDT) Subject: [rules-users] drools-wb 6.1.0.CR2-wildfly - Decision table In-Reply-To: References: <1405410687196-4030354.post@n3.nabble.com> Message-ID: <1405428953364-4030360.post@n3.nabble.com> You're right. Works with a simple JAR, no parent, no other deps. I've reviewed the packaging of my JARS and keep my DTO JAR with only DTO and no deps. I should have "Keep it simple s.. " Thank you -- View this message in context: http://drools.46999.n3.nabble.com/drools-wb-6-1-0-CR2-wildfly-Decision-table-tp4030354p4030360.html Sent from the Drools: User forum mailing list archive at Nabble.com. From andrea.pacifico.85 at gmail.com Tue Jul 15 09:29:30 2014 From: andrea.pacifico.85 at gmail.com (braveheart85) Date: Tue, 15 Jul 2014 06:29:30 -0700 (PDT) Subject: [rules-users] Problem when I cleaning the production memory. In-Reply-To: <53C515AB.3060003@gmail.com> References: <1405352623354-4030341.post@n3.nabble.com> <1405415953243-4030355.post@n3.nabble.com> <53C515AB.3060003@gmail.com> Message-ID: <1405430970870-4030361.post@n3.nabble.com> My users can apply a filter (query in Drools) and the result facts are tagged to be shown. Filters can be from a filter library or also directly written by users. I need to clear the production memory and set new knowledge (filter) each time in order to get filter result. First solution you propose is a bit problematic for me because i'd have to reinsert all facts inside the working memory but I don't keep these objects outside Drools. In my context facts are fixed while rules/queries are variables. I'd have to query Drools for all facts, then instantiate a new KnowledgeBase and finally reinsert all facts... What do you think? Thanks Andrea -- View this message in context: http://drools.46999.n3.nabble.com/Problem-when-I-cleaning-the-production-memory-tp4030341p4030361.html Sent from the Drools: User forum mailing list archive at Nabble.com. From kylekg93 at gmail.com Tue Jul 15 10:48:12 2014 From: kylekg93 at gmail.com (kylekg93 .) Date: Tue, 15 Jul 2014 10:48:12 -0400 Subject: [rules-users] Drools installation issues Message-ID: Hello, I'm having some issues starting up drools within Eclipse. I am running windows 8 with the Luna version of Eclipse. I have installed the GEF plugin and installed the DROOLS plugin using the update site. However, when I try and load examples, it appears I am missing dependencies/plugins. When I import anything in regards to KieServices, it fails. I also get an error that says 1.8 is not a valid language. Maybe I am just missing a big step, but I did follow the documentation. I would really appreciate some assistance. Like I said, maybe I've just missed a step... Thank you, Kyle Gillen -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140715/f26e6c63/attachment.html From ufos at comcast.net Tue Jul 15 10:54:33 2014 From: ufos at comcast.net (Jan Rose) Date: Tue, 15 Jul 2014 10:54:33 -0400 Subject: [rules-users] 5.6 Decision Table VLookup In-Reply-To: References: <1403019360914-4030082.post@n3.nabble.com> <1403022330863-4030084.post@n3.nabble.com> <1403034693037-4030086.post@n3.nabble.com> <1405424313249-4030357.post@n3.nabble.com> Message-ID: Hi Michael, Just a few questions: 1. Does it work in later versions of DROOLS? Which one? 2. If I put the lookups on the same sheet, will it work? Is it only because the lookups are on a separate sheet? Thanks, Jan Sent from my iPhone > On Jul 15, 2014, at 7:53 AM, Michael Anstis wrote: > > No progress. > > Community contributions always appreciated. > > http://docs.jboss.org/drools/release/6.0.1.Final/drools-docs/html/Welcome.html#gettingstarted > > >> On 15 July 2014 12:38, J Rose wrote: >> Re: [rules-users] 5.6 Decision Table VLookup. Can you tell me the status on >> this item please? I need to use a vlookup as well. >> >> >> >> -- >> View this message in context: http://drools.46999.n3.nabble.com/5-6-Decision-Table-VLookup-tp4030082p4030357.html >> Sent from the Drools: User forum mailing list archive at Nabble.com. >> _______________________________________________ >> rules-users mailing list >> rules-users at lists.jboss.org >> https://lists.jboss.org/mailman/listinfo/rules-users > > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140715/d011aa07/attachment-0001.html From michael.anstis at gmail.com Tue Jul 15 11:29:28 2014 From: michael.anstis at gmail.com (Michael Anstis) Date: Tue, 15 Jul 2014 16:29:28 +0100 Subject: [rules-users] 5.6 Decision Table VLookup In-Reply-To: References: <1403019360914-4030082.post@n3.nabble.com> <1403022330863-4030084.post@n3.nabble.com> <1403034693037-4030086.post@n3.nabble.com> <1405424313249-4030357.post@n3.nabble.com> Message-ID: It won't be fixed in any version; we've just not had time to investigate. You could try the VLOOKUP on the same sheet - my suspicion is that the issue is because it is on a different sheet.. but it's only a suspicion. On 15 July 2014 15:54, Jan Rose wrote: > Hi Michael, > Just a few questions: > 1. Does it work in later versions of DROOLS? Which one? > 2. If I put the lookups on the same sheet, will it work? Is it only > because the lookups are on a separate sheet? > > Thanks, > > Jan > > Sent from my iPhone > > On Jul 15, 2014, at 7:53 AM, Michael Anstis > wrote: > > No progress. > > Community contributions always appreciated. > > > http://docs.jboss.org/drools/release/6.0.1.Final/drools-docs/html/Welcome.html#gettingstarted > > > On 15 July 2014 12:38, J Rose wrote: > >> Re: [rules-users] 5.6 Decision Table VLookup. Can you tell me the >> status on >> this item please? I need to use a vlookup as well. >> >> >> >> -- >> View this message in context: >> http://drools.46999.n3.nabble.com/5-6-Decision-Table-VLookup-tp4030082p4030357.html >> Sent from the Drools: User forum mailing list archive at Nabble.com. >> _______________________________________________ >> rules-users mailing list >> rules-users at lists.jboss.org >> https://lists.jboss.org/mailman/listinfo/rules-users >> > > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users > > > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140715/5ac7e4df/attachment.html From sumantp at yahoo.com Tue Jul 15 13:46:04 2014 From: sumantp at yahoo.com (sumantp) Date: Tue, 15 Jul 2014 10:46:04 -0700 (PDT) Subject: [rules-users] Evaluations are increasingly slower In-Reply-To: <1405362046300-4030345.post@n3.nabble.com> References: <1405362046300-4030345.post@n3.nabble.com> Message-ID: <1405446364315-4030365.post@n3.nabble.com> For those that are interested in this topic, please see laune's response here - http://stackoverflow.com/questions/24746840/insertions-evaluations-are-progressively-slower-when-using-temporal-rule -- View this message in context: http://drools.46999.n3.nabble.com/Evaluations-are-increasingly-slower-tp4030345p4030365.html Sent from the Drools: User forum mailing list archive at Nabble.com. From dsotty at gmail.com Tue Jul 15 14:43:34 2014 From: dsotty at gmail.com (Davide Sottara) Date: Tue, 15 Jul 2014 19:43:34 +0100 Subject: [rules-users] Problem when I cleaning the production memory. In-Reply-To: <1405430970870-4030361.post@n3.nabble.com> References: <1405352623354-4030341.post@n3.nabble.com> <1405415953243-4030355.post@n3.nabble.com> <53C515AB.3060003@gmail.com> <1405430970870-4030361.post@n3.nabble.com> Message-ID: <53C57656.2070706@gmail.com> Conceptually you are right, but in practice, when you add a rule/query to the KBase all the available facts are propagated through the newly built piece of RETE. Since you clear all the rules first (which has some cost) and then you build a new set of rules, the effect is very similar - only, the engine will implicitly re-insert the objects for you. Now, a clean insertion has some costs (like the creation of the handles), so it would be interesting to benchmark the two alternatives. >From a developer's perspective, moving the objects from a session into another is as simple as this: for ( Object o : oldSession.getObjects() ) { newSession.insert( o ); } and if you can't (re)compile the source code, there is little that can be done to solve your problem. Unless there is a multi-threading issue, that is, you have different threads adding facts, removing rules/queries and adding the new ones. If that was the case, I would not be surprised since 5.5 was not thread safe. Davide On 07/15/2014 02:29 PM, braveheart85 wrote: > My users can apply a filter (query in Drools) and the result facts are tagged > to be shown. > Filters can be from a filter library or also directly written by users. > I need to clear the production memory and set new knowledge (filter) each > time in order to get filter result. > > First solution you propose is a bit problematic for me because i'd have to > reinsert all facts inside the working memory but I don't keep these objects > outside Drools. In my context facts are fixed while rules/queries are > variables. I'd have to query Drools for all facts, then instantiate a new > KnowledgeBase and finally reinsert all facts... > > What do you think? > > Thanks > Andrea > > > > -- > View this message in context: http://drools.46999.n3.nabble.com/Problem-when-I-cleaning-the-production-memory-tp4030341p4030361.html > Sent from the Drools: User forum mailing list archive at Nabble.com. > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users > From andrea.pacifico.85 at gmail.com Wed Jul 16 04:33:02 2014 From: andrea.pacifico.85 at gmail.com (braveheart85) Date: Wed, 16 Jul 2014 01:33:02 -0700 (PDT) Subject: [rules-users] Problem when I cleaning the production memory. In-Reply-To: <53C57656.2070706@gmail.com> References: <1405352623354-4030341.post@n3.nabble.com> <1405415953243-4030355.post@n3.nabble.com> <53C515AB.3060003@gmail.com> <1405430970870-4030361.post@n3.nabble.com> <53C57656.2070706@gmail.com> Message-ID: <1405499582729-4030367.post@n3.nabble.com> Yesterday I tried version 5.6. I have had a problem with the MVEL syntax. rule "RULE1" $result: PersonData( businessActivity.status == "CLOSED" ) end This rule that works in the version 5.5, now have a problem in version 5.6: unable to invoke method: org.titan.registry.filter.BusinessActivityData.getStatus: target of method is null The problem is that not all Person facts inside the working memory have a business activity. NullPointer would be quite correct but in version 5.5 the behaviour was different... Maybe I'm abusing of your kindness. Andrea -- View this message in context: http://drools.46999.n3.nabble.com/Problem-when-I-cleaning-the-production-memory-tp4030341p4030367.html Sent from the Drools: User forum mailing list archive at Nabble.com. From dsotty at gmail.com Wed Jul 16 04:54:44 2014 From: dsotty at gmail.com (Davide Sottara) Date: Wed, 16 Jul 2014 02:54:44 -0600 Subject: [rules-users] Problem when I cleaning the production memory. In-Reply-To: <1405499582729-4030367.post@n3.nabble.com> References: <1405352623354-4030341.post@n3.nabble.com> <1405415953243-4030355.post@n3.nabble.com> <53C515AB.3060003@gmail.com> <1405430970870-4030361.post@n3.nabble.com> <53C57656.2070706@gmail.com> <1405499582729-4030367.post@n3.nabble.com> Message-ID: Not checking for nulls is a debatable behavior :) In 5.6 you should be able to use the null safe accessor Business activity.!status == ... Which will be rewritten to do the check for you On Jul 16, 2014 4:33 AM, "braveheart85" wrote: > Yesterday I tried version 5.6. I have had a problem with the MVEL syntax. > > rule "RULE1" > $result: PersonData( businessActivity.status == "CLOSED" ) > end > > This rule that works in the version 5.5, now have a problem in version 5.6: > > unable to invoke method: > org.titan.registry.filter.BusinessActivityData.getStatus: target of method > is null > > The problem is that not all Person facts inside the working memory have a > business activity. NullPointer would be quite correct but in version 5.5 > the > behaviour was different... > > Maybe I'm abusing of your kindness. > Andrea > > > > -- > View this message in context: > http://drools.46999.n3.nabble.com/Problem-when-I-cleaning-the-production-memory-tp4030341p4030367.html > Sent from the Drools: User forum mailing list archive at Nabble.com. > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140716/1ef9b747/attachment.html From andrea.pacifico.85 at gmail.com Wed Jul 16 05:38:57 2014 From: andrea.pacifico.85 at gmail.com (braveheart85) Date: Wed, 16 Jul 2014 02:38:57 -0700 (PDT) Subject: [rules-users] Problem when I cleaning the production memory. In-Reply-To: References: <1405352623354-4030341.post@n3.nabble.com> <1405415953243-4030355.post@n3.nabble.com> <53C515AB.3060003@gmail.com> <1405430970870-4030361.post@n3.nabble.com> <53C57656.2070706@gmail.com> <1405499582729-4030367.post@n3.nabble.com> Message-ID: <1405503537095-4030369.post@n3.nabble.com> I have tried your hint and i got: query "dis" $result : PersonData( businessActivity.!status == "CLOSED") end [48,38]: [ERR 101] Line 48:38 no viable alternative at input '.' in query [0,0]: Parser returned a null Package -- View this message in context: http://drools.46999.n3.nabble.com/Problem-when-I-cleaning-the-production-memory-tp4030341p4030369.html Sent from the Drools: User forum mailing list archive at Nabble.com. From dsotty at gmail.com Wed Jul 16 05:42:03 2014 From: dsotty at gmail.com (Davide Sottara) Date: Wed, 16 Jul 2014 03:42:03 -0600 Subject: [rules-users] Problem when I cleaning the production memory. In-Reply-To: <1405503537095-4030369.post@n3.nabble.com> References: <1405352623354-4030341.post@n3.nabble.com> <1405415953243-4030355.post@n3.nabble.com> <53C515AB.3060003@gmail.com> <1405430970870-4030361.post@n3.nabble.com> <53C57656.2070706@gmail.com> <1405499582729-4030367.post@n3.nabble.com> <1405503537095-4030369.post@n3.nabble.com> Message-ID: Oops, it's !., not .! On Jul 16, 2014 5:39 AM, "braveheart85" wrote: > I have tried your hint and i got: > > query "dis" > $result : PersonData( businessActivity.!status == "CLOSED") > end > > [48,38]: [ERR 101] Line 48:38 no viable alternative at input '.' in query > [0,0]: Parser returned a null Package > > > > -- > View this message in context: > http://drools.46999.n3.nabble.com/Problem-when-I-cleaning-the-production-memory-tp4030341p4030369.html > Sent from the Drools: User forum mailing list archive at Nabble.com. > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140716/995ba8db/attachment.html From andrea.pacifico.85 at gmail.com Wed Jul 16 06:19:42 2014 From: andrea.pacifico.85 at gmail.com (braveheart85) Date: Wed, 16 Jul 2014 03:19:42 -0700 (PDT) Subject: [rules-users] Problem when I cleaning the production memory. In-Reply-To: References: <1405352623354-4030341.post@n3.nabble.com> <1405415953243-4030355.post@n3.nabble.com> <53C515AB.3060003@gmail.com> <1405430970870-4030361.post@n3.nabble.com> <53C57656.2070706@gmail.com> <1405499582729-4030367.post@n3.nabble.com> <1405503537095-4030369.post@n3.nabble.com> Message-ID: <1405505982824-4030371.post@n3.nabble.com> Ok, now the query works. However I have noticed that when that rule with (. instead of !.) fails, Drools can't remove the rule in the cleaning phase like the version 5.5.0. I have found these logs in my console: 09:47:31,989 INFO [http-bio-8080-exec-8][WorkingMemoryConsoleLogger:114] BEFORE PACKAGE ADDED package: "org.titan.memory.drools.command.custom" 09:47:31,990 INFO [http-bio-8080-exec-8][WorkingMemoryConsoleLogger:114] BEFORE PACKAGE ADDED package: "org.titan.registry.filter" 09:47:31,992 INFO [http-bio-8080-exec-8][WorkingMemoryConsoleLogger:114] BEFORE RULE ADDED package: "org.titan.memory.drools.command.custom" rule: "dis" then: java.lang.RuntimeException: cannot invoke getter: getBusinessActivity .... then: 09:47:32,373 INFO [http-bio-8080-exec-8][WorkingMemoryConsoleLogger:114] BEFORE PACKAGE REMOVED package: "org.titan.memory.drools.command.custom" 09:47:32,373 INFO [http-bio-8080-exec-8][WorkingMemoryConsoleLogger:114] BEFORE RULE REMOVED package: "org.titan.memory.drools.command.custom" rule: "dis" and finally: Caused by: java.lang.NullPointerException at org.drools.reteoo.ReteooBuilder.removeRule(ReteooBuilder.java:252) at org.drools.reteoo.ReteooRuleBase.removeRule(ReteooRuleBase.java:469) at org.drools.common.AbstractRuleBase.removeRule(AbstractRuleBase.java:1109) at org.drools.common.AbstractRuleBase.removePackage(AbstractRuleBase.java:1027) at org.drools.impl.KnowledgeBaseImpl.removeKnowledgePackage(KnowledgeBaseImpl.java:210) at org.titan.frontend.memory.drools.DroolsEngine._clearKnowledge(DroolsEngine.java:316) I don't have a log like AFTER RULE ADDED ... "dis". However Drools try to remove "dis" when i execute another query after the exception have raised. This is the last question. I promise! Andrea -- View this message in context: http://drools.46999.n3.nabble.com/Problem-when-I-cleaning-the-production-memory-tp4030341p4030371.html Sent from the Drools: User forum mailing list archive at Nabble.com. From rajeswari at raremile.com Wed Jul 16 09:09:44 2014 From: rajeswari at raremile.com (Rajeswari) Date: Wed, 16 Jul 2014 06:09:44 -0700 (PDT) Subject: [rules-users] Caching in Drools 5.5.0 Message-ID: <1405516184359-4030374.post@n3.nabble.com> We are using Drools 5.5.0 and have created Models and Rules via the Workbench. >From our application code, we create model classes and the models are then modified depending on the rules configured and the modified objects are used further in our code. Example: RuleModel - is a model containing fieldName and resultList. Several rules are written to return an appropriate resultList depending on the value of the fieldName. We would like to implement Caching here. At several points within our application, we create these RuleModel with sometimes the values of the fieldName being the same - How can we cache the RuleModel (after it gets modified by applying the rules for the first time) Eg: RuleModel with value of fieldName as F1 RuleModel with value of fieldName as F2 all needs to be in cache. Anytime the application needs the object with F1 for the next time, we would use that insteading of having to apply the rules again. We will further put it in a feature to refresh this cache at regular intervals. -- View this message in context: http://drools.46999.n3.nabble.com/Caching-in-Drools-5-5-0-tp4030374.html Sent from the Drools: User forum mailing list archive at Nabble.com. From sumitdhaniya at gmail.com Wed Jul 16 09:27:53 2014 From: sumitdhaniya at gmail.com (Sumit Dhaniya) Date: Wed, 16 Jul 2014 06:27:53 -0700 (PDT) Subject: [rules-users] condition altered while unmarshalling a drl to guided rule Message-ID: <1405517273744-4030375.post@n3.nabble.com> I created a guided rule and when I open it again some conditions which I wrote using the --Text-- option from drop down are altered. It seems the issue is only with unmarshalling because condition remains unaltered in rdrl file until you save it again so everything is fine if you change it every time you make any change to the rule or save it. Below is the scenario to reproduce(use 6.1CR2) :- 1) Made a Maven-ized JAR containing the following classes: package com.demo; import java.util.List; public class Foo { private List myList; public List getMyList() { return myList; } public void setMyList( List myList ) { this.myList = myList; } } public class Bar { private String myString; public String getMyString() { return myString; } public void setMyString( String myString ) { this.myString = myString; } } 2) Uploaded JAR to the workbench's Artifact Repository 3) Added a project dependency on this artifact 4) Added an Import Suggestion for java.util.List 5) Created a new Guided Rule 6) Imported Foo,Bar and java.util.List (Config tab) 7) Created the following rule: package org.mortgages; import java.lang.Number; import java.util.List; import org.anstis.MyListClass; rule "r1" dialect "mvel" when $foo : Foo() Bar : Bar( myString == $foo.myList.get(1)) then end 8) Validate rule :- will be vaidated 9) Save and close rule Now when rule will be opened again this get(1) will change to get moreover while creating rule get(index) method is not specified in dropdown so selected -- Text -- option to create the rule. DRL remains in valid format until overwritten in another save. -- View this message in context: http://drools.46999.n3.nabble.com/condition-altered-while-unmarshalling-a-drl-to-guided-rule-tp4030375.html Sent from the Drools: User forum mailing list archive at Nabble.com. From michael.anstis at gmail.com Wed Jul 16 11:40:04 2014 From: michael.anstis at gmail.com (Michael Anstis) Date: Wed, 16 Jul 2014 16:40:04 +0100 Subject: [rules-users] condition altered while unmarshalling a drl to guided rule In-Reply-To: <1405517273744-4030375.post@n3.nabble.com> References: <1405517273744-4030375.post@n3.nabble.com> Message-ID: https://issues.jboss.org/browse/GUVNOR-2109 Working on a fix. On 16 July 2014 14:27, Sumit Dhaniya wrote: > I created a guided rule and when I open it again some conditions which I > wrote using the --Text-- option from drop down are altered. > It seems the issue is only with unmarshalling because condition remains > unaltered in rdrl file until you save it again so everything is fine if you > change it every time you make any change to the rule or save it. > > Below is the scenario to reproduce(use 6.1CR2) :- > > 1) Made a Maven-ized JAR containing the following classes: > > package com.demo; > > import java.util.List; > > public class Foo { > > private List myList; > > public List getMyList() { > return myList; > } > > public void setMyList( List myList ) { > this.myList = myList; > } > } > > public class Bar { > > private String myString; > > public String getMyString() { > return myString; > } > > public void setMyString( String myString ) { > this.myString = myString; > } > } > > 2) Uploaded JAR to the workbench's Artifact Repository > > 3) Added a project dependency on this artifact > > 4) Added an Import Suggestion for java.util.List > > 5) Created a new Guided Rule > > 6) Imported Foo,Bar and java.util.List (Config tab) > > 7) Created the following rule: > > package org.mortgages; > > import java.lang.Number; > import java.util.List; > import org.anstis.MyListClass; > > rule "r1" > dialect "mvel" > when > $foo : Foo() > Bar : Bar( myString == $foo.myList.get(1)) > then > end > > 8) Validate rule :- will be vaidated > 9) Save and close rule > > Now when rule will be opened again this get(1) will change to get moreover > while creating rule get(index) method is not specified in dropdown so > selected -- Text -- option to create the rule. > > DRL remains in valid format until overwritten in another save. > > > > -- > View this message in context: > http://drools.46999.n3.nabble.com/condition-altered-while-unmarshalling-a-drl-to-guided-rule-tp4030375.html > Sent from the Drools: User forum mailing list archive at Nabble.com. > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140716/bf0682c6/attachment.html From bhavnaa.shetty at gmail.com Wed Jul 16 11:42:44 2014 From: bhavnaa.shetty at gmail.com (bjs) Date: Wed, 16 Jul 2014 08:42:44 -0700 (PDT) Subject: [rules-users] Split in rule flow in drools Message-ID: <1405525364527-4030378.post@n3.nabble.com> Hello everyone, I have doubt about the use of split in the rule-flow. I created a split with constraint1 and constraint2. But even if condition in constraint2 is fulfilled by a fact it fires the rules under constraint1 branch if the rules fulfill the when clause under constraint1 branch. This should not be the case cause the split should mean the rules in the branch under constraint2 should be fired. -- View this message in context: http://drools.46999.n3.nabble.com/Split-in-rule-flow-in-drools-tp4030378.html Sent from the Drools: User forum mailing list archive at Nabble.com. From bhavnaa.shetty at gmail.com Wed Jul 16 11:53:56 2014 From: bhavnaa.shetty at gmail.com (bjs) Date: Wed, 16 Jul 2014 08:53:56 -0700 (PDT) Subject: [rules-users] On what basis to divided rules in different drls Message-ID: <1405526036383-4030379.post@n3.nabble.com> Hello, I am new to Drools rule. So i wanted know on what basis do we divide rules in different drl files. It is that the rules related to a praticular fact should be within a single drl file? -- View this message in context: http://drools.46999.n3.nabble.com/On-what-basis-to-divided-rules-in-different-drls-tp4030379.html Sent from the Drools: User forum mailing list archive at Nabble.com. From kent.anderson at psware.com Wed Jul 16 12:33:06 2014 From: kent.anderson at psware.com (Kent Anderson) Date: Wed, 16 Jul 2014 09:33:06 -0700 Subject: [rules-users] Workaround: EventFactHandle retained in memory after FactCount reaches 0 for temporal-based rule In-Reply-To: <53C47FB8.8000900@gmail.com> References: <5BD2B8A2-53FE-4319-AB57-48015E9D6A9F@psware.com> <749AF81F-EB48-458A-8457-735CA44DD7D6@psware.com> <053D2B3B-B818-4FF2-B001-94E16CF16171@codehaus.org> <01270600-46E6-4E40-8C62-59EE72914126@psware.com> <53C4471F.60007@gmail.com> <96BEA5D6-9EB5-421C-9655-4F0298DC0163@psware.com> <53C47FB8.8000900@gmail.com> Message-ID: This issue has been resolved by https://issues.jboss.org/browse/DROOLS-516 (a discussion in the comments in https://issues.jboss.org/browse/DROOLS-498 is relevant, as this issue was originally reported as related to DROOLS-498). On Jul 14, 2014, at 6:11 PM, Davide Sottara wrote: > Thanks, we'll look at it tomorrow > Davide > > On 07/15/2014 02:09 AM, Kent Anderson wrote: >> https://github.com/droolsjbpm/drools/pull/358 >> >> Per your advice, this pull request sets up the memory leak, but it cannot verify that it exists without diving into internal drools structures. >> >> Please let me know what else we can do to facilitate fixing this issue. >> >> >> On Jul 14, 2014, at 2:09 PM, Davide Sottara wrote: >> >>> I'd need to check, but if you can put together the basics of the test case - the combination of rules and facts that causes the leak, >>> we'll add the checks to ensure it's solved. Mark should have given you enough pointers to the style we use for test cases. >>> We really appreciate your collaboration, and since this is a critical bug we'll fix it asap >>> Thanks!! >>> Davide >>> >>> On 07/14/2014 08:33 PM, Kent Anderson wrote: >>>> Is there a reliable way to find an EventFactHandle instance buried within the TupleEntryQueue?s and the PhreakPropagationContext?s? >>>> >>>> The multiple containers of interface/impl?s makes it nearly impossible to write a ?good? test that can peak under the hood where this memory leak is being held. If there is a recommended way to do it, I?d be happy to do so. >>>> >>>> >>>> >>>> >>>> >>>> On Jul 13, 2014, at 7:31 PM, Mark Proctor wrote: >>>> >>>>> Could you submit a unit test as a pull request? >>>>> http://docs.jboss.org/drools/release/5.5.0.Final/droolsjbpm-introduction-docs/html/gettingstarted.html >>>>> >>>>> Add it to here, and follow existing conventions: >>>>> https://github.com/droolsjbpm/drools/blob/master/drools-compiler/src/test/java/org/drools/compiler/integrationtests/CepEspTest.java >>>>> >>>>> Mark >>>>> On 11 Jul 2014, at 20:38, Kent Anderson wrote: >>>>> >>>>>> We have found a workaround that eliminates the leftover event (gone from Working Memory, but not from the JVM memory): >>>>>> >>>>>> The rule ?forget it ever happened? (seen below) causes the problem. Re-writing it to remove the check for RAISE in the LHS eliminated the memory leak. Of course, our application requires the check for RAISE, so it can be accomplished by manually querying working memory from the RHS. It?s ugly, but it resolved the issue. >>>>>> >>>>>> query existsRaise($id) >>>>>> $raise : MyEvent( eventState == EventState.RAISE, eventId == $id ) >>>>>> end >>>>>> >>>>>> rule "process clear" >>>>>> no-loop >>>>>> when >>>>>> $clear : MyEvent(eventState == EventState.CLEAR, $clearId : eventId) >>>>>> then >>>>>> QueryResults results = kcontext.getKieRuntime().getQueryResults( "existsRaise", $clearId ); >>>>>> if (results.size() == 0) { >>>>>> System.out.println( "Forwarding CLEAR(" + $clearId + ")" ); >>>>>> } else { >>>>>> System.out.println("Forgetting RAISE/CLEAR(" + $clearId + ")"); >>>>>> for (QueryResultsRow row : results){ >>>>>> MyEvent raise = (MyEvent) row.get ("$raise"); >>>>>> delete(raise); >>>>>> } >>>>>> } >>>>>> delete($clear); >>>>>> end >>>>>> >>>>>> This appears to be a similar situation to https://issues.jboss.org/browse/DROOLS-498. >>>>>> >>>>>> >>>>>> >>>>>> On Jul 10, 2014, at 3:54 PM, Kent Anderson wrote: >>>>>> >>>>>>> Correction: The original post did not include another rule that exists in the stream. The memory leak does not appear unless both rules are active in the stream. >>>>>>> >>>>>>> declare MyEvent >>>>>>> @role(event) >>>>>>> @timestamp(timestamp) >>>>>>> end >>>>>>> >>>>>>> /* If a RAISE is buffered for N seconds, send it out */ >>>>>>> rule "forward raise" >>>>>>> no-loop >>>>>>> duration (3s) >>>>>>> when >>>>>>> >>>>>>> $raise : MyEvent(eventState == EventState.RAISE, $raiseId : eventId) >>>>>>> then >>>>>>> >>>>>>> System.out.println("Forwarding RAISE(" + $raiseId + ")"); >>>>>>> >>>>>>> delete($raise); >>>>>>> end >>>>>>> >>>>>>> /* When CLEAR, and buffered, clear them both out */ >>>>>>> rule "forget it ever happened" >>>>>>> no-loop >>>>>>> when >>>>>>> >>>>>>> $clear : MyEvent(eventState == EventState.CLEAR, $clearId : eventId) >>>>>>> >>>>>>> $raise : MyEvent(eventState == EventState.RAISE, eventId == $clearId) >>>>>>> then >>>>>>> >>>>>>> System.out.println("Forgetting RAISE/CLEAR(" + $clearId + ")"); >>>>>>> >>>>>>> delete($clear); >>>>>>> >>>>>>> delete($raise); >>>>>>> end >>>>>>> >>>>>>> >>>>>>> On Jul 10, 2014, at 2:50 PM, Kent Anderson wrote: >>>>>>> >>>>>>>> The following rule produces a memory leak in Drools 6.1.0-SNAPSHOT: >>>>>>>> >>>>>>>> (Stream mode) >>>>>>>> >>>>>>>> declare MyEvent >>>>>>>> @role(event) >>>>>>>> @timestamp(timestamp) >>>>>>>> end >>>>>>>> >>>>>>>> /* If a RAISE is buffered for N seconds, send it out */ >>>>>>>> rule "forward raise" >>>>>>>> no-loop >>>>>>>> duration (3s) >>>>>>>> when >>>>>>>> $raise : MyEvent(eventState == EventState.RAISE, $raiseId : eventId) >>>>>>>> then >>>>>>>> System.out.println("Forwarding RAISE(" + $raiseId + ")"); >>>>>>>> delete($raise); >>>>>>>> end >>>>>>>> >>>>>>>> >>>>>>>> I see the rule fire as expected, printing out the message 3 seconds after the event is added into the session. While the event is waiting, I see a FactCount of 1 in the session. After the rule fires, the fact count goes to 0. However, using JVisualVm, querying the heap dump shows 1 instance of MyEvent, referenced by an EventFactHandle and several other Drools objects. >>>>>>>> >>>>>>>> Is this a bug, or is there a better way to write this rule so Drools? internals let go of the object after it is no longer a fact? >>>>>>>> >>>>>>>> >>>>>>>> >>>>>>>> >>>>>>>> _______________________________________________ >>>>>>>> rules-users mailing list >>>>>>>> rules-users at lists.jboss.org >>>>>>>> https://lists.jboss.org/mailman/listinfo/rules-users >>>>>>> >>>>>>> _______________________________________________ >>>>>>> rules-users mailing list >>>>>>> rules-users at lists.jboss.org >>>>>>> https://lists.jboss.org/mailman/listinfo/rules-users >>>>>> >>>>>> _______________________________________________ >>>>>> rules-users mailing list >>>>>> rules-users at lists.jboss.org >>>>>> https://lists.jboss.org/mailman/listinfo/rules-users >>>>> >>>>> _______________________________________________ >>>>> rules-users mailing list >>>>> rules-users at lists.jboss.org >>>>> https://lists.jboss.org/mailman/listinfo/rules-users >>>> >>>> >>>> >>>> _______________________________________________ >>>> rules-users mailing list >>>> rules-users at lists.jboss.org >>>> https://lists.jboss.org/mailman/listinfo/rules-users >>> >>> _______________________________________________ >>> rules-users mailing list >>> rules-users at lists.jboss.org >>> https://lists.jboss.org/mailman/listinfo/rules-users >> >> >> >> _______________________________________________ >> rules-users mailing list >> rules-users at lists.jboss.org >> https://lists.jboss.org/mailman/listinfo/rules-users > > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140716/71f61656/attachment-0001.html From ufos at comcast.net Wed Jul 16 23:49:33 2014 From: ufos at comcast.net (J Rose) Date: Wed, 16 Jul 2014 20:49:33 -0700 (PDT) Subject: [rules-users] Decision table max rows Message-ID: <1405568973696-4030382.post@n3.nabble.com> What is the maximum number of rows you can use in a decision table? I need to use over 12,000 rows but seem to get an out of memory error for even 1,000 rows. I already increased the memory used. What are my options if I need to lookup values for that many rows? -- View this message in context: http://drools.46999.n3.nabble.com/Decision-table-max-rows-tp4030382.html Sent from the Drools: User forum mailing list archive at Nabble.com. From michael.anstis at gmail.com Thu Jul 17 05:20:54 2014 From: michael.anstis at gmail.com (Michael Anstis) Date: Thu, 17 Jul 2014 10:20:54 +0100 Subject: [rules-users] Decision table max rows In-Reply-To: <1405568973696-4030382.post@n3.nabble.com> References: <1405568973696-4030382.post@n3.nabble.com> Message-ID: Simplistically, split your decision table into smaller ones. To answer your question more fully; the maximum number of rows that can exist in a XLS is (IIRC) 65535. That said; how many can be processed on a given computer, depends on how much RAM has been associated with the JVM heap and how many decision table columns are on a row. With kind regards, Mike On 17 July 2014 04:49, J Rose wrote: > What is the maximum number of rows you can use in a decision table? I need > to use over 12,000 rows but seem to get an out of memory error for even > 1,000 rows. I already increased the memory used. > What are my options if I need to lookup values for that many rows? > > > > -- > View this message in context: > http://drools.46999.n3.nabble.com/Decision-table-max-rows-tp4030382.html > Sent from the Drools: User forum mailing list archive at Nabble.com. > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140717/d6913df2/attachment.html From shameerind at gmail.com Thu Jul 17 05:39:30 2014 From: shameerind at gmail.com (Shameer E S) Date: Thu, 17 Jul 2014 15:09:30 +0530 Subject: [rules-users] Processing xml with control characters in droolserver Message-ID: Hi, I am sending xml to initiate rule execution in drools server 5.4. When there is control character in the xml, it is failing with following error, is there any way to overcome this? 16 Jul 2014 00:03:28,852 ERROR [org.apache.camel.processor.DefaultErrorHandler] (http--0.0.0.0-8080-239) Failed delivery for exchangeId: ID-svl-prod-prwf04-juniper-net-51091-1404737660521-0-3260214. Exhausted after delivery attempt: 1 caught: com.thoughtworks.xstream.converters.ConversionException: : Illegal character ((CTRL-CHAR, code 8)) [note: in XML 1.1, it could be included via entity expansion] at [row,col {unknown-source}]: [30,126] : : Illegal character ((CTRL-CHAR, code 8)) [note: in XML 1.1, it could be included via entity expansion] at [row,col {unknown-source}]: [30,126] ---- Debugging information ---- message : : Illegal character ((CTRL-CHAR, code 8)) [note: in XML 1.1, it could be included via entity expansion] at [row,col {unknown-source}]: [30,126] cause-exception : com.thoughtworks.xstream.io.StreamException cause-message : : Illegal character ((CTRL-CHAR, code 8)) [note: in XML 1.1, it could be included via entity expansion] at [row,col {unknown-source}]: [30,126] class : java.lang.String required-type : java.lang.String converter-type : com.thoughtworks.xstream.converters.SingleValueConverterWrapper wrapped-converter : com.thoughtworks.xstream.converters.basic.StringConverter path : /batch-execution/set-global[7]/map/entry[50]/string[2] line number : 2 class[1] : java.util.HashMap converter-type[1] : com.thoughtworks.xstream.converters.collections.MapConverter class[2] : org.drools.command.runtime.SetGlobalCommand converter-type[2] : org.drools.runtime.help.impl.XStreamXML$SetGlobalConverter class[3] : org.drools.command.runtime.BatchExecutionCommandImpl converter-type[3] : com.thoughtworks.xstream.converters.reflection.ReflectionConverter version : null Thanks & Regards, Shameer -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140717/adb0b6e8/attachment.html From michael.anstis at gmail.com Thu Jul 17 11:56:16 2014 From: michael.anstis at gmail.com (Michael Anstis) Date: Thu, 17 Jul 2014 16:56:16 +0100 Subject: [rules-users] condition altered while unmarshalling a drl to guided rule In-Reply-To: References: <1405517273744-4030375.post@n3.nabble.com> Message-ID: Fixed. 6.2.0-SNAPSHOT (master branch) has improved Expression handling. 6.1.0.Final will include the fix for this issue; but other aspects of Expression handling are not as developed as 6.2.0-SNAPSHOT. On 16 July 2014 16:40, Michael Anstis wrote: > https://issues.jboss.org/browse/GUVNOR-2109 > > Working on a fix. > > > On 16 July 2014 14:27, Sumit Dhaniya wrote: > >> I created a guided rule and when I open it again some conditions which I >> wrote using the --Text-- option from drop down are altered. >> It seems the issue is only with unmarshalling because condition remains >> unaltered in rdrl file until you save it again so everything is fine if >> you >> change it every time you make any change to the rule or save it. >> >> Below is the scenario to reproduce(use 6.1CR2) :- >> >> 1) Made a Maven-ized JAR containing the following classes: >> >> package com.demo; >> >> import java.util.List; >> >> public class Foo { >> >> private List myList; >> >> public List getMyList() { >> return myList; >> } >> >> public void setMyList( List myList ) { >> this.myList = myList; >> } >> } >> >> public class Bar { >> >> private String myString; >> >> public String getMyString() { >> return myString; >> } >> >> public void setMyString( String myString ) { >> this.myString = myString; >> } >> } >> >> 2) Uploaded JAR to the workbench's Artifact Repository >> >> 3) Added a project dependency on this artifact >> >> 4) Added an Import Suggestion for java.util.List >> >> 5) Created a new Guided Rule >> >> 6) Imported Foo,Bar and java.util.List (Config tab) >> >> 7) Created the following rule: >> >> package org.mortgages; >> >> import java.lang.Number; >> import java.util.List; >> import org.anstis.MyListClass; >> >> rule "r1" >> dialect "mvel" >> when >> $foo : Foo() >> Bar : Bar( myString == $foo.myList.get(1)) >> then >> end >> >> 8) Validate rule :- will be vaidated >> 9) Save and close rule >> >> Now when rule will be opened again this get(1) will change to get moreover >> while creating rule get(index) method is not specified in dropdown so >> selected -- Text -- option to create the rule. >> >> DRL remains in valid format until overwritten in another save. >> >> >> >> -- >> View this message in context: >> http://drools.46999.n3.nabble.com/condition-altered-while-unmarshalling-a-drl-to-guided-rule-tp4030375.html >> Sent from the Drools: User forum mailing list archive at Nabble.com. >> _______________________________________________ >> rules-users mailing list >> rules-users at lists.jboss.org >> https://lists.jboss.org/mailman/listinfo/rules-users >> > > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140717/d16721e8/attachment.html From bhavnaa.shetty at gmail.com Thu Jul 17 13:26:19 2014 From: bhavnaa.shetty at gmail.com (bjs) Date: Thu, 17 Jul 2014 10:26:19 -0700 (PDT) Subject: [rules-users] Activation-group doubt Message-ID: <1405617979573-4030388.post@n3.nabble.com> As far as i understand the activation group fires only one rules for a given group. But does it run once for each fact inserted or only just once. for example i have activation group act1 with 3 rules: rule1,rule2,rule3 and inserted 4 facts . But the rule1 runs only once , i wanted rule1 to run for each of the 4 facts inserted. -- View this message in context: http://drools.46999.n3.nabble.com/Activation-group-doubt-tp4030388.html Sent from the Drools: User forum mailing list archive at Nabble.com. From andrea.pacifico.85 at gmail.com Fri Jul 18 09:39:01 2014 From: andrea.pacifico.85 at gmail.com (braveheart85) Date: Fri, 18 Jul 2014 06:39:01 -0700 (PDT) Subject: [rules-users] Problem when I cleaning the production memory. In-Reply-To: <1405505982824-4030371.post@n3.nabble.com> References: <1405352623354-4030341.post@n3.nabble.com> <1405415953243-4030355.post@n3.nabble.com> <53C515AB.3060003@gmail.com> <1405430970870-4030361.post@n3.nabble.com> <53C57656.2070706@gmail.com> <1405499582729-4030367.post@n3.nabble.com> <1405503537095-4030369.post@n3.nabble.com> <1405505982824-4030371.post@n3.nabble.com> Message-ID: <1405690741245-4030396.post@n3.nabble.com> Finally I resolve my issues destroing the Knowledge Base and then re-create it when the problem occurs. I confirm that version 5.6 is more stable than 5.5. In 5.6 i don't have the non-deterministic behaviour anymore whereby it's impossible to remove a knowledge package. In 5.6, however, the same issue is still present when i add a knowledge package in the knowledge base that generate a nullpointerexception when matching with facts already present inside the session. In 5.6 the issue can be accurately examined because have a deterministic occurrences! The problem seems to be: * KnowledgeBase fail to add the new package due to NullPointerException. * When the cleaning is called KnowledgeBase want remove the package that previously it couldn't add. Probably I have had a lot of problems because I'm not doing things in the right way. I hope this experience can help someone. -- View this message in context: http://drools.46999.n3.nabble.com/Problem-when-I-cleaning-the-production-memory-tp4030341p4030396.html Sent from the Drools: User forum mailing list archive at Nabble.com. From skip.cole at gmail.com Mon Jul 21 10:44:10 2014 From: skip.cole at gmail.com (skipatdb) Date: Mon, 21 Jul 2014 07:44:10 -0700 (PDT) Subject: [rules-users] Migration to Drools 6 and Workbench from Guvnor 5.5? In-Reply-To: <1392229969793-4028102.post@n3.nabble.com> References: <1392057599571-4028040.post@n3.nabble.com> <1392061440541-4028042.post@n3.nabble.com> <1392075119671-4028049.post@n3.nabble.com> <1392224557958-4028097.post@n3.nabble.com> <1392229969793-4028102.post@n3.nabble.com> Message-ID: <1405953850391-4030409.post@n3.nabble.com> Hi, This thread kind of trails off on Feb 12, 2014. Did you finish your migration? We are about to start the same, so we are very curious about how this all works. I imagine that many people are. Also, I can't currently build the migration tool. When trying to build it from the github code I keep getting the message "Failure to find org.kie:kie-parent-with-dependencies:pom:6.2.0-SNAPSHOT". Does anyone has any advice on how to get passed that? Thanks, Skip -- View this message in context: http://drools.46999.n3.nabble.com/Migration-to-Drools-6-and-Workbench-from-Guvnor-5-5-tp4028040p4030409.html Sent from the Drools: User forum mailing list archive at Nabble.com. From dunnlow at yahoo.com Mon Jul 21 11:58:26 2014 From: dunnlow at yahoo.com (dunnlow) Date: Mon, 21 Jul 2014 08:58:26 -0700 (PDT) Subject: [rules-users] Migration to Drools 6 and Workbench from Guvnor 5.5? In-Reply-To: <1405953850391-4030409.post@n3.nabble.com> References: <1392057599571-4028040.post@n3.nabble.com> <1392061440541-4028042.post@n3.nabble.com> <1392075119671-4028049.post@n3.nabble.com> <1392224557958-4028097.post@n3.nabble.com> <1392229969793-4028102.post@n3.nabble.com> <1405953850391-4030409.post@n3.nabble.com> Message-ID: <1405958306959-4030410.post@n3.nabble.com> We did not perform the migration largely due to scheduling and the volume of changes that would be needed (against our working system). We use Guvnor, the Drools Integration Server as well as a Camel application which incorporates Drools - a lot of moving parts to update. The big hurdle I ran into was in migrating the knowledge base (partly documented in this thread). Additionally, the main driver for us to update was that the Knowledge Agent we used was unable to reconcile changes in Guvnor with a persisted knowledge session. Once migration to v6 proved to be substantial effort, I tried the latest version of 5.6.1 which I read had addressed issues with KAgent. It turns out that the issues were (largely) fixed, so we just updated to 5.6.1 as the path of least resistance. Sorry I can't provide more information. -- View this message in context: http://drools.46999.n3.nabble.com/Migration-to-Drools-6-and-Workbench-from-Guvnor-5-5-tp4028040p4030410.html Sent from the Drools: User forum mailing list archive at Nabble.com. From pichulines at gmail.com Mon Jul 21 13:28:37 2014 From: pichulines at gmail.com (pacovalsera) Date: Mon, 21 Jul 2014 10:28:37 -0700 (PDT) Subject: [rules-users] Using java enums in guvnor test scenarios (6.0.1Final) Message-ID: <1405963717819-4030411.post@n3.nabble.com> Hi all, I'm defining a test scenario within guvnor (now called kie-workbench) and I'm experiencing some issues about using java enums. The case is simple, I have a java model (deploying a jar) with a class having a member of enum type. The enum is defined in the same package but in a different java file, not an inner class. This is packed in a jar that I deploy manually uploading the file to the embedded maven repo using the workbench. / public class ClassWithMemberAsEnum { private EnumType enumMember; /*getters/setters included*/} public enum EnumType {HELLO, BYE} / Then I write a dummy rule with the guided editor like this: / import es.shin.test.ClassWithMemberAsEnum; import es.shin.test.EnumType; rule "DummyRule" dialect "mvel" when x : ClassWithMemberAsEnum( enumMember == EnumType.HELLO ) then x.setEnumMember( EnumType.BYE ); end / And finally a test scenario inserting a ClassWithMemberAsEnum initialized with enumMember=EnumType.HELLO and checking that it is changed to EnumType.BYE after firing all rules. The error message returned in the reporting console is: / EnumTest : [Error: unable to resolve method using strict-mode: java.lang.Object.es()] [Near : {... es.shin.test.EnumType.HELLO ....}] ^ [Line: 1, Column: 1] / I have tried the same case but defining the class in the data modeler and the enum with the enumeration editor, without using any jar artifact. The case worked as expected. Has anybody experienced the same issue? Thanks for your help. -- View this message in context: http://drools.46999.n3.nabble.com/Using-java-enums-in-guvnor-test-scenarios-6-0-1Final-tp4030411.html Sent from the Drools: User forum mailing list archive at Nabble.com. From borris at chaos.org.uk Mon Jul 21 14:57:35 2014 From: borris at chaos.org.uk (Borris) Date: Mon, 21 Jul 2014 19:57:35 +0100 Subject: [rules-users] Question about getObjects() on workspace with defeasible belief system Message-ID: <53CD629F.9090808@chaos.org.uk> I am trying the Defeasible belief system (it ties in pretty well with some of how I want to structure my project). After fixing many typos, the rule behaviour seems to be what it should for a defeasible rule being correctly defeated (my clash spotter doesn't fire, which it does if any part of the defeasible chain is broken). Which is all jolly fun and good and exciting. But, my question. I have a simple workspace dump based upon getting all objects (via ksession.getObjects() ) and then doing my own tidy presentation. This still shows the defeated fact as present. So I know there is still record somewhere of the defeated fact, because if the workspace changed such that my defeater was retracted, then it needs to make the fact visible again. But I wasn't expecting to see it via getObjects(). Is that the intended behaviour? If so, is there a way to enquire whether a fact is in the "defeated state" or not that I could add to my tidy workspace dumper? Thanks! Borris From dsotty at gmail.com Mon Jul 21 16:24:32 2014 From: dsotty at gmail.com (Davide Sottara) Date: Mon, 21 Jul 2014 22:24:32 +0200 Subject: [rules-users] Question about getObjects() on workspace with defeasible belief system In-Reply-To: <53CD629F.9090808@chaos.org.uk> References: <53CD629F.9090808@chaos.org.uk> Message-ID: <53CD7700.3010308@gmail.com> Thanks for the feedback! The defeasible subsystem is still very experimental, and it's good to know that people are using it. This said, as for your question. It is possible, but takes a little effort since we don't have a public API for that. You can do: // get the handle for the object InternalFactHandle handle = (InternalFactHandle) session.getFactHandle( myObject ); // lookup the belief set, where all justifiers (pos and neg) are stored and linked DefeasibleBeliefSet dbs = (DefeasibleBeliefSet) posHandle.getEqualityKey().getBeliefSet(); DefeasibilityStatus status = dbs.getStatus(); status now has 4 values: DEFINITELY (strict), DEFEASIBLY, DEFEATEDLY (defeated), UNDECIDEDLY (unresolved conflict) Notice that "negatively" asserted facts end up in a "negative" entry point, so you have to look them up explicitly: InternalFactHandle negHandle = (InternalFactHandle) session.getEntryPoint( "neg" ).getFactHandle( myNegatedObject ); Again, we are currently working on this specific system even now, so things may change in 6.2, but this should work in 6.1. Please report any issue that you might find. Best Davide On 07/21/2014 08:57 PM, Borris wrote: > I am trying the Defeasible belief system (it ties in pretty well with > some of how I want > to structure my project). > > After fixing many typos, the rule behaviour seems to be what it should > for a defeasible > rule being correctly defeated (my clash spotter doesn't fire, which it > does if any > part of the defeasible chain is broken). Which is all jolly fun and good > and exciting. > > But, my question. > > I have a simple workspace dump based upon getting all objects (via > ksession.getObjects() ) > and then doing my own tidy presentation. This still shows the defeated > fact as present. > > So I know there is still record somewhere of the defeated fact, because > if the workspace > changed such that my defeater was retracted, then it needs to make the > fact visible again. > > But I wasn't expecting to see it via getObjects(). Is that the intended > behaviour? If so, > is there a way to enquire whether a fact is in the "defeated state" or > not that I could > add to my tidy workspace dumper? > > Thanks! > > Borris > > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users > From borris at chaos.org.uk Mon Jul 21 18:41:17 2014 From: borris at chaos.org.uk (Borris) Date: Mon, 21 Jul 2014 23:41:17 +0100 Subject: [rules-users] Question about getObjects() on workspace with defeasible belief system In-Reply-To: <53CD7700.3010308@gmail.com> References: <53CD629F.9090808@chaos.org.uk> <53CD7700.3010308@gmail.com> Message-ID: <53CD970D.7050605@chaos.org.uk> And thanks for the response! A quick question on your example code before I try it: On 21/07/2014 21:24, Davide Sottara wrote: > Notice that "negatively" asserted facts end up in a "negative" entry > point, so you have to look them > up explicitly: > InternalFactHandle negHandle = (InternalFactHandle) > session.getEntryPoint( "neg" ).getFactHandle( myNegatedObject ); > Is myNegatedObject just the set that getObjects() returned or is there another enumeration method I should use? Ie do I Iook for a neg entry point object for each object I get back from ksession.getObjects() or do I need to acquire a collection from another place (as well) if I want to enumerate everything in the workspace for my dumpWorkspace() pretty printer? Thanks Borris From dsotty at gmail.com Mon Jul 21 21:04:28 2014 From: dsotty at gmail.com (Davide Sottara) Date: Tue, 22 Jul 2014 03:04:28 +0200 Subject: [rules-users] Question about getObjects() on workspace with defeasible belief system In-Reply-To: <53CD970D.7050605@chaos.org.uk> References: <53CD629F.9090808@chaos.org.uk> <53CD7700.3010308@gmail.com> <53CD970D.7050605@chaos.org.uk> Message-ID: <53CDB89C.9090607@gmail.com> getObjects() will return all the objects. However, an object's HANDLE will be in the default x-or in the "neg" entry-point, depending on whether the object was asserted in the positive or negative form, and depending on the conflict resolution by defeasibility. In my snippet, "myNegatedObject" was supposedly an object in "negative" form. If you are trying to build a pretty printer, you may just want to iterate the fact handles directly. Methods such as session.getEntryPoints() session.getEntryPoint( entryPointName ).getFactHandles(); will help On 07/22/2014 12:41 AM, Borris wrote: > And thanks for the response! > > A quick question on your example code before I try it: > > On 21/07/2014 21:24, Davide Sottara wrote: >> Notice that "negatively" asserted facts end up in a "negative" entry >> point, so you have to look them >> up explicitly: >> InternalFactHandle negHandle = (InternalFactHandle) >> session.getEntryPoint( "neg" ).getFactHandle( myNegatedObject ); >> > Is myNegatedObject just the set that getObjects() returned or is there > another enumeration method I should use? Ie do I Iook for a neg entry > point object for each object I get back from ksession.getObjects() or do > I need to acquire a collection from another place (as well) if I want to > enumerate everything in the workspace for my dumpWorkspace() pretty printer? > > Thanks > > Borris > > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users > From mproctor at codehaus.org Mon Jul 21 21:12:44 2014 From: mproctor at codehaus.org (Mark Proctor) Date: Tue, 22 Jul 2014 02:12:44 +0100 Subject: [rules-users] Question about getObjects() on workspace with defeasible belief system In-Reply-To: <53CD970D.7050605@chaos.org.uk> References: <53CD629F.9090808@chaos.org.uk> <53CD7700.3010308@gmail.com> <53CD970D.7050605@chaos.org.uk> Message-ID: Easiest thing is to look at the code: https://github.com/droolsjbpm/drools/blob/master/drools-core/src/main/java/org/drools/core/beliefsystem/defeasible/DefeasibleBeliefSet.java https://github.com/droolsjbpm/drools/blob/master/drools-core/src/main/java/org/drools/core/beliefsystem/defeasible/DefeasibleBeliefSystem.java And tests: https://github.com/droolsjbpm/drools/blob/master/drools-compiler/src/test/java/org/drools/compiler/beliefsystem/defeasible/DefeasibilityTest.java As Davide said, this is highly experimental. It?s likely we won?t use a ?neg? entry point in the future to handle negated facts, but instead provided a meta property. Mark On 21 Jul 2014, at 23:41, Borris wrote: > And thanks for the response! > > A quick question on your example code before I try it: > > On 21/07/2014 21:24, Davide Sottara wrote: >> Notice that "negatively" asserted facts end up in a "negative" entry >> point, so you have to look them >> up explicitly: >> InternalFactHandle negHandle = (InternalFactHandle) >> session.getEntryPoint( "neg" ).getFactHandle( myNegatedObject ); >> > Is myNegatedObject just the set that getObjects() returned or is there > another enumeration method I should use? Ie do I Iook for a neg entry > point object for each object I get back from ksession.getObjects() or do > I need to acquire a collection from another place (as well) if I want to > enumerate everything in the workspace for my dumpWorkspace() pretty printer? > > Thanks > > Borris > > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users From toni.rikkola at gmail.com Tue Jul 22 05:25:46 2014 From: toni.rikkola at gmail.com (Toni Rikkola) Date: Tue, 22 Jul 2014 12:25:46 +0300 Subject: [rules-users] Using java enums in guvnor test scenarios (6.0.1Final) In-Reply-To: <1405963717819-4030411.post@n3.nabble.com> References: <1405963717819-4030411.post@n3.nabble.com> Message-ID: <1406021146.3041.1.camel@localhost.localdomain> Hi, Tested this and looks like you found a bug. Made a ticket for it so we can get it fixed. https://bugzilla.redhat.com/show_bug.cgi?id=1121985 Thanks for reporting Toni Rikkola On ma, 2014-07-21 at 10:28 -0700, pacovalsera wrote: > Hi all, I'm defining a test scenario within guvnor (now called kie-workbench) > and I'm experiencing some issues about using java enums. > > The case is simple, I have a java model (deploying a jar) with a class > having a member of enum type. The enum is defined in the same package but in > a different java file, not an inner class. This is packed in a jar that I > deploy manually uploading the file to the embedded maven repo using the > workbench. > > / > public class ClassWithMemberAsEnum { private EnumType enumMember; > /*getters/setters included*/} > public enum EnumType {HELLO, BYE} > / > > Then I write a dummy rule with the guided editor like this: > > / > import es.shin.test.ClassWithMemberAsEnum; > import es.shin.test.EnumType; > > rule "DummyRule" > dialect "mvel" > when > x : ClassWithMemberAsEnum( enumMember == EnumType.HELLO ) > then > x.setEnumMember( EnumType.BYE ); > end > / > > And finally a test scenario inserting a ClassWithMemberAsEnum initialized > with enumMember=EnumType.HELLO and checking that it is changed to > EnumType.BYE after firing all rules. > > The error message returned in the reporting console is: > > / > EnumTest : [Error: unable to resolve method using strict-mode: > java.lang.Object.es()] [Near : {... es.shin.test.EnumType.HELLO ....}] ^ > [Line: 1, Column: 1] > / > > I have tried the same case but defining the class in the data modeler and > the enum with the enumeration editor, without using any jar artifact. The > case worked as expected. > > Has anybody experienced the same issue? Thanks for your help. > > > > > -- > View this message in context: http://drools.46999.n3.nabble.com/Using-java-enums-in-guvnor-test-scenarios-6-0-1Final-tp4030411.html > Sent from the Drools: User forum mailing list archive at Nabble.com. > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users From pichulines at gmail.com Tue Jul 22 05:57:38 2014 From: pichulines at gmail.com (pacovalsera) Date: Tue, 22 Jul 2014 02:57:38 -0700 (PDT) Subject: [rules-users] Using java enums in guvnor test scenarios (6.0.1Final) In-Reply-To: <1406021146.3041.1.camel@localhost.localdomain> References: <1405963717819-4030411.post@n3.nabble.com> <1406021146.3041.1.camel@localhost.localdomain> Message-ID: <1406023058056-4030421.post@n3.nabble.com> Hi Toni, thanks for your quick response. As a workaround I'm defining a getter/setter for the enum member based on a string arg. That is, / public String getEnumMemberStr() {return enumMember.name();} public void setEnumMemberStr(String enumMemberStr) {enumMember=EnumType.valueOf(enumMemberStr); } / Then I use them in the test scenario to initialize facts. To avoid type errors I also define an enumeration for the new member (enumMemberStr), so the scenario editor shows a combo rather and a free text field. In the rules there is no problem in using the enum member (enumMember). Meanwhile I'll wait for the fix in the next release. -- View this message in context: http://drools.46999.n3.nabble.com/Using-java-enums-in-guvnor-test-scenarios-6-0-1Final-tp4030411p4030421.html Sent from the Drools: User forum mailing list archive at Nabble.com. From jps at jps.ch Tue Jul 22 06:25:12 2014 From: jps at jps.ch (jps) Date: Tue, 22 Jul 2014 03:25:12 -0700 (PDT) Subject: [rules-users] [drools-wb] how to move an asset to another package ? Message-ID: <1406024712969-4030422.post@n3.nabble.com> Hello, I'm in the process of refactoring the different packages in my project. How can I move an asset (a guided decision table in this case) from its current package to a new package ? It seems there's no button or action for that in drools-wb ? Regards. --jps -- View this message in context: http://drools.46999.n3.nabble.com/drools-wb-how-to-move-an-asset-to-another-package-tp4030422.html Sent from the Drools: User forum mailing list archive at Nabble.com. From mproctor at codehaus.org Tue Jul 22 09:27:24 2014 From: mproctor at codehaus.org (Mark Proctor) Date: Tue, 22 Jul 2014 14:27:24 +0100 Subject: [rules-users] Drools Applications Google Group Message-ID: A while back there was a discussion on the volume of posts and the range of post discussions. OptaPlanner already has it?s own google group, which has helped reduce the volume. There is still the discussion on whether to split Drools. My initial idea is to leave this list for installation, setup, configuration, deployment and getting started (hello world won?t run) - this tends to be a fairly shallow knowledge area, that new people will need to deal with. Then also create a separate google group for those wanting help on writing rule applications, that?s authoring (drl, score cards, decision tables etc) and running (insert, fireAllRules etc); this would become a deep knowledge area. In the google group you would not ask how to install the workbench, or how to deploy your app, or how to setup HA etc. Thoughts? We are about to do 6.1 final. For this we are revamping the websites, and sorting out our communications (lists etc) at the same time. Mark From richard.hands at uk.sopragroup.com Tue Jul 22 09:42:28 2014 From: richard.hands at uk.sopragroup.com (richardhands) Date: Tue, 22 Jul 2014 06:42:28 -0700 (PDT) Subject: [rules-users] how to count distinct nested property? Message-ID: <1406036548440-4030424.post@n3.nabble.com> Hi, I?m trying to wrap my head around how to use a combination of accumulate from and collect from to get a count of how many unique items there are of a nested child property and run the RHS of a rule if it?s > 1 So I have Many of Object A Each one contains An object B An object C Object C contains a nested child property So A +-+-B | +-C ? property myId (many of these in the working memory) The rule I?m working with right now is rule "B must only be at 1 myId per day" when $b : B() $c : C() $aList : ArrayList (size > 1) from collect( A(b == $b, c.getDate() == $c.getDate()) ) eval ( RulesUtils.countIdsForC ($aList) > 1 ) then //fire some rules here end and the RulesUtils method is public static int countIdsForC (List aList) { Set myIds = new HashSet(); for (A a : aList) { myIds.add(a.getC().getMyId()); } return myIds.size(); } Now I?m well aware that this is sub-optimal, and indeed is firing lots of extra times and is really (Really) slow. I can vizualise that this should easily be possible with some combination of compound accumulate and collect statements, but for the life of me I can?t work out the correct arrangement (This is actually for use in an optaplanner ruleset so it will potentially be working on lots of data, over many iterations). Any suggestions on how to do this the way I know it needs to be, greatfully appreciated ? -- View this message in context: http://drools.46999.n3.nabble.com/how-to-count-distinct-nested-property-tp4030424.html Sent from the Drools: User forum mailing list archive at Nabble.com. From marianbuenosayres at gmail.com Tue Jul 22 10:20:08 2014 From: marianbuenosayres at gmail.com (marianbuenosayres) Date: Tue, 22 Jul 2014 07:20:08 -0700 (PDT) Subject: [rules-users] Dynamically loading rules in KieBase In-Reply-To: <1405375761418-4030351.post@n3.nabble.com> References: <1405375761418-4030351.post@n3.nabble.com> Message-ID: <1406038808305-4030425.post@n3.nabble.com> I'm bumping this question for general interest on other possible solutions, and to give my two cents. The closest I was to getting this feature in Drools 6 from the public APIs, is to use a persistent session. Then, when I loaded an existing session, I would pass a newly created KieBase, like this KieStoreServices kstore = KieServices.Factory.get().getStoreServices(); KieBase kbase = ...; //create a Kie Base Environment env = ...; //create an environment KieSession ksession = kstore.newKieSession(kbase, null, env); Integer sessionId = ksession.getId(); KieBase kbase2 = ...; //updated Kie base KieSession ksessionReloaded = ks.loadKieSession(kbase2, null, env); ksession and ksessionReloaded would be the same working memory and agenda, but the kie base they work with would change. Hope this helps, but I hope more for an alternative -- View this message in context: http://drools.46999.n3.nabble.com/Dynamically-loading-rules-in-KieBase-tp4030351p4030425.html Sent from the Drools: User forum mailing list archive at Nabble.com. From jeremy.ary at gmail.com Tue Jul 22 10:38:33 2014 From: jeremy.ary at gmail.com (Jeremy Ary) Date: Tue, 22 Jul 2014 09:38:33 -0500 Subject: [rules-users] how to count distinct nested property? In-Reply-To: <1406036548440-4030424.post@n3.nabble.com> References: <1406036548440-4030424.post@n3.nabble.com> Message-ID: I wonder if something like this might do it? when $set : HashSet ( ) from accumulate ( ObjectA ( $myId : objectC.myId ), init ( HashSet uniqueIds = new HashSet(); ), action ( uniqueIds.add($id); ), reverse ( uniqueIds.remove($id); ), result ( uniqueIds ) ) HashSet ( this == $set, size > 1 ) then // consequence end - Jeremy On Tue, Jul 22, 2014 at 8:42 AM, richardhands < richard.hands at uk.sopragroup.com> wrote: > Hi, > > I?m trying to wrap my head around how to use a combination of accumulate > from and collect from to get a count of how many unique items there are of > a > nested child property and run the RHS of a rule if it?s > 1 > > So I have > > Many of Object A > > Each one contains > An object B > An object C > > Object C contains a nested child property > > So > > A > +-+-B > | > +-C ? property myId > > (many of these in the working memory) > > The rule I?m working with right now is > > rule "B must only be at 1 myId per day" > when > $b : B() > $c : C() > $aList : ArrayList (size > 1) > from collect( > A(b == $b, c.getDate() == $c.getDate()) ) > eval ( RulesUtils.countIdsForC ($aList) > 1 ) > then > //fire some rules here > end > > and the RulesUtils method is > > public static int countIdsForC (List aList) > { > Set myIds = new HashSet(); > for (A a : aList) > { > myIds.add(a.getC().getMyId()); > } > return myIds.size(); > } > > > Now I?m well aware that this is sub-optimal, and indeed is firing lots of > extra times and is really (Really) slow. I can vizualise that this should > easily be possible with some combination of compound accumulate and collect > statements, but for the life of me I can?t work out the correct arrangement > (This is actually for use in an optaplanner ruleset so it will potentially > be working on lots of data, over many iterations). > > Any suggestions on how to do this the way I know it needs to be, greatfully > appreciated ? > > > > > -- > View this message in context: > http://drools.46999.n3.nabble.com/how-to-count-distinct-nested-property-tp4030424.html > Sent from the Drools: User forum mailing list archive at Nabble.com. > > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140722/49025101/attachment.html From jeremy.ary at gmail.com Tue Jul 22 10:39:52 2014 From: jeremy.ary at gmail.com (Jeremy Ary) Date: Tue, 22 Jul 2014 09:39:52 -0500 Subject: [rules-users] how to count distinct nested property? In-Reply-To: References: <1406036548440-4030424.post@n3.nabble.com> Message-ID: err, typo there, add() and remove() should be using $myId instead of $id On Tue, Jul 22, 2014 at 9:38 AM, Jeremy Ary wrote: > I wonder if something like this might do it? > > when > $set : HashSet ( ) from accumulate ( ObjectA ( $myId : objectC.myId ), > init ( HashSet uniqueIds = new HashSet(); ), > action ( uniqueIds.add($id); ), > reverse ( uniqueIds.remove($id); ), > result ( uniqueIds ) ) > HashSet ( this == $set, size > 1 ) > then > // consequence > end > > > - Jeremy > > > > On Tue, Jul 22, 2014 at 8:42 AM, richardhands < > richard.hands at uk.sopragroup.com> wrote: > >> Hi, >> >> I?m trying to wrap my head around how to use a combination of accumulate >> from and collect from to get a count of how many unique items there are >> of a >> nested child property and run the RHS of a rule if it?s > 1 >> >> So I have >> >> Many of Object A >> >> Each one contains >> An object B >> An object C >> >> Object C contains a nested child property >> >> So >> >> A >> +-+-B >> | >> +-C ? property myId >> >> (many of these in the working memory) >> >> The rule I?m working with right now is >> >> rule "B must only be at 1 myId per day" >> when >> $b : B() >> $c : C() >> $aList : ArrayList (size > 1) >> from collect( >> A(b == $b, c.getDate() == $c.getDate()) ) >> eval ( RulesUtils.countIdsForC ($aList) > 1 ) >> then >> //fire some rules here >> end >> >> and the RulesUtils method is >> >> public static int countIdsForC (List aList) >> { >> Set myIds = new HashSet(); >> for (A a : aList) >> { >> myIds.add(a.getC().getMyId()); >> } >> return myIds.size(); >> } >> >> >> Now I?m well aware that this is sub-optimal, and indeed is firing lots of >> extra times and is really (Really) slow. I can vizualise that this should >> easily be possible with some combination of compound accumulate and >> collect >> statements, but for the life of me I can?t work out the correct >> arrangement >> (This is actually for use in an optaplanner ruleset so it will potentially >> be working on lots of data, over many iterations). >> >> Any suggestions on how to do this the way I know it needs to be, >> greatfully >> appreciated ? >> >> >> >> >> -- >> View this message in context: >> http://drools.46999.n3.nabble.com/how-to-count-distinct-nested-property-tp4030424.html >> Sent from the Drools: User forum mailing list archive at Nabble.com. >> >> _______________________________________________ >> rules-users mailing list >> rules-users at lists.jboss.org >> https://lists.jboss.org/mailman/listinfo/rules-users > > > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140722/7ce53511/attachment.html From jeremy.ary at gmail.com Tue Jul 22 10:50:27 2014 From: jeremy.ary at gmail.com (Jeremy Ary) Date: Tue, 22 Jul 2014 09:50:27 -0500 Subject: [rules-users] how to count distinct nested property? In-Reply-To: References: <1406036548440-4030424.post@n3.nabble.com> Message-ID: My last comparison there may be problematic as well...too focused on the accumulate to see the obvious. I think that approach might still require an eval to check the size constraint on the list and we don't really want that. What you could do instead, however, is insert the hashset into the working memory in that rule's consequence and have a 2nd rule that's just HashSet ( size > 1 ) and its consequence does your actions and retracts the hashset back out of memory. - J On Tue, Jul 22, 2014 at 9:39 AM, Jeremy Ary wrote: > err, typo there, add() and remove() should be using $myId instead of $id > > > On Tue, Jul 22, 2014 at 9:38 AM, Jeremy Ary wrote: > >> I wonder if something like this might do it? >> >> when >> $set : HashSet ( ) from accumulate ( ObjectA ( $myId : objectC.myId ), >> init ( HashSet uniqueIds = new HashSet(); ), >> action ( uniqueIds.add($id); ), >> reverse ( uniqueIds.remove($id); ), >> result ( uniqueIds ) ) >> HashSet ( this == $set, size > 1 ) >> then >> // consequence >> end >> >> >> - Jeremy >> >> >> >> On Tue, Jul 22, 2014 at 8:42 AM, richardhands < >> richard.hands at uk.sopragroup.com> wrote: >> >>> Hi, >>> >>> I?m trying to wrap my head around how to use a combination of accumulate >>> from and collect from to get a count of how many unique items there are >>> of a >>> nested child property and run the RHS of a rule if it?s > 1 >>> >>> So I have >>> >>> Many of Object A >>> >>> Each one contains >>> An object B >>> An object C >>> >>> Object C contains a nested child property >>> >>> So >>> >>> A >>> +-+-B >>> | >>> +-C ? property myId >>> >>> (many of these in the working memory) >>> >>> The rule I?m working with right now is >>> >>> rule "B must only be at 1 myId per day" >>> when >>> $b : B() >>> $c : C() >>> $aList : ArrayList (size > 1) >>> from collect( >>> A(b == $b, c.getDate() == $c.getDate()) ) >>> eval ( RulesUtils.countIdsForC ($aList) > 1 ) >>> then >>> //fire some rules here >>> end >>> >>> and the RulesUtils method is >>> >>> public static int countIdsForC (List aList) >>> { >>> Set myIds = new HashSet(); >>> for (A a : aList) >>> { >>> myIds.add(a.getC().getMyId()); >>> } >>> return myIds.size(); >>> } >>> >>> >>> Now I?m well aware that this is sub-optimal, and indeed is firing lots of >>> extra times and is really (Really) slow. I can vizualise that this >>> should >>> easily be possible with some combination of compound accumulate and >>> collect >>> statements, but for the life of me I can?t work out the correct >>> arrangement >>> (This is actually for use in an optaplanner ruleset so it will >>> potentially >>> be working on lots of data, over many iterations). >>> >>> Any suggestions on how to do this the way I know it needs to be, >>> greatfully >>> appreciated ? >>> >>> >>> >>> >>> -- >>> View this message in context: >>> http://drools.46999.n3.nabble.com/how-to-count-distinct-nested-property-tp4030424.html >>> Sent from the Drools: User forum mailing list archive at Nabble.com. >>> >>> _______________________________________________ >>> rules-users mailing list >>> rules-users at lists.jboss.org >>> https://lists.jboss.org/mailman/listinfo/rules-users >> >> >> > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140722/6927663c/attachment.html From michael1.cis at gmail.com Tue Jul 22 11:13:07 2014 From: michael1.cis at gmail.com (mikedev9000) Date: Tue, 22 Jul 2014 08:13:07 -0700 (PDT) Subject: [rules-users] KieContainer#updateToVersion fails when both versions of a drl file contain an event type declaration for an existing class In-Reply-To: References: <1403119812069-4030100.post@n3.nabble.com> Message-ID: <1406041987438-4030434.post@n3.nabble.com> Mark, thank you for the response. I was able to reproduce this issue with 6.1CR1 and the latest code from the 6.1.x as of this morning. I created a bug ticket for this issue and a pull request containing the unit test I wrote. Ticket: https://issues.jboss.org/browse/DROOLS-560 Pull request: https://github.com/droolsjbpm/drools/pull/360 -- View this message in context: http://drools.46999.n3.nabble.com/KieContainer-updateToVersion-fails-when-both-versions-of-a-drl-file-contain-an-event-type-declaratios-tp4030100p4030434.html Sent from the Drools: User forum mailing list archive at Nabble.com. From borris at chaos.org.uk Tue Jul 22 11:48:11 2014 From: borris at chaos.org.uk (Borris) Date: Tue, 22 Jul 2014 16:48:11 +0100 Subject: [rules-users] Are globals not permitted with queries? Message-ID: <53CE87BB.7050203@chaos.org.uk> I was experimenting with ways of avoiding having to put literal strings into my rules (it is very fragile and bugs can be silent for a long time). I tried declaring a global and then tried supplying it to a query. This generates a backtrace during the newKieSession. A simple example to provoke the problem: KieServices ks = KieServices.Factory.get(); KieContainer kContainer = ks.getKieClasspathContainer(); KieSession kSession = kContainer.newKieSession("ksession-rules"); kSession.setGlobal("AString", "Hello World"); kSession.fireAllRules(); package com.sample global java.lang.String AString; declare Thing name: String @key end rule init when then insert( new Thing( AString ) ); end query test(String $in) Thing( $in; ) end rule spot when test( "Hello World"; ) Thing( "Hello World"; ) test( AString; ) Thing( AString; ) then System.out.println("found msg\n"); end java.lang.NullPointerException at org.drools.core.rule.LogicTransformer.processElement(LogicTransformer.java:243) at org.drools.core.rule.LogicTransformer.processElement(LogicTransformer.java:263) at org.drools.core.rule.LogicTransformer.fixClonedDeclarations(LogicTransformer.java:134) at org.drools.core.rule.LogicTransformer.transform(LogicTransformer.java:99) at org.drools.core.definitions.rule.impl.RuleImpl.getTransformedLhs(RuleImpl.java:560) at org.drools.core.reteoo.builder.ReteooRuleBuilder.addRule(ReteooRuleBuilder.java:105) at org.drools.core.reteoo.ReteooBuilder.addRule(ReteooBuilder.java:100) at org.drools.core.impl.KnowledgeBaseImpl.addRule(KnowledgeBaseImpl.java:1455) at org.drools.core.impl.KnowledgeBaseImpl.addRule(KnowledgeBaseImpl.java:1435) at org.drools.core.impl.KnowledgeBaseImpl.addPackages(KnowledgeBaseImpl.java:838) at org.drools.core.impl.KnowledgeBaseImpl.addKnowledgePackages(KnowledgeBaseImpl.java:266) at org.drools.compiler.kie.builder.impl.KieContainerImpl.createKieBase(KieContainerImpl.java:412) at org.drools.compiler.kie.builder.impl.KieContainerImpl.getKieBase(KieContainerImpl.java:346) at org.drools.compiler.kie.builder.impl.KieContainerImpl.newKieSession(KieContainerImpl.java:498) at org.drools.compiler.kie.builder.impl.KieContainerImpl.newKieSession(KieContainerImpl.java:469) at com.sample.DroolsTest.main(DroolsTest.java:17) The 3rd action in the spot rule causes the null exception during initialise, if it is present. Comment out just that line and no exceptions happen and behaviour is as expected. Are globals permitted in the way I am trying to use them, as a parameter to a query? Borris From dsotty at gmail.com Tue Jul 22 12:14:32 2014 From: dsotty at gmail.com (Davide Sottara) Date: Tue, 22 Jul 2014 18:14:32 +0200 Subject: [rules-users] Dynamically loading rules in KieBase In-Reply-To: <1406038808305-4030425.post@n3.nabble.com> References: <1405375761418-4030351.post@n3.nabble.com> <1406038808305-4030425.post@n3.nabble.com> Message-ID: <53CE8DE8.8040001@gmail.com> You can add rules programmatically to an existing KieBase, but you have to: 1) add/replace the resource in the KieFileSystem 2) Cast the KieBuilder to InternalKieBuilder and use the incrementalBuild() method 3) Enjoy and report problems as this is a newer feature See the test suite here https://github.com/droolsjbpm/drools/blob/184765346e998430064a4935fbb358930946d82c/drools-compiler/src/test/java/org/drools/compiler/integrationtests/IncrementalCompilationTest.java the latest tests show the use of the incremental builder Davide On 07/22/2014 04:20 PM, marianbuenosayres wrote: > I'm bumping this question for general interest on other possible solutions, > and to give my two cents. > > The closest I was to getting this feature in Drools 6 from the public APIs, > is to use a persistent session. Then, when I loaded an existing session, I > would pass a newly created KieBase, like this > > KieStoreServices kstore = KieServices.Factory.get().getStoreServices(); > > KieBase kbase = ...; //create a Kie Base > Environment env = ...; //create an environment > KieSession ksession = kstore.newKieSession(kbase, null, env); > Integer sessionId = ksession.getId(); > > KieBase kbase2 = ...; //updated Kie base > KieSession ksessionReloaded = ks.loadKieSession(kbase2, null, env); > > ksession and ksessionReloaded would be the same working memory and agenda, > but the kie base they work with would change. > > Hope this helps, but I hope more for an alternative > > > > -- > View this message in context: http://drools.46999.n3.nabble.com/Dynamically-loading-rules-in-KieBase-tp4030351p4030425.html > Sent from the Drools: User forum mailing list archive at Nabble.com. > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users > From borris at chaos.org.uk Tue Jul 22 12:16:27 2014 From: borris at chaos.org.uk (Borris) Date: Tue, 22 Jul 2014 17:16:27 +0100 Subject: [rules-users] Drools Applications Google Group In-Reply-To: References: Message-ID: <53CE8E5B.4090903@chaos.org.uk> On 22/07/2014 14:27, Mark Proctor wrote: > A while back there was a discussion on the volume of posts and the range of post discussions. OptaPlanner already has it?s own google group, which has helped reduce the volume. There is still the discussion on whether to split Drools. > > My initial idea is to leave this list for installation, setup, configuration, deployment and getting started (hello world won?t run) - this tends to be a fairly shallow knowledge area, that new people will need to deal with. Then also create a separate google group for those wanting help on writing rule applications, that?s authoring (drl, score cards, decision tables etc) and running (insert, fireAllRules etc); this would become a deep knowledge area. In the google group you would not ask how to install the workbench, or how to deploy your app, or how to setup HA etc. > > Thoughts? > > We are about to do 6.1 final. For this we are revamping the websites, and sorting out our communications (lists etc) at the same time. > > Mark > A few thoughts for you: Partitioning the discussions as you suggest sounds sensible - minimising "off-topic" posts is always desirable. It should be *easy* for a user who lands on one of the groups (say via a Google search) to realise there is a better (more appropriate) group for them to post their question on - so maybe some form of standardised footer that compactly identifies the purposes of the different groups? Over time, I think you could also use the application writing group to bootstrap some form of "How do I ..." FAQ or tips and techniques listing. This could supplement the documentation, but be organised by developer task rather than language feature/area. Borris From dsotty at gmail.com Tue Jul 22 12:16:42 2014 From: dsotty at gmail.com (Davide Sottara) Date: Tue, 22 Jul 2014 18:16:42 +0200 Subject: [rules-users] Are globals not permitted with queries? In-Reply-To: <53CE87BB.7050203@chaos.org.uk> References: <53CE87BB.7050203@chaos.org.uk> Message-ID: <53CE8E6A.40708@gmail.com> The case may not be supported, but even then, it should be reported as a compilation error, not as a NPE I'll investigate and report back later Thanks Davide On 07/22/2014 05:48 PM, Borris wrote: > I was experimenting with ways of avoiding having to put literal strings > into my rules (it is very fragile and bugs can be silent for a long > time). I tried declaring a global and then tried supplying it to a > query. This generates a backtrace during the newKieSession. A simple > example to provoke the problem: > > > KieServices ks = KieServices.Factory.get(); > KieContainer kContainer = ks.getKieClasspathContainer(); > KieSession kSession = > kContainer.newKieSession("ksession-rules"); > > kSession.setGlobal("AString", "Hello World"); > > kSession.fireAllRules(); > > > > package com.sample > > global java.lang.String AString; > > declare Thing > name: String @key > end > > rule init > when > then > insert( new Thing( AString ) ); > end > > query test(String $in) > Thing( $in; ) > end > > rule spot > when > test( "Hello World"; ) > Thing( "Hello World"; ) > test( AString; ) > Thing( AString; ) > then > System.out.println("found msg\n"); > end > > > java.lang.NullPointerException > at > org.drools.core.rule.LogicTransformer.processElement(LogicTransformer.java:243) > at > org.drools.core.rule.LogicTransformer.processElement(LogicTransformer.java:263) > at > org.drools.core.rule.LogicTransformer.fixClonedDeclarations(LogicTransformer.java:134) > at > org.drools.core.rule.LogicTransformer.transform(LogicTransformer.java:99) > at > org.drools.core.definitions.rule.impl.RuleImpl.getTransformedLhs(RuleImpl.java:560) > at > org.drools.core.reteoo.builder.ReteooRuleBuilder.addRule(ReteooRuleBuilder.java:105) > at org.drools.core.reteoo.ReteooBuilder.addRule(ReteooBuilder.java:100) > at > org.drools.core.impl.KnowledgeBaseImpl.addRule(KnowledgeBaseImpl.java:1455) > at > org.drools.core.impl.KnowledgeBaseImpl.addRule(KnowledgeBaseImpl.java:1435) > at > org.drools.core.impl.KnowledgeBaseImpl.addPackages(KnowledgeBaseImpl.java:838) > at > org.drools.core.impl.KnowledgeBaseImpl.addKnowledgePackages(KnowledgeBaseImpl.java:266) > at > org.drools.compiler.kie.builder.impl.KieContainerImpl.createKieBase(KieContainerImpl.java:412) > at > org.drools.compiler.kie.builder.impl.KieContainerImpl.getKieBase(KieContainerImpl.java:346) > at > org.drools.compiler.kie.builder.impl.KieContainerImpl.newKieSession(KieContainerImpl.java:498) > at > org.drools.compiler.kie.builder.impl.KieContainerImpl.newKieSession(KieContainerImpl.java:469) > at com.sample.DroolsTest.main(DroolsTest.java:17) > > > The 3rd action in the spot rule causes the null exception during > initialise, if it is present. Comment out just that line and no > exceptions happen and behaviour is as expected. > > Are globals permitted in the way I am trying to use them, as a parameter > to a query? > > Borris > > > > > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users > From mario.fusco at gmail.com Tue Jul 22 14:25:55 2014 From: mario.fusco at gmail.com (Mario Fusco) Date: Tue, 22 Jul 2014 11:25:55 -0700 (PDT) Subject: [rules-users] KieContainer#updateToVersion fails when both versions of a drl file contain an event type declaration for an existing class In-Reply-To: <1406041987438-4030434.post@n3.nabble.com> References: <1403119812069-4030100.post@n3.nabble.com> <1406041987438-4030434.post@n3.nabble.com> Message-ID: <1406053555305-4030440.post@n3.nabble.com> Hi Mike, I merged your test case and fixed the bug with this commit https://github.com/droolsjbpm/drools/commit/283ba1d94 Thanks a lot for having reported this problem, Mario -- View this message in context: http://drools.46999.n3.nabble.com/KieContainer-updateToVersion-fails-when-both-versions-of-a-drl-file-contain-an-event-type-declaratios-tp4030100p4030440.html Sent from the Drools: User forum mailing list archive at Nabble.com. From borris at chaos.org.uk Tue Jul 22 15:40:27 2014 From: borris at chaos.org.uk (Borris) Date: Tue, 22 Jul 2014 20:40:27 +0100 Subject: [rules-users] Defeasible: NPE: with multiple @Defeasible Message-ID: <53CEBE2B.4070903@chaos.org.uk> Hi Davide, I've got a null pointer exception with defeasible. My test case is: package com.sample declare Fact fact: String @key end rule init when then System.out.println("inserting initial facts"); insert( new Fact( "one" ) ); insert( new Fact( "two" ) ); insert( new Fact( "two" ) ); end rule rule1 @Defeasible enabled true when Fact( "one"; ) then System.out.println("one causes wibble"); insertLogical( new Fact( "wibble") ); end rule rule2 @Defeasible when Fact( "two"; ) then System.out.println("two causes wibble"); insertLogical( new Fact( "wibble") ); end rule rule3 @Defeater @Defeats( "rule2" ) when Fact( "two"; ) then System.out.println("two negates wibble"); insertLogical( new Fact( "wibble"), "neg" ); end The output I get is inserting initial facts one causes wibble two causes wibble two causes wibble two negates wibble two negates wibble Exception executing consequence for rule "rule3" in com.sample: java.lang.NullPointerException at org.drools.core.runtime.rule.impl.DefaultConsequenceExceptionHandler.handleException(DefaultConsequenceExceptionHandler.java:39) at org.drools.core.common.DefaultAgenda.fireActivation(DefaultAgenda.java:1057) at org.drools.core.phreak.RuleExecutor.fire(RuleExecutor.java:152) at org.drools.core.phreak.RuleExecutor.evaluateNetworkAndFire(RuleExecutor.java:94) at org.drools.core.common.DefaultAgenda.fireNextItem(DefaultAgenda.java:964) at org.drools.core.common.DefaultAgenda.fireAllRules(DefaultAgenda.java:1234) at org.drools.core.impl.StatefulKnowledgeSessionImpl.fireAllRules(StatefulKnowledgeSessionImpl.java:1239) at org.drools.core.impl.StatefulKnowledgeSessionImpl.fireAllRules(StatefulKnowledgeSessionImpl.java:1212) at com.sample.DroolsTest.main(DroolsTest.java:21) Caused by: java.lang.NullPointerException at org.drools.core.beliefsystem.defeasible.DefeasibleBeliefSet.removeUndefeated(DefeasibleBeliefSet.java:295) at org.drools.core.beliefsystem.defeasible.DefeasibleBeliefSet.add(DefeasibleBeliefSet.java:126) at org.drools.core.beliefsystem.jtms.JTMSBeliefSystem.insert(JTMSBeliefSystem.java:52) at org.drools.core.beliefsystem.defeasible.DefeasibleBeliefSystem.insert(DefeasibleBeliefSystem.java:45) at org.drools.core.common.TruthMaintenanceSystem.addLogicalDependency(TruthMaintenanceSystem.java:136) at org.drools.core.common.TruthMaintenanceSystem.addLogicalDependency(TruthMaintenanceSystem.java:107) at org.drools.core.common.NamedEntryPoint.insert(NamedEntryPoint.java:234) at org.drools.core.impl.StatefulKnowledgeSessionImpl.insert(StatefulKnowledgeSessionImpl.java:1430) at org.drools.core.base.DefaultKnowledgeHelper.insertLogical(DefaultKnowledgeHelper.java:275) at org.drools.core.base.DefaultKnowledgeHelper.insertLogical(DefaultKnowledgeHelper.java:247) at com.sample.Rule_rule32132126114.defaultConsequence(Rule_rule32132126114.java:8) at com.sample.Rule_rule32132126114DefaultConsequenceInvokerGenerated.evaluate(Unknown Source) at com.sample.Rule_rule32132126114DefaultConsequenceInvoker.evaluate(Unknown Source) at org.drools.core.common.DefaultAgenda.fireActivation(DefaultAgenda.java:1046) ... 7 more I believe I am using snapshot 6.1.0.201407170510 but I suspect the precise version doesn't matter too much. In the above example, if you disable rule1 then the NPE doesn't happen. Only doing one "two" fact insertion in the init rule likewise means the NPE doesn't happen. I think the issue is something like rule3 does more than one defeat on rule2's scoring on "wibble" fact, but rule1 still has a say in the continuing existence of the "wibble" fact. Should I get a Jira log in and enter these well qualified bugs directly? Regards, Borris From mproctor at codehaus.org Tue Jul 22 16:52:09 2014 From: mproctor at codehaus.org (Mark Proctor) Date: Tue, 22 Jul 2014 21:52:09 +0100 Subject: [rules-users] Drools Applications Google Group In-Reply-To: References: Message-ID: I?m currently setting a google group, won?t touch nabble. It allows welcome messages, sticky nodes, and if necessary moderation. Mark On 22 Jul 2014, at 18:24, Wolfgang Laun wrote: > As long as Nabble is kept out. > > Stackoverflow is, at present, quite reasonable, with a high percentage > of what I consider as interesting, i.e., the "hard core" Expert/Fusion > questions. > > Cheers > Wolfgang > > On 22/07/2014, Mark Proctor wrote: >> A while back there was a discussion on the volume of posts and the range of >> post discussions. OptaPlanner already has it's own google group, which has >> helped reduce the volume. There is still the discussion on whether to split >> Drools. >> >> My initial idea is to leave this list for installation, setup, >> configuration, deployment and getting started (hello world won't run) - this >> tends to be a fairly shallow knowledge area, that new people will need to >> deal with. Then also create a separate google group for those wanting help >> on writing rule applications, that's authoring (drl, score cards, decision >> tables etc) and running (insert, fireAllRules etc); this would become a deep >> knowledge area. In the google group you would not ask how to install the >> workbench, or how to deploy your app, or how to setup HA etc. >> >> Thoughts? >> >> We are about to do 6.1 final. For this we are revamping the websites, and >> sorting out our communications (lists etc) at the same time. >> >> Mark >> >> From mproctor at codehaus.org Tue Jul 22 17:44:56 2014 From: mproctor at codehaus.org (Mark Proctor) Date: Tue, 22 Jul 2014 22:44:56 +0100 Subject: [rules-users] Defeasible: NPE: with multiple @Defeasible In-Reply-To: <53CEBE2B.4070903@chaos.org.uk> References: <53CEBE2B.4070903@chaos.org.uk> Message-ID: <1FE456CF-C308-4AE5-A014-EBAB4A9C23A2@codehaus.org> Stack trace shows the error: org.drools.core.beliefsystem.defeasible.DefeasibleBeliefSet.removeUndefeated(DefeasibleBeliefSet.java:295) https://github.com/sotty/drools/blob/master/drools-core/src/main/java/org/drools/core/beliefsystem/defeasible/DefeasibleBeliefSet.java Maybe have a go fixing it yourself? And submit the fix with a unit test, as a pull request? http://docs.jboss.org/drools/release/5.6.0.Final/droolsjbpm-introduction-docs/html/gettingstarted.html Mark On 22 Jul 2014, at 20:40, Borris wrote: > Hi Davide, > > I've got a null pointer exception with defeasible. My test case is: > > package com.sample > > declare Fact > fact: String @key > end > > rule init > when > then > System.out.println("inserting initial facts"); > insert( new Fact( "one" ) ); > insert( new Fact( "two" ) ); > insert( new Fact( "two" ) ); > end > > rule rule1 > @Defeasible > enabled true > when > Fact( "one"; ) > then > System.out.println("one causes wibble"); > insertLogical( new Fact( "wibble") ); > end > > rule rule2 > @Defeasible > when > Fact( "two"; ) > then > System.out.println("two causes wibble"); > insertLogical( new Fact( "wibble") ); > end > > rule rule3 > @Defeater > @Defeats( "rule2" ) > when > Fact( "two"; ) > then > System.out.println("two negates wibble"); > insertLogical( new Fact( "wibble"), "neg" ); > end > > The output I get is > > inserting initial facts > one causes wibble > two causes wibble > two causes wibble > two negates wibble > two negates wibble > Exception executing consequence for rule "rule3" in com.sample: > java.lang.NullPointerException > at > org.drools.core.runtime.rule.impl.DefaultConsequenceExceptionHandler.handleException(DefaultConsequenceExceptionHandler.java:39) > at > org.drools.core.common.DefaultAgenda.fireActivation(DefaultAgenda.java:1057) > at org.drools.core.phreak.RuleExecutor.fire(RuleExecutor.java:152) > at > org.drools.core.phreak.RuleExecutor.evaluateNetworkAndFire(RuleExecutor.java:94) > at > org.drools.core.common.DefaultAgenda.fireNextItem(DefaultAgenda.java:964) > at > org.drools.core.common.DefaultAgenda.fireAllRules(DefaultAgenda.java:1234) > at > org.drools.core.impl.StatefulKnowledgeSessionImpl.fireAllRules(StatefulKnowledgeSessionImpl.java:1239) > at > org.drools.core.impl.StatefulKnowledgeSessionImpl.fireAllRules(StatefulKnowledgeSessionImpl.java:1212) > at com.sample.DroolsTest.main(DroolsTest.java:21) > Caused by: java.lang.NullPointerException > at > org.drools.core.beliefsystem.defeasible.DefeasibleBeliefSet.removeUndefeated(DefeasibleBeliefSet.java:295) > at > org.drools.core.beliefsystem.defeasible.DefeasibleBeliefSet.add(DefeasibleBeliefSet.java:126) > at > org.drools.core.beliefsystem.jtms.JTMSBeliefSystem.insert(JTMSBeliefSystem.java:52) > at > org.drools.core.beliefsystem.defeasible.DefeasibleBeliefSystem.insert(DefeasibleBeliefSystem.java:45) > at > org.drools.core.common.TruthMaintenanceSystem.addLogicalDependency(TruthMaintenanceSystem.java:136) > at > org.drools.core.common.TruthMaintenanceSystem.addLogicalDependency(TruthMaintenanceSystem.java:107) > at > org.drools.core.common.NamedEntryPoint.insert(NamedEntryPoint.java:234) > at > org.drools.core.impl.StatefulKnowledgeSessionImpl.insert(StatefulKnowledgeSessionImpl.java:1430) > at > org.drools.core.base.DefaultKnowledgeHelper.insertLogical(DefaultKnowledgeHelper.java:275) > at > org.drools.core.base.DefaultKnowledgeHelper.insertLogical(DefaultKnowledgeHelper.java:247) > at > com.sample.Rule_rule32132126114.defaultConsequence(Rule_rule32132126114.java:8) > at > com.sample.Rule_rule32132126114DefaultConsequenceInvokerGenerated.evaluate(Unknown > Source) > at > com.sample.Rule_rule32132126114DefaultConsequenceInvoker.evaluate(Unknown Source) > at > org.drools.core.common.DefaultAgenda.fireActivation(DefaultAgenda.java:1046) > ... 7 more > > > I believe I am using snapshot 6.1.0.201407170510 but I suspect the > precise version doesn't matter too much. > > In the above example, if you disable rule1 then the NPE doesn't happen. > Only doing one "two" fact insertion in the init rule likewise means the > NPE doesn't happen. I think the issue is something like rule3 does more > than one defeat on rule2's scoring on "wibble" fact, but rule1 still has > a say in the continuing existence of the "wibble" fact. > > Should I get a Jira log in and enter these well qualified bugs directly? > > Regards, > > Borris > > > > > > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users From kent.anderson at psware.com Tue Jul 22 17:46:35 2014 From: kent.anderson at psware.com (Kent Anderson) Date: Tue, 22 Jul 2014 14:46:35 -0700 Subject: [rules-users] DROOLS-516 - Continued Memory Leak problem Drools 6.1.0. Message-ID: <1F438071-3E59-416F-873E-08BAD0D9E016@psware.com> It appears there is another condition where Drools holds onto memory indefinitely. (See https://issues.jboss.org/browse/DROOLS-516) Use case: We have a set of rules designed to detect a heartbeat, then report when/if the heartbeat stops. Problem: In the normal case of a constant heartbeat, memory is retained in the JVM, even though the fact count in working memory is 1. The following rules produce this problem. I have attached a test project that demonstrates this problem. 600K events are inserted into the stream, then the test driver waits. After 10 seconds, the ?absence detected? rule fires. Requesting a GC via JMC has no effect. If you hit a key while the test driver is waiting, a new event will be added, which will cause the ?clear absence alarm? rule to fire. At this point some memory is freed automatically. Requesting another GC removes all memory and the JVM is back in its (nearly) new condition. We consider this a memory leak since the events are gone from working memory and will no longer be considered in any rule evaluations, but they are still active somewhere in the JVM. package org.drools.example.api.kiemodulemodel import demo.Event declare Event @role( event ) @timestamp( timestamp ) end declare Heartbeat @role( event ) @timestamp( event.timestamp ) event : Event end declare AbsenceDetected name : String end /* * This rule matches the first event * * NOTE: This stream requires the heartbeat event * to occur at least once before absence will be detected. */ rule "detect first heartbeat" when $event : Event() not ( Heartbeat() ) then delete($event); insert(new Heartbeat($event)); System.out.println("[DFH] Got event: " + $event.getEventId()); end /* * This rule matches every event and stores only the most recent * as the heartbeat. */ rule "keep latest heartbeat" when $heartbeat : Heartbeat() $event : Event() then delete($heartbeat); insert(new Heartbeat($event)); System.out.println("[KLH] Got event: " + $event.getEventId()); delete($event); end /* * This rule detects when a heartbeat stops for 10s */ rule "detect absence" duration(10s) when $heartbeat : Heartbeat() not ( Event() ) not (AbsenceDetected() ) then delete($heartbeat); insert(new AbsenceDetected("Absence")); System.out.println("[DA] Absence detected"); end /* * This rule detects when the heartbeat starts again after * absence has been detected. */ rule "clear absence alarm" when $heartbeat : Heartbeat() $absence : AbsenceDetected () then delete($absence); System.out.println("[CAA] Heartbeat restored"); end -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140722/ae94e30b/attachment-0003.html -------------- next part -------------- A non-text attachment was scrubbed... Name: Screen Shot 2014-07-22 at 2.21.16 PM.png Type: image/png Size: 90601 bytes Desc: not available Url : http://lists.jboss.org/pipermail/rules-users/attachments/20140722/ae94e30b/attachment-0001.png -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140722/ae94e30b/attachment-0004.html -------------- next part -------------- A non-text attachment was scrubbed... Name: memory-leak.zip Type: application/zip Size: 10416 bytes Desc: not available Url : http://lists.jboss.org/pipermail/rules-users/attachments/20140722/ae94e30b/attachment-0001.zip -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140722/ae94e30b/attachment-0005.html From dsotty at gmail.com Tue Jul 22 18:54:52 2014 From: dsotty at gmail.com (Davide Sottara) Date: Wed, 23 Jul 2014 00:54:52 +0200 Subject: [rules-users] DROOLS-516 - Continued Memory Leak problem Drools 6.1.0. In-Reply-To: <1F438071-3E59-416F-873E-08BAD0D9E016@psware.com> References: <1F438071-3E59-416F-873E-08BAD0D9E016@psware.com> Message-ID: <53CEEBBC.8060203@gmail.com> Ack'd and queued. On 07/22/2014 11:46 PM, Kent Anderson wrote: > It appears there is another condition where Drools holds onto memory > indefinitely. (See https://issues.jboss.org/browse/DROOLS-516) > > Use case: We have a set of rules designed to detect a heartbeat, then > report when/if the heartbeat stops. > > Problem: In the normal case of a constant heartbeat, memory is > retained in the JVM, even though the fact count in working memory is 1. > > The following rules produce this problem. I have attached a test > project that demonstrates this problem. 600K events are inserted into > the stream, then the test driver waits. After 10 seconds, the > "absence detected" rule fires. Requesting a GC via JMC has no effect. > If you hit a key while the test driver is waiting, a new event will > be added, which will cause the "clear absence alarm" rule to fire. At > this point some memory is freed automatically. Requesting another GC > removes all memory and the JVM is back in its (nearly) new condition. > > We consider this a memory leak since the events are gone from working > memory and will no longer be considered in any rule evaluations, but > they are still active somewhere in the JVM. > > packageorg.drools.example.api.kiemodulemodel > > import demo.Event > > declareEvent > @role( event ) > @timestamp( timestamp ) > end > > declare Heartbeat > @role( event ) > @timestamp( event.timestamp ) > event : Event > end > > declare AbsenceDetected > name : String > end > > /* > * This rule matches the first event > * > * NOTE: This stream requires the heartbeat event > * to occur at least once before absence will be detected. > */ > rule"detect first heartbeat" > when > $event : Event() > not ( Heartbeat() ) > then > delete($event); > insert(new Heartbeat($event)); > System.out.println("[DFH] Got event: " + $event.getEventId()); > end > > > /* > * This rule matches every event and stores only the most recent > * as the heartbeat. > */ > rule"keep latest heartbeat" > when > $heartbeat : Heartbeat() > $event : Event() > then > delete($heartbeat); > insert(new Heartbeat($event)); > System.out.println("[KLH] Got event: " + $event.getEventId()); > delete($event); > end > > > /* > * This rule detects when a heartbeat stops for 10s > */ > rule"detect absence" > duration(10s) > when > $heartbeat : Heartbeat() > not ( Event() ) > not (AbsenceDetected() ) > then > delete($heartbeat); > insert(new AbsenceDetected("Absence")); > System.out.println("[DA] Absence detected"); > end > > /* > * This rule detects when the heartbeat starts again after > * absence has been detected. > */ > rule"clear absence alarm" > when > $heartbeat : Heartbeat() > $absence : AbsenceDetected () > then > delete($absence); > System.out.println("[CAA] Heartbeat restored"); > end > > > > > > > > > > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140723/92b0bbd5/attachment.html From ilguapo at gmail.com Tue Jul 22 20:55:22 2014 From: ilguapo at gmail.com (ilguapo) Date: Tue, 22 Jul 2014 17:55:22 -0700 (PDT) Subject: [rules-users] Including repository in a WAR file Message-ID: <1406076922671-4030450.post@n3.nabble.com> I'm using Drools 5.3.0 I'd like to find out if the following scenario is possible: - Include the repository_export.zip file inside my application WAR file. This way, Guvnor won't be necessary. - Provide a special upload page just like Guvnor's Import/Export to upload a completely new repository_export.zip file when rules have changed. I haven't been able to find a way to read a repository_export.zip file with the current API. They only talk about drl, pkg, etc..etc but no zip files. I could potentially take the zip file, unzip it to an XML and maybe read this file?? Any ideas would be really helpful. Regards, Ilguapo -- View this message in context: http://drools.46999.n3.nabble.com/Including-repository-in-a-WAR-file-tp4030450.html Sent from the Drools: User forum mailing list archive at Nabble.com. From salaboy at gmail.com Wed Jul 23 03:40:36 2014 From: salaboy at gmail.com (Mauricio Salatino) Date: Wed, 23 Jul 2014 08:40:36 +0100 Subject: [rules-users] Including repository in a WAR file In-Reply-To: <1406076922671-4030450.post@n3.nabble.com> References: <1406076922671-4030450.post@n3.nabble.com> Message-ID: Hi, I don't think that it will be possible the repository is a JCR repository in 5.3, so there is no point in storing all the meta information from the repository if the only thing you need are the rules. You can always ship the rules inside the web application, provide a way to upload new rules when needed and regenerate the sessions using the new rules. Why do you want to have all the repo? On Wed, Jul 23, 2014 at 1:55 AM, ilguapo wrote: > I'm using Drools 5.3.0 > > > I'd like to find out if the following scenario is possible: > > - Include the repository_export.zip file inside my application WAR file. > This way, Guvnor won't be necessary. > - Provide a special upload page just like Guvnor's Import/Export to upload > a > completely new repository_export.zip file when rules have changed. > > I haven't been able to find a way to read a repository_export.zip file with > the current API. They only talk about drl, pkg, etc..etc but no zip files. > I could potentially take the zip file, unzip it to an XML and maybe read > this file?? > > Any ideas would be really helpful. > > Regards, > Ilguapo > > > > -- > View this message in context: > http://drools.46999.n3.nabble.com/Including-repository-in-a-WAR-file-tp4030450.html > Sent from the Drools: User forum mailing list archive at Nabble.com. > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users > -- - MyJourney @ http://salaboy.com - Co-Founder @ http://www.jugargentina.org - Co-Founder @ http://www.jbug.com.ar - Salatino "Salaboy" Mauricio - -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140723/f1c576df/attachment.html From toni.rikkola at gmail.com Wed Jul 23 03:41:33 2014 From: toni.rikkola at gmail.com (Toni Rikkola) Date: Wed, 23 Jul 2014 10:41:33 +0300 Subject: [rules-users] [drools-wb] how to move an asset to another package ? In-Reply-To: <1406024712969-4030422.post@n3.nabble.com> References: <1406024712969-4030422.post@n3.nabble.com> Message-ID: <1406101293.3353.1.camel@localhost.localdomain> Looks like the move is indeed missing. For now you can clone the git repo, do the refactoring and push the changes back to the workbench. Toni Rikkola On ti, 2014-07-22 at 03:25 -0700, jps wrote: > Hello, > > I'm in the process of refactoring the different packages in my project. > How can I move an asset (a guided decision table in this case) from its > current package to a new package ? > It seems there's no button or action for that in drools-wb ? > > Regards. > --jps > > > > -- > View this message in context: http://drools.46999.n3.nabble.com/drools-wb-how-to-move-an-asset-to-another-package-tp4030422.html > Sent from the Drools: User forum mailing list archive at Nabble.com. > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users From toni.rikkola at gmail.com Wed Jul 23 03:51:46 2014 From: toni.rikkola at gmail.com (Toni Rikkola) Date: Wed, 23 Jul 2014 10:51:46 +0300 Subject: [rules-users] Including repository in a WAR file In-Reply-To: <1406076922671-4030450.post@n3.nabble.com> References: <1406076922671-4030450.post@n3.nabble.com> Message-ID: <1406101906.3353.9.camel@localhost.localdomain> This is possible, but you will need to add the ability to compile the repository_export.zip. This means you need to reuse a lot of the Guvnor codes for resolving enums, package imports, guided rules and so on. If I guess our needs correctly. You are better taking a different approach. Build the repository using Guvnor and then add the import function for Drools packages. This way you only need the Drools core in your own application for running these packages and updating them is easy. Toni Rikkola On ti, 2014-07-22 at 17:55 -0700, ilguapo wrote: > I'm using Drools 5.3.0 > > > I'd like to find out if the following scenario is possible: > > - Include the repository_export.zip file inside my application WAR file. > This way, Guvnor won't be necessary. > - Provide a special upload page just like Guvnor's Import/Export to upload a > completely new repository_export.zip file when rules have changed. > > I haven't been able to find a way to read a repository_export.zip file with > the current API. They only talk about drl, pkg, etc..etc but no zip files. > I could potentially take the zip file, unzip it to an XML and maybe read > this file?? > > Any ideas would be really helpful. > > Regards, > Ilguapo > > > > -- > View this message in context: http://drools.46999.n3.nabble.com/Including-repository-in-a-WAR-file-tp4030450.html > Sent from the Drools: User forum mailing list archive at Nabble.com. > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users From ilguapo at gmail.com Wed Jul 23 09:39:38 2014 From: ilguapo at gmail.com (ilguapo) Date: Wed, 23 Jul 2014 06:39:38 -0700 (PDT) Subject: [rules-users] Including repository in a WAR file In-Reply-To: <1406101906.3353.9.camel@localhost.localdomain> References: <1406076922671-4030450.post@n3.nabble.com> <1406101906.3353.9.camel@localhost.localdomain> Message-ID: <1406122778076-4030458.post@n3.nabble.com> Thank you for replying Toni and Salaboy. This is the reason why we want to do that: -We already have an application that uses Guvnor in production. The problem is Guvnor is hosted on a different machine which we are losing therefore we thought about an idea of completely eliminating Guvnor by including the repository in the WAR so that we could read it the first time the application starts. As you know, this is being done by pointing to the Guvnor URL at this time. -We actually wanted to leave Guvnor in the dev environment so that developers could add more rules to the application whenever necessary by providing an Import feature to read the repository_export.zip file into the application to replace the old repository. -If we do this, we will only need Guvnor in the dev environment which is controlled by us and will be eliminated from all other environments. (Will reduce a lot of paper work at a government site) I like Toni's idea of building the repository using Guvnor in the dev environment but how do you read the repository the first time the app starts? This is done now by getting the package from Guvnor thru a URL. That was the only reason to store the repository inside the WAR file so that the rules could be read at initialization time. Any pointers would be really appreciated especially how to update the package which according to Toni is easy :-) Regards, Ilguapo -- View this message in context: http://drools.46999.n3.nabble.com/Including-repository-in-a-WAR-file-tp4030450p4030458.html Sent from the Drools: User forum mailing list archive at Nabble.com. From jps at jps.ch Wed Jul 23 12:27:46 2014 From: jps at jps.ch (jps) Date: Wed, 23 Jul 2014 09:27:46 -0700 (PDT) Subject: [rules-users] Project Explorer has dissappeared in KIE Workbench In-Reply-To: <1402484249840-4029975.post@n3.nabble.com> References: <1390223441353-4027767.post@n3.nabble.com> <1402484249840-4029975.post@n3.nabble.com> Message-ID: <1406132866722-4030460.post@n3.nabble.com> I had the same problem today on kie-drools-wb-distribution-wars-6.0.1.Final-jboss-as7.0 ... Googling a while ... I found this thread with the working workaround for me : https://community.jboss.org/thread/237501 --jps -- View this message in context: http://drools.46999.n3.nabble.com/Project-Explorer-has-dissappeared-in-KIE-Workbench-tp4027767p4030460.html Sent from the Drools: User forum mailing list archive at Nabble.com. From jps at jps.ch Wed Jul 23 12:34:49 2014 From: jps at jps.ch (jps) Date: Wed, 23 Jul 2014 09:34:49 -0700 (PDT) Subject: [rules-users] [drools-wb] how to move an asset to another package ? In-Reply-To: <1406101293.3353.1.camel@localhost.localdomain> References: <1406024712969-4030422.post@n3.nabble.com> <1406101293.3353.1.camel@localhost.localdomain> Message-ID: <1406133289398-4030461.post@n3.nabble.com> Hi, Thank you for the reply and the workaround. Will you add this kind of functionnality in the future ? We expect to deploy drools-wb to business users so they have a "business-user-friendly" environment to author their rules. But you know - we can't ask our business users to do a git clone + git push :) This leads me to other questions about git operations, but that's going to be another post. Regards, --jps -- View this message in context: http://drools.46999.n3.nabble.com/drools-wb-how-to-move-an-asset-to-another-package-tp4030422p4030461.html Sent from the Drools: User forum mailing list archive at Nabble.com. From chieu.nguyen at verizon.com Wed Jul 23 14:55:00 2014 From: chieu.nguyen at verizon.com (Nguyen, Chieu X) Date: Wed, 23 Jul 2014 14:55:00 -0400 Subject: [rules-users] Getting Errors Deploying kie-drools-wb-distribution-6.0.1.Final Message-ID: I am trying to deploy the kie-drools-wb on Tomcat7, but I keep getting these errors. SEVERE: Error listenerStart Jul 23, 2014 10:03:26 AM org.apache.catalina.core.StandardContext startInternal SEVERE: Context [/rule-mgnt-6.0.1] startup failed due to previous errors Jul 23, 2014 10:03:26 AM org.apache.catalina.loader.WebappClassLoader clearReferencesThreads SEVERE: The web application [/rule-mgnt-6.0.1] appears to have started a thread named [pool-4-thread-1] but has failed to stop it. This is very likely to create a memory leak. Jul 23, 2014 10:03:26 AM org.apache.catalina.loader.WebappClassLoader checkThreadLocalMapForLeaks SEVERE: The web application [/rule-mgnt-6.0.1] created a ThreadLocal with key of type [org.jboss.solder.servlet.beanManager.ServletContextAttributeProvider$1] (value [org.jboss.solder.servlet.beanManager.ServletContextAttributeProvider$1 at 323acc6f]) and a value of type [org.apache.catalina.core.ApplicationContextFacade] (value [org.apache.catalina.core.ApplicationContextFacade at 3243a52c]) but failed to remove it when the web application was stopped. Threads are going to be renewed over time to try and avoid a probable memory leak. Jul 23, 2014 10:03:26 AM org.apache.catalina.loader.WebappClassLoader checkThreadLocalMapForLeaks SEVERE: The web application [/rule-mgnt-6.0.1] created a ThreadLocal with key of type [org.jboss.errai.config.util.ClassScanner$1] (value [org.jboss.errai.config.util.ClassScanner$1 at 7711057b]) and a value of type [java.lang.Boolean] (value [true]) but failed to remove it when the web application was stopped. Threads are going to be renewed over time to try and avoid a probable memory leak. I have follow the instructions provided from this link:http://drools.46999.n3.nabble.com/rules-users-Problems-deploying-war-td4029202.html 1. I have added these 3 jar files in my tomcat_home/lib directory a. javax.security.jacc-api-1.5.jar b. kie-tomcat-integration-6.1.0.CR2.jar c. slf4j-api-1.7.7.jar 2. Modified the server.xml in tomcat_home/conf directory by adding the line below in the tag 3. Added the following in tomcat-users.xml 4. Delete org.uberfire.security.auth.AuthenticationSource inside WEB-INF/classes/META-INF/services 5. Rename org.uberfire.security.auth.AuthenticationSource-TOMCAT-JEE-SECURITY to org.uberfire.security.auth.AuthenticationSource inside WEB-INF/classes/META-INF/services 6. Created a setenv.sh in tomcat_home/bin directory, which has this as it content export JAVA_OPTS="-Dfile.encoding=UTF-8 -Xms128m -Xmx1024m -XX:PermSize=64m -XX:MaxPermSize=256m" 7. Finally, uncomment the section in web.xml from the WAR file. I am using Tomcat 7.0.54 and running on 64 bit Linux server. I would appreciate any suggestions. Thank You, Chieu Nguyen Chieu.nguyen at verizon.com -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140723/268a65ea/attachment.html From apeksha.gupta at asurion.com Wed Jul 23 15:53:22 2014 From: apeksha.gupta at asurion.com (LearningDrool) Date: Wed, 23 Jul 2014 12:53:22 -0700 (PDT) Subject: [rules-users] Unable to build index of kmodule.xml from Kie project jar In-Reply-To: <1404691060208-4030253.post@n3.nabble.com> References: <1404691060208-4030253.post@n3.nabble.com> Message-ID: <1406145202206-4030463.post@n3.nabble.com> Hi, I am getting the same error as described below. I was able to run and fire rules using a standalone application in my project but when I try to call the same rules through a dynamic web app, it throws the below errors : Code : KieServices ks = KieServices.Factory.get(); KieContainer kc = ks.getKieClasspathContainer(); StatelessKieSession ksession = kc.newStatelessKieSession("TestDRL"); ksession.addEventListener( new DebugAgendaEventListener() ); ksession.execute() The Kmodule File is defined as below and is placed in the /Resources/META-INF folder Error : 0:05:58.692 [http-bio-8443-exec-4] INFO o.d.c.k.b.impl.ClasspathKieProject - Found kmodule: jar:file:/C:/test/web/actions/bard/WEB-INF/lib/bard.jar!/META-INF/kmodule.xml 10:05:58.706 [http-bio-8443-exec-4] DEBUG o.d.c.k.b.impl.ClasspathKieProject - KieModule URL type=jar url=/C:/test/web/actions/bard/WEB-INF/lib/bard.jar 10:06:05.834 [http-bio-8443-exec-4] ERROR o.d.c.k.b.impl.ClasspathKieProject - Unable to load pom.properties from/C:/test/web/actions/bard/WEB-INF/lib/bard.jar null 10:06:05.845 [http-bio-8443-exec-4] ERROR o.d.c.k.b.impl.ClasspathKieProject - Unable to load pom.properties from/C:/test/web/actions/bard/WEB-INF/lib/bard.jar 10:06:05.856 [http-bio-8443-exec-4] ERROR o.d.c.k.b.impl.ClasspathKieProject - Unable to build index of kmodule.xml url=jar:file:/C:/test/web/actions/bard/WEB-INF/lib/bard.jar!/META-INF/kmodule.xml null Also I was able to call the DRL file using the below code in my project: KnowledgeBuilder kbuilder = KnowledgeBuilderFactory.newKnowledgeBuilder(); Resource ruleFile = ResourceFactory.newUrlResource(getClass().getClassLoader().getResource("test1.drl")); kbuilder.add(ruleFile, ResourceType.DRL); KnowledgeBase kbase = kbuilder.newKnowledgeBase(); kbase.addKnowledgePackages(kbuilder.getKnowledgePackages()); I had placed the test1.drl file in the Tomcat folder Why are the Ksessions not being loaded when using the Kmodule.xml. Any ideas? -- View this message in context: http://drools.46999.n3.nabble.com/Unable-to-build-index-of-kmodule-xml-from-Kie-project-jar-tp4030253p4030463.html Sent from the Drools: User forum mailing list archive at Nabble.com. From borris at chaos.org.uk Wed Jul 23 16:56:32 2014 From: borris at chaos.org.uk (Borris) Date: Wed, 23 Jul 2014 21:56:32 +0100 Subject: [rules-users] Are globals not permitted with queries? In-Reply-To: <53CE8E6A.40708@gmail.com> References: <53CE87BB.7050203@chaos.org.uk> <53CE8E6A.40708@gmail.com> Message-ID: <53D02180.7070504@chaos.org.uk> I want to pass strings around between rules and queries to control their actions and provide control values. I know I can just use "literals" but I know from past experience that that leads to small typos not being detected (either at compile time or run time) and leads to nasty subtle errors down the line. For rules, you can over come this with a bunch of public static final String in a class (I call mine Consts) - and then any spelling mistakes become compile time issues as you are matching against a variable/constant name and if you spell this right then you know you get the right control string. But does anyone have a technique that works with queries? I know lots of the docn talks about queries being things you can invoke from Java. But I use queries in my rules (they have a private stack and support recursion that rules don't quite do in the same way). Does anyone have a clever technique they've used in the past? Thanks Borris On 22/07/2014 17:16, Davide Sottara wrote: > The case may not be supported, but even then, it should be reported as > a compilation error, not as a NPE > I'll investigate and report back later > Thanks > Davide > > On 07/22/2014 05:48 PM, Borris wrote: >> I was experimenting with ways of avoiding having to put literal strings >> into my rules (it is very fragile and bugs can be silent for a long >> time). I tried declaring a global and then tried supplying it to a >> query. This generates a backtrace during the newKieSession. A simple >> example to provoke the problem: >> >> >> KieServices ks = KieServices.Factory.get(); >> KieContainer kContainer = ks.getKieClasspathContainer(); >> KieSession kSession = >> kContainer.newKieSession("ksession-rules"); >> >> kSession.setGlobal("AString", "Hello World"); >> >> kSession.fireAllRules(); >> >> >> >> package com.sample >> >> global java.lang.String AString; >> >> declare Thing >> name: String @key >> end >> >> rule init >> when >> then >> insert( new Thing( AString ) ); >> end >> >> query test(String $in) >> Thing( $in; ) >> end >> >> rule spot >> when >> test( "Hello World"; ) >> Thing( "Hello World"; ) >> test( AString; ) >> Thing( AString; ) >> then >> System.out.println("found msg\n"); >> end >> >> >> java.lang.NullPointerException >> at >> org.drools.core.rule.LogicTransformer.processElement(LogicTransformer.java:243) >> at >> org.drools.core.rule.LogicTransformer.processElement(LogicTransformer.java:263) >> at >> org.drools.core.rule.LogicTransformer.fixClonedDeclarations(LogicTransformer.java:134) >> at >> org.drools.core.rule.LogicTransformer.transform(LogicTransformer.java:99) >> at >> org.drools.core.definitions.rule.impl.RuleImpl.getTransformedLhs(RuleImpl.java:560) >> at >> org.drools.core.reteoo.builder.ReteooRuleBuilder.addRule(ReteooRuleBuilder.java:105) >> at org.drools.core.reteoo.ReteooBuilder.addRule(ReteooBuilder.java:100) >> at >> org.drools.core.impl.KnowledgeBaseImpl.addRule(KnowledgeBaseImpl.java:1455) >> at >> org.drools.core.impl.KnowledgeBaseImpl.addRule(KnowledgeBaseImpl.java:1435) >> at >> org.drools.core.impl.KnowledgeBaseImpl.addPackages(KnowledgeBaseImpl.java:838) >> at >> org.drools.core.impl.KnowledgeBaseImpl.addKnowledgePackages(KnowledgeBaseImpl.java:266) >> at >> org.drools.compiler.kie.builder.impl.KieContainerImpl.createKieBase(KieContainerImpl.java:412) >> at >> org.drools.compiler.kie.builder.impl.KieContainerImpl.getKieBase(KieContainerImpl.java:346) >> at >> org.drools.compiler.kie.builder.impl.KieContainerImpl.newKieSession(KieContainerImpl.java:498) >> at >> org.drools.compiler.kie.builder.impl.KieContainerImpl.newKieSession(KieContainerImpl.java:469) >> at com.sample.DroolsTest.main(DroolsTest.java:17) >> >> >> The 3rd action in the spot rule causes the null exception during >> initialise, if it is present. Comment out just that line and no >> exceptions happen and behaviour is as expected. >> >> Are globals permitted in the way I am trying to use them, as a parameter >> to a query? >> >> Borris >> >> >> >> >> _______________________________________________ >> rules-users mailing list >> rules-users at lists.jboss.org >> https://lists.jboss.org/mailman/listinfo/rules-users >> > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users From borris at chaos.org.uk Wed Jul 23 16:58:58 2014 From: borris at chaos.org.uk (Borris) Date: Wed, 23 Jul 2014 21:58:58 +0100 Subject: [rules-users] Defeasible: NPE: with multiple @Defeasible In-Reply-To: <1FE456CF-C308-4AE5-A014-EBAB4A9C23A2@codehaus.org> References: <53CEBE2B.4070903@chaos.org.uk> <1FE456CF-C308-4AE5-A014-EBAB4A9C23A2@codehaus.org> Message-ID: <53D02212.6040307@chaos.org.uk> On 22/07/2014 22:44, Mark Proctor wrote: > Stack trace shows the error: > org.drools.core.beliefsystem.defeasible.DefeasibleBeliefSet.removeUndefeated(DefeasibleBeliefSet.java:295) > https://github.com/sotty/drools/blob/master/drools-core/src/main/java/org/drools/core/beliefsystem/defeasible/DefeasibleBeliefSet.java > > Maybe have a go fixing it yourself? And submit the fix with a unit test, as a pull request? > http://docs.jboss.org/drools/release/5.6.0.Final/droolsjbpm-introduction-docs/html/gettingstarted.html > I might well have a go, but there's a whole bunch of learning I need to do before I can submit my first candidate patch. So don't expect something too quickly. Borris From salaboy at gmail.com Wed Jul 23 17:45:54 2014 From: salaboy at gmail.com (Mauricio Salatino) Date: Wed, 23 Jul 2014 22:45:54 +0100 Subject: [rules-users] Including repository in a WAR file In-Reply-To: <1406122778076-4030458.post@n3.nabble.com> References: <1406076922671-4030450.post@n3.nabble.com> <1406101906.3353.9.camel@localhost.localdomain> <1406122778076-4030458.post@n3.nabble.com> Message-ID: You can build the PKGs in guvnor and then just move the PKGs to a accesible server by the app that will load the rules in those packages. That will do the work IMO. Regards On Wed, Jul 23, 2014 at 2:39 PM, ilguapo wrote: > Thank you for replying Toni and Salaboy. > > This is the reason why we want to do that: > > -We already have an application that uses Guvnor in production. The > problem > is Guvnor is hosted on a different machine which we are losing therefore we > thought about an idea of completely eliminating Guvnor by including the > repository in the WAR so that we could read it the first time the > application starts. As you know, this is being done by pointing to the > Guvnor URL at this time. > > -We actually wanted to leave Guvnor in the dev environment so that > developers could add more rules to the application whenever necessary by > providing an Import feature to read the repository_export.zip file into the > application to replace the old repository. > > -If we do this, we will only need Guvnor in the dev environment which is > controlled by us and will be eliminated from all other environments. (Will > reduce a lot of paper work at a government site) > > I like Toni's idea of building the repository using Guvnor in the dev > environment but how do you read the repository the first time the app > starts? This is done now by getting the package from Guvnor thru a URL. > That was the only reason to store the repository inside the WAR file so > that > the rules could be read at initialization time. > > Any pointers would be really appreciated especially how to update the > package which according to Toni is easy :-) > > Regards, > Ilguapo > > > > > > > > -- > View this message in context: > http://drools.46999.n3.nabble.com/Including-repository-in-a-WAR-file-tp4030450p4030458.html > Sent from the Drools: User forum mailing list archive at Nabble.com. > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users > -- - MyJourney @ http://salaboy.com - Co-Founder @ http://www.jugargentina.org - Co-Founder @ http://www.jbug.com.ar - Salatino "Salaboy" Mauricio - -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140723/35031d5f/attachment.html From mproctor at codehaus.org Wed Jul 23 18:43:48 2014 From: mproctor at codehaus.org (Mark Proctor) Date: Wed, 23 Jul 2014 23:43:48 +0100 Subject: [rules-users] Defeasible: NPE: with multiple @Defeasible In-Reply-To: <53D02212.6040307@chaos.org.uk> References: <53CEBE2B.4070903@chaos.org.uk> <1FE456CF-C308-4AE5-A014-EBAB4A9C23A2@codehaus.org> <53D02212.6040307@chaos.org.uk> Message-ID: On 23 Jul 2014, at 21:58, Borris wrote: > > On 22/07/2014 22:44, Mark Proctor wrote: >> Stack trace shows the error: >> org.drools.core.beliefsystem.defeasible.DefeasibleBeliefSet.removeUndefeated(DefeasibleBeliefSet.java:295) >> https://github.com/sotty/drools/blob/master/drools-core/src/main/java/org/drools/core/beliefsystem/defeasible/DefeasibleBeliefSet.java >> >> Maybe have a go fixing it yourself? And submit the fix with a unit test, as a pull request? >> http://docs.jboss.org/drools/release/5.6.0.Final/droolsjbpm-introduction-docs/html/gettingstarted.html >> > > I might well have a go, but there's a whole bunch of learning I need to > do before I can submit my first candidate patch. So don't expect > something too quickly. We are available for real time chat on irc, if you need help. http://drools.jboss.org/irc Either way best way to start is to submit a compact self contained unit test, to show the failure, as a pull request. Don?t forget to @Ignore it, so it won?t break our build and we can fix it later: https://github.com/droolsjbpm/drools/blob/master/drools-compiler/src/test/java/org/drools/compiler/beliefsystem/defeasible/DefeasibilityTest.java Mark > > Borris > > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users From shameerind at gmail.com Thu Jul 24 01:09:31 2014 From: shameerind at gmail.com (Shameer E S) Date: Thu, 24 Jul 2014 10:39:31 +0530 Subject: [rules-users] Fwd: Processing xml with control characters in droolserver In-Reply-To: References: Message-ID: Hi, is there any workaround available for below issue? -Shameer ---------- Forwarded message ---------- From: Shameer E S Date: Thu, Jul 17, 2014 at 3:09 PM Subject: Processing xml with control characters in droolserver To: rules-users at lists.jboss.org Hi, I am sending xml to initiate rule execution in drools server 5.4. When there is control character in the xml, it is failing with following error, is there any way to overcome this? 16 Jul 2014 00:03:28,852 ERROR [org.apache.camel.processor.DefaultErrorHandler] (http--0.0.0.0-8080-239) Failed delivery for exchangeId: ID-svl-prod-prwf04-juniper-net-51091-1404737660521-0-3260214. Exhausted after delivery attempt: 1 caught: com.thoughtworks.xstream.converters.ConversionException: : Illegal character ((CTRL-CHAR, code 8)) [note: in XML 1.1, it could be included via entity expansion] at [row,col {unknown-source}]: [30,126] : : Illegal character ((CTRL-CHAR, code 8)) [note: in XML 1.1, it could be included via entity expansion] at [row,col {unknown-source}]: [30,126] ---- Debugging information ---- message : : Illegal character ((CTRL-CHAR, code 8)) [note: in XML 1.1, it could be included via entity expansion] at [row,col {unknown-source}]: [30,126] cause-exception : com.thoughtworks.xstream.io.StreamException cause-message : : Illegal character ((CTRL-CHAR, code 8)) [note: in XML 1.1, it could be included via entity expansion] at [row,col {unknown-source}]: [30,126] class : java.lang.String required-type : java.lang.String converter-type : com.thoughtworks.xstream.converters.SingleValueConverterWrapper wrapped-converter : com.thoughtworks.xstream.converters.basic.StringConverter path : /batch-execution/set-global[7]/map/entry[50]/string[2] line number : 2 class[1] : java.util.HashMap converter-type[1] : com.thoughtworks.xstream.converters.collections.MapConverter class[2] : org.drools.command.runtime.SetGlobalCommand converter-type[2] : org.drools.runtime.help.impl.XStreamXML$SetGlobalConverter class[3] : org.drools.command.runtime.BatchExecutionCommandImpl converter-type[3] : com.thoughtworks.xstream.converters.reflection.ReflectionConverter version : null Thanks & Regards, Shameer -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140724/3a09cc35/attachment.html From ephemeris.lappis at gmail.com Thu Jul 24 03:21:56 2014 From: ephemeris.lappis at gmail.com (Ephemeris Lappis) Date: Thu, 24 Jul 2014 00:21:56 -0700 (PDT) Subject: [rules-users] Drools Fusion (CEP) & event life cycle Message-ID: <1406186516229-4030471.post@n3.nabble.com> Hello. I'm testing event processing in Drools, and after some basic tests, I have some questions about event life cycle management. According to the documentation, in stream mode, events may be automatically discarded by the engine when no rule, currently or in the future, applies to them. In the following rule set (at the end of my post), the rule named "Processing new alert event" is expected to be executed when a new 'alert' notification event arrives and no previous alert exists. After an elementary test, the first matching notification produces the expected behavior and generates the Alert. But if a second matching notification is inserted, the rule is ignored as expected, since the Alert is already set, but the event object seems to be put durably in memory. When a 'stop' notification is inserted, the Alert object is cleared by the rule "Processing stop event after alert", as expected, but the second 'alert' notification that should be forgotten is raised from the memory and the first rule is fired again, creating an undesired second Alert. I've tried a workaround adding an "opposite rule" to check the processing of an 'alert' notification when there is a current Alert. As at the moment the notification object is inserted the two rules are candidate in the agenda, both are executed. I suppose I could try, for example, adding salience values to make the rules execute in a deterministic order... As you can see, I've added explicit deletion of the notification objects in the rules, and all seems to work as needed. But it seems really a bit cimplicated, and contradictory with the documentation... What did I miss ? Thanks for your help. Regards? Here the rule set : -- View this message in context: http://drools.46999.n3.nabble.com/Drools-Fusion-CEP-event-life-cycle-tp4030471.html Sent from the Drools: User forum mailing list archive at Nabble.com. From colorful.world.18 at gmail.com Thu Jul 24 04:15:53 2014 From: colorful.world.18 at gmail.com (colorful.world) Date: Thu, 24 Jul 2014 01:15:53 -0700 (PDT) Subject: [rules-users] [optaplanner] creating dynamic fact classes(planning entity and planning variables) in Optaplanner Message-ID: <1406189753515-4030473.post@n3.nabble.com> Hi guys, Recently, I have successfully implemented drools project with dynamic domain attributes(using declare facts type in drl) and dynamic rules(using drl rule string) which allows the users to easily add and change the domain classes and rules from GUI. But, when we come to have auto allocation with this requirement (using OptaPlanner), we are having difficulties to achieve this dynamic classes feature. So, is there a way we can define like planning entities and variables in 'declare fact type' (or) has anyone achieved this kind of mechanism using Optaplanner?? Thanks in advance for your time and suggestions. -- View this message in context: http://drools.46999.n3.nabble.com/optaplanner-creating-dynamic-fact-classes-planning-entity-and-planning-variables-in-Optaplanner-tp4030473.html Sent from the Drools: User forum mailing list archive at Nabble.com. From ge0ffrey.spam at gmail.com Thu Jul 24 04:40:18 2014 From: ge0ffrey.spam at gmail.com (Geoffrey De Smet) Date: Thu, 24 Jul 2014 10:40:18 +0200 Subject: [rules-users] [optaplanner] creating dynamic fact classes(planning entity and planning variables) in Optaplanner In-Reply-To: <1406189753515-4030473.post@n3.nabble.com> References: <1406189753515-4030473.post@n3.nabble.com> Message-ID: <53D0C672.2040305@gmail.com> (this is indeed a Drools question) It's a matter of adding Java annotations on those declared fact types. I don't know if Drools supports that. It would be nice if we have an example to demonstrate that. Feel free to open a jira on OptaPlanner that we should create such an example. On 24-07-14 10:15, colorful.world wrote: > Hi guys, > > Recently, I have successfully implemented drools project with dynamic domain > attributes(using declare facts type in drl) and dynamic rules(using drl rule > string) which allows the users to easily add and change the domain classes > and rules from GUI. > > But, when we come to have auto allocation with this requirement (using > OptaPlanner), we are having difficulties to achieve this dynamic classes > feature. > > So, is there a way we can define like planning entities and variables in > 'declare fact type' (or) > has anyone achieved this kind of mechanism using Optaplanner?? > > Thanks in advance for your time and suggestions. > > > > > > -- > View this message in context: http://drools.46999.n3.nabble.com/optaplanner-creating-dynamic-fact-classes-planning-entity-and-planning-variables-in-Optaplanner-tp4030473.html > Sent from the Drools: User forum mailing list archive at Nabble.com. > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users > From zahid.ahmed at emirates.com Thu Jul 24 04:56:51 2014 From: zahid.ahmed at emirates.com (Zahid Ahmed) Date: Thu, 24 Jul 2014 08:56:51 +0000 Subject: [rules-users] Drools Performance Analysis Required Message-ID: Hi, I need to know the Drools capacity to execute the rules. I need to know how many rules it can execute at a time and with how many facts. I need to know the memory stats. We are planning for a central rules execution server with executing around 10,000 rules per request and requests per minute can be ~300. Has anyone done the benchmarking. Or is there any scalable solution that can be implemented. -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140724/58aee7b2/attachment.html From colorful.world.18 at gmail.com Thu Jul 24 05:19:00 2014 From: colorful.world.18 at gmail.com (colorful.world) Date: Thu, 24 Jul 2014 02:19:00 -0700 (PDT) Subject: [rules-users] [optaplanner] creating dynamic fact classes(planning entity and planning variables) in Optaplanner In-Reply-To: <53D0C672.2040305@gmail.com> References: <1406189753515-4030473.post@n3.nabble.com> <53D0C672.2040305@gmail.com> Message-ID: <1406193540659-4030476.post@n3.nabble.com> Hi Geoffrey, Thanks for reply. What we use for declaring fact type is just to have class declaration in drl file. Since this drl string is loaded at runtime, we are able to have dynamic class structures and drools rules from DB. So, I am wondering if we can have dynamic Planning Entity and Variables in Optaplanner. Please share, if you have another similar ideas to achieve this. -- View this message in context: http://drools.46999.n3.nabble.com/optaplanner-creating-dynamic-fact-classes-planning-entity-and-planning-variables-in-Optaplanner-tp4030473p4030476.html Sent from the Drools: User forum mailing list archive at Nabble.com. From dsotty at gmail.com Thu Jul 24 05:27:31 2014 From: dsotty at gmail.com (Davide Sottara) Date: Thu, 24 Jul 2014 11:27:31 +0200 Subject: [rules-users] [optaplanner] creating dynamic fact classes(planning entity and planning variables) in Optaplanner In-Reply-To: <1406193540659-4030476.post@n3.nabble.com> References: <1406189753515-4030473.post@n3.nabble.com> <53D0C672.2040305@gmail.com> <1406193540659-4030476.post@n3.nabble.com> Message-ID: <53D0D183.2090502@gmail.com> Declared types support annotations. You'll have to import it package my.drl; import my.SomeAnnotation; declare Foo @SomeAnnotation bar : String end When the declare is processed, the class builder will try to resolve the annotation and, if found, will wire it to the class being generated. If this does not work, it's a bug, so please report it as such. Davide On 07/24/2014 11:19 AM, colorful.world wrote: > Hi Geoffrey, > > Thanks for reply. > What we use for declaring fact type is just to have class declaration in drl > file. Since this drl string is loaded at runtime, we are able to have > dynamic class structures and drools rules from DB. > So, I am wondering if we can have dynamic Planning Entity and Variables in > Optaplanner. > Please share, if you have another similar ideas to achieve this. > > > > -- > View this message in context: http://drools.46999.n3.nabble.com/optaplanner-creating-dynamic-fact-classes-planning-entity-and-planning-variables-in-Optaplanner-tp4030473p4030476.html > Sent from the Drools: User forum mailing list archive at Nabble.com. > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users > From ge0ffrey.spam at gmail.com Thu Jul 24 05:36:50 2014 From: ge0ffrey.spam at gmail.com (Geoffrey De Smet) Date: Thu, 24 Jul 2014 11:36:50 +0200 Subject: [rules-users] [optaplanner] creating dynamic fact classes(planning entity and planning variables) in Optaplanner In-Reply-To: <1406193540659-4030476.post@n3.nabble.com> References: <1406189753515-4030473.post@n3.nabble.com> <53D0C672.2040305@gmail.com> <1406193540659-4030476.post@n3.nabble.com> Message-ID: On 24-07-14 11:19, colorful.world wrote: > Hi Geoffrey, > > Thanks for reply. > What we use for declaring fact type is just to have class declaration in drl > file. Since this drl string is loaded at runtime, we are able to have > dynamic class structures and drools rules from DB. > So, I am wondering if we can have dynamic Planning Entity and Variables in > Optaplanner. That might work. See docs "Solver configuration by Java API" http://docs.jboss.org/drools/release/latest/optaplanner-docs/html_single/index.html#d0e2636 > Please share, if you have another similar ideas to achieve this. > > > > -- > View this message in context: http://drools.46999.n3.nabble.com/optaplanner-creating-dynamic-fact-classes-planning-entity-and-planning-variables-in-Optaplanner-tp4030473p4030476.html > Sent from the Drools: User forum mailing list archive at Nabble.com. > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140724/79e512d3/attachment.html From colorful.world.18 at gmail.com Thu Jul 24 05:59:40 2014 From: colorful.world.18 at gmail.com (colorful.world) Date: Thu, 24 Jul 2014 02:59:40 -0700 (PDT) Subject: [rules-users] [optaplanner] creating dynamic fact classes(planning entity and planning variables) in Optaplanner In-Reply-To: References: <1406189753515-4030473.post@n3.nabble.com> <53D0C672.2040305@gmail.com> <1406193540659-4030476.post@n3.nabble.com> Message-ID: <1406195980984-4030480.post@n3.nabble.com> Thank you very much for your replies. I will definitely try and get it back here. -- View this message in context: http://drools.46999.n3.nabble.com/optaplanner-creating-dynamic-fact-classes-planning-entity-and-planning-variables-in-Optaplanner-tp4030473p4030480.html Sent from the Drools: User forum mailing list archive at Nabble.com. From abhinay_agarwal at infosys.com Thu Jul 24 06:26:44 2014 From: abhinay_agarwal at infosys.com (abhinay_agarwal) Date: Thu, 24 Jul 2014 03:26:44 -0700 (PDT) Subject: [rules-users] How to read XML using XMLPackageReader-Drools-compiler.5.2.1.final? In-Reply-To: <1321536936892-3515778.post@n3.nabble.com> References: <1321536936892-3515778.post@n3.nabble.com> Message-ID: <1406197603912-4030481.post@n3.nabble.com> Though the post is very old, it may help someone to know the solution public static void XMLtoDRL() { try { PackageBuilderConfiguration conf = new PackageBuilderConfiguration(); final XmlPackageReader xmlPackageReader = new XmlPackageReader( conf.getSemanticModules()); xmlPackageReader.read(new InputStreamReader(XMLtoDRLConverter.class .getResourceAsStream("Sample.xml"))); final PackageDescr pkg = xmlPackageReader.getPackageDescr(); final DrlDumper drlDumper = new DrlDumper(); final String drlResult = drlDumper.dump(pkg); System.out.println(drlResult); } catch (SAXException e) { // TODO Auto-generated catch block e.printStackTrace(); } catch (IOException e) { // TODO Auto-generated catch block e.printStackTrace(); } } -- View this message in context: http://drools.46999.n3.nabble.com/How-to-read-XML-using-XMLPackageReader-Drools-compiler-5-2-1-final-tp3515778p4030481.html Sent from the Drools: User forum mailing list archive at Nabble.com. From sumitdhaniya at gmail.com Thu Jul 24 07:09:19 2014 From: sumitdhaniya at gmail.com (sumit dhaniya) Date: Thu, 24 Jul 2014 16:39:19 +0530 Subject: [rules-users] Unable to build index of kmodule.xml from Kie project jar In-Reply-To: <1406145202206-4030463.post@n3.nabble.com> References: <1404691060208-4030253.post@n3.nabble.com> <1406145202206-4030463.post@n3.nabble.com> Message-ID: Try upgrading to 6.1.CR2. On Thu, Jul 24, 2014 at 1:23 AM, LearningDrool wrote: > Hi, > > I am getting the same error as described below. I was able to run and fire > rules using a standalone application in my project but when I try to call > the same rules through a dynamic web app, it throws the below errors : > > Code : > > KieServices ks = KieServices.Factory.get(); > KieContainer kc = ks.getKieClasspathContainer(); > StatelessKieSession ksession = kc.newStatelessKieSession("TestDRL"); > ksession.addEventListener( new DebugAgendaEventListener() ); > ksession.execute() > > The Kmodule File is defined as below and is placed in the > /Resources/META-INF folder > > > xmlns="http://jboss.org/kie/6.0.0/kmodule" > xmlns:Kie="http://drools.org/schema/drools-spring"> > packages="com.test.web.actions.bard" > > > > > > > > Error : > > 0:05:58.692 [http-bio-8443-exec-4] INFO o.d.c.k.b.impl.ClasspathKieProject > - Found kmodule: > > jar:file:/C:/test/web/actions/bard/WEB-INF/lib/bard.jar!/META-INF/kmodule.xml > 10:05:58.706 [http-bio-8443-exec-4] DEBUG > o.d.c.k.b.impl.ClasspathKieProject > - KieModule URL type=jar url=/C:/test/web/actions/bard/WEB-INF/lib/bard.jar > 10:06:05.834 [http-bio-8443-exec-4] ERROR > o.d.c.k.b.impl.ClasspathKieProject > - Unable to load pom.properties > from/C:/test/web/actions/bard/WEB-INF/lib/bard.jar > null > 10:06:05.845 [http-bio-8443-exec-4] ERROR > o.d.c.k.b.impl.ClasspathKieProject > - Unable to load pom.properties > from/C:/test/web/actions/bard/WEB-INF/lib/bard.jar > 10:06:05.856 [http-bio-8443-exec-4] ERROR > o.d.c.k.b.impl.ClasspathKieProject > - Unable to build index of kmodule.xml > > url=jar:file:/C:/test/web/actions/bard/WEB-INF/lib/bard.jar!/META-INF/kmodule.xml > null > > > > > Also I was able to call the DRL file using the below code in my project: > > KnowledgeBuilder kbuilder = KnowledgeBuilderFactory.newKnowledgeBuilder(); > Resource ruleFile = > > ResourceFactory.newUrlResource(getClass().getClassLoader().getResource("test1.drl")); > kbuilder.add(ruleFile, ResourceType.DRL); > KnowledgeBase kbase = kbuilder.newKnowledgeBase(); > kbase.addKnowledgePackages(kbuilder.getKnowledgePackages()); > > > I had placed the test1.drl file in the Tomcat folder > > Why are the Ksessions not being loaded when using the Kmodule.xml. Any > ideas? > > > > > > -- > View this message in context: > http://drools.46999.n3.nabble.com/Unable-to-build-index-of-kmodule-xml-from-Kie-project-jar-tp4030253p4030463.html > Sent from the Drools: User forum mailing list archive at Nabble.com. > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140724/d2478902/attachment-0001.html From stephen.masters at me.com Thu Jul 24 07:10:55 2014 From: stephen.masters at me.com (Stephen Masters) Date: Thu, 24 Jul 2014 12:10:55 +0100 Subject: [rules-users] Drools Performance Analysis Required In-Reply-To: References: Message-ID: Your specific rules have so much more impact on these stats than any of the factors you mention such as numbers of rules and facts. The number of rules by itself has very little impact on performance, except at start-up time. There are knowledge bases out there with > 100,000 rules, which achieve evaluations in milliseconds. The number of facts by itself has very little impact on performance, unless you are inserting 1000s on each request. If you are able to design your application to insert facts up front, then a request may well be an insertion of a single fact. All benchmarks available achieve nothing more than showing whether a particular rules engine is a little bit faster than another at running a particular set of rules against a particular set of facts. And most are deliberately designed to be doing inefficient things, which are unlikely to bear any relation to real-world applications. So you need to run your own benchmarks against your own rules and facts. Steve On 24 Jul 2014, at 09:56, Zahid Ahmed wrote: > Hi, > > I need to know the Drools capacity to execute the rules. > > I need to know how many rules it can execute at a time and with how many facts. > > I need to know the memory stats. > > We are planning for a central rules execution server with executing around 10,000 rules per request and requests per minute can be ~300. > > Has anyone done the benchmarking. Or is there any scalable solution that can be implemented. > > > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140724/4d825191/attachment.html From jmercier at genoscope.cns.fr Thu Jul 24 09:08:22 2014 From: jmercier at genoscope.cns.fr (Mercier Jonathan) Date: Thu, 24 Jul 2014 15:08:22 +0200 Subject: [rules-users] gradle and drools Message-ID: <53D10546.2000606@genoscope.cns.fr> Dear, Gradle become day after day more popular. In more spring and hibernate project switch to this tools. So how we can use this tools with drools to get an uniform build system ? Regards From webster.homer at sial.com Thu Jul 24 10:35:30 2014 From: webster.homer at sial.com (WebHomer) Date: Thu, 24 Jul 2014 07:35:30 -0700 (PDT) Subject: [rules-users] Problem with Drools 6.0.1 Eclipse Projects with CDI and Java 7 Message-ID: <1406212530528-4030485.post@n3.nabble.com> I'm new to Drools and pretty new to maven. I am trying to incorporate Drools 6.0.1 into a Wildfly (8.0.0) based project. I am using the current version of JBoss Developer Studio 7.1.1.GA on Redhat Linux In Eclipse the project has a number of errors in CDI modules, but builds without errors in maven. The Java auto-complete works correctly as I import annotations, but after is is imported I get an error in the file showing import javax.enterprise.context.ApplicationScoped; import javax.enterprise.context.Dependent; import javax.enterprise.inject.Disposes; import javax.enterprise.inject.Produces; import javax.enterprise.inject.spi.InjectionPoint; The above all show the same type of error: Only a type can be imported. javax.enterprise.inject.Disposes resolves to a package It seems to be limited to the javax cdi includes This is a maven project, and maven compiles it with no problems. Only Eclipse seems to have an issue. I have m2eclipse installed as well. In addition, if I use Java 7 syntax extensions it complains about those too. The maven pom specifies Java 1.7, the project facets specifies 1.7 and the default compliance level is also Java 1.7. But something somewhere doesn't like it. Again, a maven build works. Only Eclipse has problems. I suspect the Eclipse Drools plugin may be at fault as I don't see this in non-Drools projects I see this in the standard Java files, not the .drl files. It is quite annoying and frustrating. We have to build using only maven I found that this can be easily reproduced. You need m2eclipse installed, and the drools 6.0.1.Final eclipse plugin installed 1. In Eclipse create a new drools project 2. Convert the project to maven 3. add the javax.enterprise:cdi-api (version 1.1) dependency 4. Maven>Update Project 5. edit a java file in the project and try to add one of the above listed imports and you will see the same error. I believe that this is also related: I set my pom.xml to java 7, verified that the project was java 7 compliance etc and the eclipse editor still complained about the use of Java 7 features like the "diamond" operator. It seems that Drools doesn't like Eclipse and Java 7... -- View this message in context: http://drools.46999.n3.nabble.com/Problem-with-Drools-6-0-1-Eclipse-Projects-with-CDI-and-Java-7-tp4030485.html Sent from the Drools: User forum mailing list archive at Nabble.com. From reddy.lakshmi at gmail.com Thu Jul 24 10:50:00 2014 From: reddy.lakshmi at gmail.com (LaKhI ReDdY!!!!!!!!!!!) Date: Thu, 24 Jul 2014 20:20:00 +0530 Subject: [rules-users] Any point on how to make SSO(Single sign on) authentication in Guvnor 5.3.3.Final version? Message-ID: Hi, Can anybody suggest on how to make SSO(Single sign on) authentication in Guvnor 5.3.3.Final version? Regards, Reddy -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140724/e335b86b/attachment.html From borris at chaos.org.uk Thu Jul 24 11:10:08 2014 From: borris at chaos.org.uk (Borris) Date: Thu, 24 Jul 2014 16:10:08 +0100 Subject: [rules-users] Problem with Drools 6.0.1 Eclipse Projects with CDI and Java 7 In-Reply-To: <1406212530528-4030485.post@n3.nabble.com> References: <1406212530528-4030485.post@n3.nabble.com> Message-ID: <53D121D0.60407@chaos.org.uk> I had a similar problem. There was a bug https://issues.jboss.org/browse/DROOLS-472 which has now been fixed. I think if you try the 6.1CR you should find the issue is resolved. Borris On Thursday 24/07/2014 15:35, WebHomer wrote: > I'm new to Drools and pretty new to maven. I am trying to incorporate Drools > 6.0.1 into a Wildfly (8.0.0) based project. I am using the current version > of JBoss Developer Studio 7.1.1.GA on Redhat Linux In Eclipse the project > has a number of errors in CDI modules, but builds without errors in maven. > The Java auto-complete works correctly as I import annotations, but after is > is imported I get an error in the file showing > > import javax.enterprise.context.ApplicationScoped; > import javax.enterprise.context.Dependent; > import javax.enterprise.inject.Disposes; > import javax.enterprise.inject.Produces; > import javax.enterprise.inject.spi.InjectionPoint; > The above all show the same type of error: > > Only a type can be imported. javax.enterprise.inject.Disposes resolves to a > package > It seems to be limited to the javax cdi includes > > This is a maven project, and maven compiles it with no problems. Only > Eclipse seems to have an issue. > > I have m2eclipse installed as well. > > In addition, if I use Java 7 syntax extensions it complains about those too. > The maven pom specifies Java 1.7, the project facets specifies 1.7 and the > default compliance level is also Java 1.7. But something somewhere doesn't > like it. Again, a maven build works. Only Eclipse has problems. I suspect > the Eclipse Drools plugin may be at fault as I don't see this in non-Drools > projects > > I see this in the standard Java files, not the .drl files. It is quite > annoying and frustrating. We have to build using only maven > > I found that this can be easily reproduced. You need m2eclipse installed, > and the drools 6.0.1.Final eclipse plugin installed > 1. In Eclipse create a new drools project > 2. Convert the project to maven > 3. add the javax.enterprise:cdi-api (version 1.1) dependency > 4. Maven>Update Project > 5. edit a java file in the project and try to add one of the above listed > imports and you will see the same error. > > I believe that this is also related: > I set my pom.xml to java 7, verified that the project was java 7 compliance > etc and the eclipse editor still complained about the use of Java 7 features > like the "diamond" operator. > It seems that Drools doesn't like Eclipse and Java 7... > > > > > -- > View this message in context: http://drools.46999.n3.nabble.com/Problem-with-Drools-6-0-1-Eclipse-Projects-with-CDI-and-Java-7-tp4030485.html > Sent from the Drools: User forum mailing list archive at Nabble.com. > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users From mproctor at codehaus.org Thu Jul 24 15:07:05 2014 From: mproctor at codehaus.org (Mark Proctor) Date: Thu, 24 Jul 2014 20:07:05 +0100 Subject: [rules-users] gradle and drools In-Reply-To: <53D10546.2000606@genoscope.cns.fr> References: <53D10546.2000606@genoscope.cns.fr> Message-ID: By getting involved and porting the maven plugin to those other build systems: http://docs.jboss.org/drools/release/5.6.0.Final/droolsjbpm-introduction-docs/html/gettingstarted.html Mark On 24 Jul 2014, at 14:08, Mercier Jonathan wrote: > Dear, > > Gradle become day after day more popular. In more spring and hibernate > project switch to this tools. So how we can use this tools with drools > to get an uniform build system ? > > Regards > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users From webster.homer at sial.com Thu Jul 24 16:41:10 2014 From: webster.homer at sial.com (WebHomer) Date: Thu, 24 Jul 2014 13:41:10 -0700 (PDT) Subject: [rules-users] Problem with Drools 6.0.1 Eclipse Projects with CDI and Java 7 In-Reply-To: <53D121D0.60407@chaos.org.uk> References: <1406212530528-4030485.post@n3.nabble.com> <53D121D0.60407@chaos.org.uk> Message-ID: <1406234470712-4030490.post@n3.nabble.com> Thanks! upgrading to 6.1CR2 fixed both the problem with loading the annotation and the inability to use Java 1.7 syntax -- View this message in context: http://drools.46999.n3.nabble.com/Problem-with-Drools-6-0-1-Eclipse-Projects-with-CDI-and-Java-7-tp4030485p4030490.html Sent from the Drools: User forum mailing list archive at Nabble.com. From mario.fusco at gmail.com Fri Jul 25 11:36:43 2014 From: mario.fusco at gmail.com (Mario Fusco) Date: Fri, 25 Jul 2014 08:36:43 -0700 (PDT) Subject: [rules-users] DROOLS-516 - Continued Memory Leak problem Drools 6.1.0. In-Reply-To: <1F438071-3E59-416F-873E-08BAD0D9E016@psware.com> References: <1F438071-3E59-416F-873E-08BAD0D9E016@psware.com> Message-ID: <1406302603002-4030497.post@n3.nabble.com> Hi, your last test case evidenced that there was something not covered by my fix of DROOLS-516. I resolved this issue with this further commit: https://github.com/droolsjbpm/drools/commit/a833097b4 Thanks a lot for having reported this and regards, Mario -- View this message in context: http://drools.46999.n3.nabble.com/rules-users-DROOLS-516-Continued-Memory-Leak-problem-Drools-6-1-0-tp4030448p4030497.html Sent from the Drools: User forum mailing list archive at Nabble.com. From matteo.mortari at gmail.com Fri Jul 25 11:54:58 2014 From: matteo.mortari at gmail.com (Matteo Mortari) Date: Fri, 25 Jul 2014 17:54:58 +0200 Subject: [rules-users] packaging 'kjar' with kie-maven-plugin and src/test/resources directory Message-ID: Ciao, speaking of the kie maven plugin, can I kindly ask for a feedback about https://issues.jboss.org/browse/DROOLS-495 , please? I normally use src/test/resources directory to store test files for some Unit test. Typically by "test files" I mean xml files, which get un-marshaled and used for some additional testing of rule behavior. It seems to me: - that setting in the pom.xml the to 'kjar' does not make these file resources available during the test phase. - setting the to 'jar' solve the issue, but this exclude the kie-maven-plugin from the maven phases. At least this is my experience, as detailed in the Jira with reproducer, and personally I'm currently using other not-very-beautiful means to overcome the issue. Just asking to know, thank you in advance. (also "not a bug" or "reject" would be acceptable feedback of course) Ciao, Matteo -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140725/2ff82273/attachment-0001.html From bhavnaa.shetty at gmail.com Fri Jul 25 11:58:09 2014 From: bhavnaa.shetty at gmail.com (bjs) Date: Fri, 25 Jul 2014 08:58:09 -0700 (PDT) Subject: [rules-users] Doubt regarding split in Drools rule-flow Message-ID: <1406303889619-4030500.post@n3.nabble.com> Hello everyone, I have ruleflow with a split that seggregates objects with balance less than 5000(branch1) and more than and equal to 5000(branch2) and series of rules in each of the branch. But when i run the flow for multiple objects , if an objects with balance less than 5000(branch1) matches the rule under the branch2 it fires the rule. How do i segregate based on the split and make the objects fire rules only under branch1 if it satisfies the condition for branch1. -- View this message in context: http://drools.46999.n3.nabble.com/Doubt-regarding-split-in-Drools-rule-flow-tp4030500.html Sent from the Drools: User forum mailing list archive at Nabble.com. From psiroky at redhat.com Fri Jul 25 13:43:15 2014 From: psiroky at redhat.com (=?UTF-8?B?UGV0ciDFoGlyb2vDvQ==?=) Date: Fri, 25 Jul 2014 19:43:15 +0200 Subject: [rules-users] packaging 'kjar' with kie-maven-plugin and src/test/resources directory In-Reply-To: References: Message-ID: <53D29733.6000201@redhat.com> Hello, I think this is a bug in the kie-maven-plugin as it does not execute the process-test-resources phase by default. I created a PR with the fix: https://github.com/droolsjbpm/drools/pull/365 You can workaround this issue by specifying the testResources phase explicitly in your pom.xml (see my last comment on https://issues.jboss.org/browse/DROOLS-495 for more info). Thanks, Petr On Fri 25 Jul 2014 17:54:58 CEST, Matteo Mortari wrote: > Ciao, speaking of the kie maven plugin, can I kindly ask for a > feedback about https://issues.jboss.org/browse/DROOLS-495 , please? > > I normally use src/test/resources directory to store test files for > some Unit test. Typically by "test files" I mean xml files, which get > un-marshaled and used for some additional testing of rule behavior. It > seems to me: > - that setting in the pom.xml the to 'kjar' does not make > these file resources available during the test phase. > - setting the to 'jar' solve the issue, but this exclude > the kie-maven-plugin from the maven phases. > > At least this is my experience, as detailed in the Jira with > reproducer, and personally I'm currently using other > not-very-beautiful means to overcome the issue. > > Just asking to know, thank you in advance. > (also "not a bug" or "reject" would be acceptable feedback of course) > Ciao, > Matteo > > > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users From dsotty at gmail.com Fri Jul 25 16:06:00 2014 From: dsotty at gmail.com (Davide Sottara) Date: Fri, 25 Jul 2014 22:06:00 +0200 Subject: [rules-users] Are globals not permitted with queries? In-Reply-To: <53D02180.7070504@chaos.org.uk> References: <53CE87BB.7050203@chaos.org.uk> <53CE8E6A.40708@gmail.com> <53D02180.7070504@chaos.org.uk> Message-ID: <53D2B8A8.2000403@gmail.com> Confirmed, the NPE is a bug.. The use case was not covered. A tentative fix is here, we'll discuss it next week https://issues.jboss.org/browse/DROOLS-564 https://github.com/sotty/drools/commit/9db38d098e67560839b36661bdf24a5f5cdae1df Davide On 07/23/2014 10:56 PM, Borris wrote: > I want to pass strings around between rules and queries to control their > actions and provide control values. I know I can just use "literals" but > I know from past experience that that leads to small typos not being > detected (either at compile time or run time) and leads to nasty subtle > errors down the line. > > For rules, you can over come this with a bunch of public static final > String in a class (I call mine Consts) - and then any spelling mistakes > become compile time issues as you are matching against a > variable/constant name and if you spell this right then you know you get > the right control string. > > But does anyone have a technique that works with queries? I know lots of > the docn talks about queries being things you can invoke from Java. But > I use queries in my rules (they have a private stack and support > recursion that rules don't quite do in the same way). Does anyone have a > clever technique they've used in the past? > > Thanks > > Borris > > > On 22/07/2014 17:16, Davide Sottara wrote: >> The case may not be supported, but even then, it should be reported as >> a compilation error, not as a NPE >> I'll investigate and report back later >> Thanks >> Davide >> >> On 07/22/2014 05:48 PM, Borris wrote: >>> I was experimenting with ways of avoiding having to put literal strings >>> into my rules (it is very fragile and bugs can be silent for a long >>> time). I tried declaring a global and then tried supplying it to a >>> query. This generates a backtrace during the newKieSession. A simple >>> example to provoke the problem: >>> >>> >>> KieServices ks = KieServices.Factory.get(); >>> KieContainer kContainer = ks.getKieClasspathContainer(); >>> KieSession kSession = >>> kContainer.newKieSession("ksession-rules"); >>> >>> kSession.setGlobal("AString", "Hello World"); >>> >>> kSession.fireAllRules(); >>> >>> >>> >>> package com.sample >>> >>> global java.lang.String AString; >>> >>> declare Thing >>> name: String @key >>> end >>> >>> rule init >>> when >>> then >>> insert( new Thing( AString ) ); >>> end >>> >>> query test(String $in) >>> Thing( $in; ) >>> end >>> >>> rule spot >>> when >>> test( "Hello World"; ) >>> Thing( "Hello World"; ) >>> test( AString; ) >>> Thing( AString; ) >>> then >>> System.out.println("found msg\n"); >>> end >>> >>> >>> java.lang.NullPointerException >>> at >>> org.drools.core.rule.LogicTransformer.processElement(LogicTransformer.java:243) >>> at >>> org.drools.core.rule.LogicTransformer.processElement(LogicTransformer.java:263) >>> at >>> org.drools.core.rule.LogicTransformer.fixClonedDeclarations(LogicTransformer.java:134) >>> at >>> org.drools.core.rule.LogicTransformer.transform(LogicTransformer.java:99) >>> at >>> org.drools.core.definitions.rule.impl.RuleImpl.getTransformedLhs(RuleImpl.java:560) >>> at >>> org.drools.core.reteoo.builder.ReteooRuleBuilder.addRule(ReteooRuleBuilder.java:105) >>> at org.drools.core.reteoo.ReteooBuilder.addRule(ReteooBuilder.java:100) >>> at >>> org.drools.core.impl.KnowledgeBaseImpl.addRule(KnowledgeBaseImpl.java:1455) >>> at >>> org.drools.core.impl.KnowledgeBaseImpl.addRule(KnowledgeBaseImpl.java:1435) >>> at >>> org.drools.core.impl.KnowledgeBaseImpl.addPackages(KnowledgeBaseImpl.java:838) >>> at >>> org.drools.core.impl.KnowledgeBaseImpl.addKnowledgePackages(KnowledgeBaseImpl.java:266) >>> at >>> org.drools.compiler.kie.builder.impl.KieContainerImpl.createKieBase(KieContainerImpl.java:412) >>> at >>> org.drools.compiler.kie.builder.impl.KieContainerImpl.getKieBase(KieContainerImpl.java:346) >>> at >>> org.drools.compiler.kie.builder.impl.KieContainerImpl.newKieSession(KieContainerImpl.java:498) >>> at >>> org.drools.compiler.kie.builder.impl.KieContainerImpl.newKieSession(KieContainerImpl.java:469) >>> at com.sample.DroolsTest.main(DroolsTest.java:17) >>> >>> >>> The 3rd action in the spot rule causes the null exception during >>> initialise, if it is present. Comment out just that line and no >>> exceptions happen and behaviour is as expected. >>> >>> Are globals permitted in the way I am trying to use them, as a parameter >>> to a query? >>> >>> Borris >>> >>> >>> >>> >>> _______________________________________________ >>> rules-users mailing list >>> rules-users at lists.jboss.org >>> https://lists.jboss.org/mailman/listinfo/rules-users >>> >> _______________________________________________ >> rules-users mailing list >> rules-users at lists.jboss.org >> https://lists.jboss.org/mailman/listinfo/rules-users > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users > From dsotty at gmail.com Fri Jul 25 19:39:15 2014 From: dsotty at gmail.com (Davide Sottara) Date: Sat, 26 Jul 2014 01:39:15 +0200 Subject: [rules-users] Defeasible: NPE: with multiple @Defeasible In-Reply-To: <53D02212.6040307@chaos.org.uk> References: <53CEBE2B.4070903@chaos.org.uk> <1FE456CF-C308-4AE5-A014-EBAB4A9C23A2@codehaus.org> <53D02212.6040307@chaos.org.uk> Message-ID: <53D2EAA3.2000308@gmail.com> Fixed, in PR status. It was indeed another bug. https://github.com/sotty/drools/commit/7941a0c8d7e66c6c7719c14ca58d798337d067d8 Thanks for reporting, we really appreciate the feedback Davide On 07/23/2014 10:58 PM, Borris wrote: > On 22/07/2014 22:44, Mark Proctor wrote: >> Stack trace shows the error: >> org.drools.core.beliefsystem.defeasible.DefeasibleBeliefSet.removeUndefeated(DefeasibleBeliefSet.java:295) >> https://github.com/sotty/drools/blob/master/drools-core/src/main/java/org/drools/core/beliefsystem/defeasible/DefeasibleBeliefSet.java >> >> Maybe have a go fixing it yourself? And submit the fix with a unit test, as a pull request? >> http://docs.jboss.org/drools/release/5.6.0.Final/droolsjbpm-introduction-docs/html/gettingstarted.html >> > I might well have a go, but there's a whole bunch of learning I need to > do before I can submit my first candidate patch. So don't expect > something too quickly. > > Borris > > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users > From matteo.mortari at gmail.com Sat Jul 26 06:30:46 2014 From: matteo.mortari at gmail.com (Matteo Mortari) Date: Sat, 26 Jul 2014 12:30:46 +0200 Subject: [rules-users] packaging 'kjar' with kie-maven-plugin and src/test/resources directory In-Reply-To: <53D29733.6000201@redhat.com> References: <53D29733.6000201@redhat.com> Message-ID: Thank you Petr, for the fix on master and the workaround, works for me. Ciao, Matteo On Fri, Jul 25, 2014 at 7:43 PM, Petr ?irok? wrote: > Hello, > > I think this is a bug in the kie-maven-plugin as it does not execute the > process-test-resources phase by default. I created a PR with the fix: > https://github.com/droolsjbpm/drools/pull/365 > > You can workaround this issue by specifying the testResources phase > explicitly in your pom.xml (see my last comment on > https://issues.jboss.org/browse/DROOLS-495 for more info). > > Thanks, > Petr > > > On Fri 25 Jul 2014 17:54:58 CEST, Matteo Mortari wrote: > >> Ciao, speaking of the kie maven plugin, can I kindly ask for a >> feedback about https://issues.jboss.org/browse/DROOLS-495 , please? >> >> I normally use src/test/resources directory to store test files for >> some Unit test. Typically by "test files" I mean xml files, which get >> un-marshaled and used for some additional testing of rule behavior. It >> seems to me: >> - that setting in the pom.xml the to 'kjar' does not make >> these file resources available during the test phase. >> - setting the to 'jar' solve the issue, but this exclude >> the kie-maven-plugin from the maven phases. >> >> At least this is my experience, as detailed in the Jira with >> reproducer, and personally I'm currently using other >> not-very-beautiful means to overcome the issue. >> >> Just asking to know, thank you in advance. >> (also "not a bug" or "reject" would be acceptable feedback of course) >> Ciao, >> Matteo >> >> >> _______________________________________________ >> rules-users mailing list >> rules-users at lists.jboss.org >> https://lists.jboss.org/mailman/listinfo/rules-users >> > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140726/0e72e085/attachment.html From Darshana.R at azay.co.th Mon Jul 28 06:34:48 2014 From: Darshana.R at azay.co.th (Darshana Rajapaksha (Thailand)) Date: Mon, 28 Jul 2014 10:34:48 +0000 Subject: [rules-users] Deploying drools workbench on weblogic Message-ID: Hi, I'm trying to deploy kie-drools-wb-distribution-wars-6.0.1.Final-tomcat7.0.war on weblogic 12C and I'm getting different kind of exceptions. When one get fixed another exception. Anybody got success doing this. Below is the latest exception I'm getting when deploying. Any helpful idea is really appreciated. (NIOLuceneSetup.java:31) at org.drools.workbench.backend.server.ApplicationScopedProducer.(ApplicationScopedProducer.java:70) at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:57) at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45) at java.lang.reflect.Constructor.newInstance(Constructor.java:525) at org.jboss.weld.introspector.jlr.WeldConstructorImpl.newInstance(WeldConstructorImpl.java:206) at org.jboss.weld.injection.ConstructorInjectionPoint.newInstance(ConstructorInjectionPoint.java:117) at org.jboss.weld.bean.ManagedBean.createInstance(ManagedBean.java:336) at org.jboss.weld.bean.ManagedBean$ManagedBeanInjectionTarget.produce(ManagedBean.java:200) at org.jboss.weld.bean.ManagedBean.create(ManagedBean.java:292) at org.jboss.weld.context.AbstractContext.get(AbstractContext.java:103) at org.jboss.weld.manager.BeanManagerImpl.getReference(BeanManagerImpl.java:608) at org.jboss.weld.bean.AbstractReceiverBean.getReceiver(AbstractReceiverBean.java:77) at org.jboss.weld.bean.AbstractProducerBean$AbstractProducer.produce(AbstractProducerBean.java:317) at org.jboss.weld.bean.AbstractProducerBean.create(AbstractProducerBean.java:307) at org.jboss.weld.context.unbound.DependentContextImpl.get(DependentContextImpl.java:68) at org.jboss.weld.manager.BeanManagerImpl.getReference(BeanManagerImpl.java:608) at org.jboss.weld.manager.BeanManagerImpl.getReference(BeanManagerImpl.java:674) at org.jboss.weld.injection.FieldInjectionPoint.inject(FieldInjectionPoint.java:136) at org.jboss.weld.util.Beans.injectBoundFields(Beans.java:763) at org.jboss.weld.util.Beans.injectFieldsAndInitializers(Beans.java:772) at org.jboss.weld.bean.ManagedBean$ManagedBeanInjectionTarget$1$1.proceed(ManagedBean.java:161) at com.oracle.injection.provider.weld.WeldInjectionServicesAdapter.aroundInject(WeldInjectionServicesAdapter.java:103) at org.jboss.weld.injection.InjectionContextImpl.run(InjectionContextImpl.java:46) at org.jboss.weld.bean.ManagedBean$ManagedBeanInjectionTarget$1.work(ManagedBean.java:157) at org.jboss.weld.bean.ManagedBean$FixInjectionPoint.run(ManagedBean.java:131) at org.jboss.weld.bean.ManagedBean$ManagedBeanInjectionTarget.inject(ManagedBean.java:153) at org.jboss.weld.bean.ManagedBean.create(ManagedBean.java:293) at org.jboss.weld.context.AbstractContext.get(AbstractContext.java:103) at org.jboss.weld.bean.proxy.ContextBeanInstance.getInstance(ContextBeanInstance.java:90) at org.jboss.weld.bean.proxy.ProxyMethodHandler.invoke(ProxyMethodHandler.java:79) at org.uberfire.backend.server.repositories.RepositoryServiceImpl$Proxy$_$$_WeldClientProxy.getRepository(RepositoryServiceImpl$Proxy$_$$_WeldClientProxy.java) at org.drools.workbench.backend.server.AppSetup.assertPlayground(AppSetup.java:81) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:601) at org.jboss.weld.util.reflection.SecureReflections$13.work(SecureReflections.java:267) at org.jboss.weld.util.reflection.SecureReflectionAccess.run(SecureReflectionAccess.java:52) at org.jboss.weld.util.reflection.SecureReflectionAccess.runAsInvocation(SecureReflectionAccess.java:137) at org.jboss.weld.util.reflection.SecureReflections.invoke(SecureReflections.java:263) at org.jboss.weld.introspector.jlr.WeldMethodImpl.invoke(WeldMethodImpl.java:174) at org.jboss.weld.bean.AbstractClassBean.defaultPostConstruct(AbstractClassBean.java:402) at org.jboss.weld.bean.ManagedBean$ManagedBeanInjectionTarget.postConstruct(ManagedBean.java:174) at org.jboss.weld.bean.ManagedBean.create(ManagedBean.java:294) at org.jboss.weld.context.AbstractContext.get(AbstractContext.java:103) at org.jboss.weld.bean.proxy.ContextBeanInstance.getInstance(ContextBeanInstance.java:90) at org.jboss.weld.bean.proxy.ProxyMethodHandler.invoke(ProxyMethodHandler.java:79) at org.drools.workbench.backend.server.AppSetup$Proxy$_$$_WeldClientProxy.toString(AppSetup$Proxy$_$$_WeldClientProxy.java) at org.uberfire.commons.services.cdi.StartupBeanExtension.runPostConstruct(StartupBeanExtension.java:83) at org.uberfire.commons.services.cdi.StartupBeanExtension.afterDeploymentValidation(StartupBeanExtension.java:67) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:601) at org.jboss.weld.util.reflection.SecureReflections$13.work(SecureReflections.java:267) at org.jboss.weld.util.reflection.SecureReflectionAccess.run(SecureReflectionAccess.java:52) at org.jboss.weld.util.reflection.SecureReflectionAccess.runAsInvocation(SecureReflectionAccess.java:137) at org.jboss.weld.util.reflection.SecureReflections.invoke(SecureReflections.java:263) at org.jboss.weld.introspector.jlr.WeldMethodImpl.invokeOnInstance(WeldMethodImpl.java:170) at org.jboss.weld.introspector.ForwardingWeldMethod.invokeOnInstance(ForwardingWeldMethod.java:51) at org.jboss.weld.injection.MethodInjectionPoint.invokeOnInstanceWithSpecialValue(MethodInjectionPoint.java:154) at org.jboss.weld.event.ObserverMethodImpl.sendEvent(ObserverMethodImpl.java:245) at org.jboss.weld.event.ObserverMethodImpl.sendEvent(ObserverMethodImpl.java:233) at org.jboss.weld.event.ObserverMethodImpl.notify(ObserverMethodImpl.java:213) at org.jboss.weld.bootstrap.events.AbstractContainerEvent.fire(AbstractContainerEvent.java:75) at org.jboss.weld.bootstrap.events.AbstractDeploymentContainerEvent.fire(AbstractDeploymentContainerEvent.java:46) at org.jboss.weld.bootstrap.events.AfterDeploymentValidationImpl.fire(AfterDeploymentValidationImpl.java:31) at org.jboss.weld.bootstrap.WeldBootstrap.validateBeans(WeldBootstrap.java:382) at com.oracle.injection.provider.weld.WeldInjectionContainer.start(WeldInjectionContainer.java:106) at com.oracle.injection.integration.CDIAppDeploymentExtension.initCdi(CDIAppDeploymentExtension.java:70) at com.oracle.injection.integration.CDIAppDeploymentExtension.activate(CDIAppDeploymentExtension.java:47) at weblogic.application.internal.flow.AppDeploymentExtensionFlow.activate(AppDeploymentExtensionFlow.java:37) at weblogic.application.internal.BaseDeployment$2.next(BaseDeployment.java:729) at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:42) at weblogic.application.internal.BaseDeployment.activate(BaseDeployment.java:258) at weblogic.application.internal.SingleModuleDeployment.activate(SingleModuleDeployment.java:48) at weblogic.application.internal.DeploymentStateChecker.activate(DeploymentStateChecker.java:165) at weblogic.deploy.internal.targetserver.AppContainerInvoker.activate(AppContainerInvoker.java:80) at weblogic.deploy.internal.targetserver.operations.AbstractOperation.activate(AbstractOperation.java:586) at weblogic.deploy.internal.targetserver.operations.ActivateOperation.activateDeployment(ActivateOperation.java:148) at weblogic.deploy.internal.targetserver.operations.ActivateOperation.doCommit(ActivateOperation.java:114) at weblogic.deploy.internal.targetserver.operations.AbstractOperation.commit(AbstractOperation.java:339) at weblogic.deploy.internal.targetserver.DeploymentManager.handleDeploymentCommit(DeploymentManager.java:846) at weblogic.deploy.internal.targetserver.DeploymentManager.activateDeploymentList(DeploymentManager.java:1275) at weblogic.deploy.internal.targetserver.DeploymentManager.handleCommit(DeploymentManager.java:442) at weblogic.deploy.internal.targetserver.DeploymentServiceDispatcher.commit(DeploymentServiceDispatcher.java:176) at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer.doCommitCallback(DeploymentReceiverCallbackDeliverer.java:195) at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer.access$100(DeploymentReceiverCallbackDeliverer.java:13) at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer$2.run(DeploymentReceiverCallbackDeliverer.java:68) at weblogic.work.SelfTuningWorkManagerImpl$WorkAdapterImpl.run(SelfTuningWorkManagerImpl.java:550) at weblogic.work.ExecuteThread.execute(ExecuteThread.java:295) at weblogic.work.ExecuteThread.run(ExecuteThread.java:254) Caused By: java.lang.ClassNotFoundException: org.apache.lucene.store.NIOFSDirectory at java.net.URLClassLoader$1.run(URLClassLoader.java:366) at java.net.URLClassLoader$1.run(URLClassLoader.java:355) at java.security.AccessController.doPrivileged(Native Method) at java.net.URLClassLoader.findClass(URLClassLoader.java:354) at java.lang.ClassLoader.loadClass(ClassLoader.java:423) at java.lang.ClassLoader.loadClass(ClassLoader.java:356) at org.uberfire.metadata.backend.lucene.setups.NIOLuceneSetup.getDirectory(NIOLuceneSetup.java:40) at org.uberfire.metadata.backend.lucene.setups.NIOLuceneSetup.(NIOLuceneSetup.java:31) at org.drools.workbench.backend.server.ApplicationScopedProducer.(ApplicationScopedProducer.java:70) at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:57) at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45) at java.lang.reflect.Constructor.newInstance(Constructor.java:525) at org.jboss.weld.introspector.jlr.WeldConstructorImpl.newInstance(WeldConstructorImpl.java:206) at org.jboss.weld.injection.ConstructorInjectionPoint.newInstance(ConstructorInjectionPoint.java:117) at org.jboss.weld.bean.ManagedBean.createInstance(ManagedBean.java:336) at org.jboss.weld.bean.ManagedBean$ManagedBeanInjectionTarget.produce(ManagedBean.java:200) at org.jboss.weld.bean.ManagedBean.create(ManagedBean.java:292) at org.jboss.weld.context.AbstractContext.get(AbstractContext.java:103) at org.jboss.weld.manager.BeanManagerImpl.getReference(BeanManagerImpl.java:608) at org.jboss.weld.bean.AbstractReceiverBean.getReceiver(AbstractReceiverBean.java:77) at org.jboss.weld.bean.AbstractProducerBean$AbstractProducer.produce(AbstractProducerBean.java:317) at org.jboss.weld.bean.AbstractProducerBean.create(AbstractProducerBean.java:307) at org.jboss.weld.context.unbound.DependentContextImpl.get(DependentContextImpl.java:68) at org.jboss.weld.manager.BeanManagerImpl.getReference(BeanManagerImpl.java:608) at org.jboss.weld.manager.BeanManagerImpl.getReference(BeanManagerImpl.java:674) at org.jboss.weld.injection.FieldInjectionPoint.inject(FieldInjectionPoint.java:136) at org.jboss.weld.util.Beans.injectBoundFields(Beans.java:763) at org.jboss.weld.util.Beans.injectFieldsAndInitializers(Beans.java:772) at org.jboss.weld.bean.ManagedBean$ManagedBeanInjectionTarget$1$1.proceed(ManagedBean.java:161) at com.oracle.injection.provider.weld.WeldInjectionServicesAdapter.aroundInject(WeldInjectionServicesAdapter.java:103) at org.jboss.weld.injection.InjectionContextImpl.run(InjectionContextImpl.java:46) at org.jboss.weld.bean.ManagedBean$ManagedBeanInjectionTarget$1.work(ManagedBean.java:157) at org.jboss.weld.bean.ManagedBean$FixInjectionPoint.run(ManagedBean.java:131) at org.jboss.weld.bean.ManagedBean$ManagedBeanInjectionTarget.inject(ManagedBean.java:153) at org.jboss.weld.bean.ManagedBean.create(ManagedBean.java:293) at org.jboss.weld.context.AbstractContext.get(AbstractContext.java:103) at org.jboss.weld.bean.proxy.ContextBeanInstance.getInstance(ContextBeanInstance.java:90) at org.jboss.weld.bean.proxy.ProxyMethodHandler.invoke(ProxyMethodHandler.java:79) at org.uberfire.backend.server.repositories.RepositoryServiceImpl$Proxy$_$$_WeldClientProxy.getRepository(RepositoryServiceImpl$Proxy$_$$_WeldClientProxy.java) at org.drools.workbench.backend.server.AppSetup.assertPlayground(AppSetup.java:81) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:601) at org.jboss.weld.util.reflection.SecureReflections$13.work(SecureReflections.java:267) at org.jboss.weld.util.reflection.SecureReflectionAccess.run(SecureReflectionAccess.java:52) at org.jboss.weld.util.reflection.SecureReflectionAccess.runAsInvocation(SecureReflectionAccess.java:137) at org.jboss.weld.util.reflection.SecureReflections.invoke(SecureReflections.java:263) at org.jboss.weld.introspector.jlr.WeldMethodImpl.invoke(WeldMethodImpl.java:174) at org.jboss.weld.bean.AbstractClassBean.defaultPostConstruct(AbstractClassBean.java:402) at org.jboss.weld.bean.ManagedBean$ManagedBeanInjectionTarget.postConstruct(ManagedBean.java:174) at org.jboss.weld.bean.ManagedBean.create(ManagedBean.java:294) at org.jboss.weld.context.AbstractContext.get(AbstractContext.java:103) at org.jboss.weld.bean.proxy.ContextBeanInstance.getInstance(ContextBeanInstance.java:90) at org.jboss.weld.bean.proxy.ProxyMethodHandler.invoke(ProxyMethodHandler.java:79) at org.drools.workbench.backend.server.AppSetup$Proxy$_$$_WeldClientProxy.toString(AppSetup$Proxy$_$$_WeldClientProxy.java) at org.uberfire.commons.services.cdi.StartupBeanExtension.runPostConstruct(StartupBeanExtension.java:83) at org.uberfire.commons.services.cdi.StartupBeanExtension.afterDeploymentValidation(StartupBeanExtension.java:67) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:601) at org.jboss.weld.util.reflection.SecureReflections$13.work(SecureReflections.java:267) at org.jboss.weld.util.reflection.SecureReflectionAccess.run(SecureReflectionAccess.java:52) at org.jboss.weld.util.reflection.SecureReflectionAccess.runAsInvocation(SecureReflectionAccess.java:137) at org.jboss.weld.util.reflection.SecureReflections.invoke(SecureReflections.java:263) at org.jboss.weld.introspector.jlr.WeldMethodImpl.invokeOnInstance(WeldMethodImpl.java:170) at org.jboss.weld.introspector.ForwardingWeldMethod.invokeOnInstance(ForwardingWeldMethod.java:51) at org.jboss.weld.injection.MethodInjectionPoint.invokeOnInstanceWithSpecialValue(MethodInjectionPoint.java:154) at org.jboss.weld.event.ObserverMethodImpl.sendEvent(ObserverMethodImpl.java:245) at org.jboss.weld.event.ObserverMethodImpl.sendEvent(ObserverMethodImpl.java:233) at org.jboss.weld.event.ObserverMethodImpl.notify(ObserverMethodImpl.java:213) at org.jboss.weld.bootstrap.events.AbstractContainerEvent.fire(AbstractContainerEvent.java:75) at org.jboss.weld.bootstrap.events.AbstractDeploymentContainerEvent.fire(AbstractDeploymentContainerEvent.java:46) at org.jboss.weld.bootstrap.events.AfterDeploymentValidationImpl.fire(AfterDeploymentValidationImpl.java:31) at org.jboss.weld.bootstrap.WeldBootstrap.validateBeans(WeldBootstrap.java:382) at com.oracle.injection.provider.weld.WeldInjectionContainer.start(WeldInjectionContainer.java:106) at com.oracle.injection.integration.CDIAppDeploymentExtension.initCdi(CDIAppDeploymentExtension.java:70) at com.oracle.injection.integration.CDIAppDeploymentExtension.activate(CDIAppDeploymentExtension.java:47) at weblogic.application.internal.flow.AppDeploymentExtensionFlow.activate(AppDeploymentExtensionFlow.java:37) at weblogic.application.internal.BaseDeployment$2.next(BaseDeployment.java:729) at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:42) at weblogic.application.internal.BaseDeployment.activate(BaseDeployment.java:258) at weblogic.application.internal.SingleModuleDeployment.activate(SingleModuleDeployment.java:48) at weblogic.application.internal.DeploymentStateChecker.activate(DeploymentStateChecker.java:165) at weblogic.deploy.internal.targetserver.AppContainerInvoker.activate(AppContainerInvoker.java:80) at weblogic.deploy.internal.targetserver.operations.AbstractOperation.activate(AbstractOperation.java:586) at weblogic.deploy.internal.targetserver.operations.ActivateOperation.activateDeployment(ActivateOperation.java:148) at weblogic.deploy.internal.targetserver.operations.ActivateOperation.doCommit(ActivateOperation.java:114) at weblogic.deploy.internal.targetserver.operations.AbstractOperation.commit(AbstractOperation.java:339) at weblogic.deploy.internal.targetserver.DeploymentManager.handleDeploymentCommit(DeploymentManager.java:846) at weblogic.deploy.internal.targetserver.DeploymentManager.activateDeploymentList(DeploymentManager.java:1275) at weblogic.deploy.internal.targetserver.DeploymentManager.handleCommit(DeploymentManager.java:442) at weblogic.deploy.internal.targetserver.DeploymentServiceDispatcher.commit(DeploymentServiceDispatcher.java:176) at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer.doCommitCallback(DeploymentReceiverCallbackDeliverer.java:195) at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer.access$100(DeploymentReceiverCallbackDeliverer.java:13) at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer$2.run(DeploymentReceiverCallbackDeliverer.java:68) at weblogic.work.SelfTuningWorkManagerImpl$WorkAdapterImpl.run(SelfTuningWorkManagerImpl.java:550) at weblogic.work.ExecuteThread.execute(ExecuteThread.java:295) at weblogic.work.ExecuteThread.run(ExecuteThread.java:254) > References: Message-ID: <81522501-73CA-46FA-BB69-1AE2EED3A81F@codehaus.org> We haven?t done any testing on Weblogic yet, we in the process of going through this now. Any feedback or pointers would be appreciated. Mark On 28 Jul 2014, at 11:34, Darshana Rajapaksha (Thailand) wrote: > Hi, > I'm trying to deploy kie-drools-wb-distribution-wars-6.0.1.Final-tomcat7.0.war on weblogic 12C and I'm getting different kind of exceptions. When one get fixed another exception. Anybody got success doing this. Below is the latest exception I'm getting when deploying. Any helpful idea is really appreciated. > > javax.enterprise.inject.CreationException > at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) > at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:57) > at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45) > at java.lang.reflect.Constructor.newInstance(Constructor.java:525) > at java.lang.Class.newInstance0(Class.java:374) > at java.lang.Class.newInstance(Class.java:327) > at org.jboss.weld.util.reflection.SecureReflections$16.work(SecureReflections.java:344) > at org.jboss.weld.util.reflection.SecureReflectionAccess.run(SecureReflectionAccess.java:52) > at org.jboss.weld.util.reflection.SecureReflectionAccess.runAsInstantiation(SecureReflectionAccess.java:173) > at org.jboss.weld.util.reflection.SecureReflections.newInstance(SecureReflections.java:341) > at org.jboss.weld.injection.Exceptions.rethrowException(Exceptions.java:33) > at org.jboss.weld.injection.Exceptions.rethrowException(Exceptions.java:45) > at org.jboss.weld.injection.Exceptions.rethrowException(Exceptions.java:85) > at org.jboss.weld.injection.ConstructorInjectionPoint.newInstance(ConstructorInjectionPoint.java:125) > at org.jboss.weld.bean.ManagedBean.createInstance(ManagedBean.java:336) > at org.jboss.weld.bean.ManagedBean$ManagedBeanInjectionTarget.produce(ManagedBean.java:200) > at org.jboss.weld.bean.ManagedBean.create(ManagedBean.java:292) > at org.jboss.weld.context.AbstractContext.get(AbstractContext.java:103) > at org.jboss.weld.manager.BeanManagerImpl.getReference(BeanManagerImpl.java:608) > at org.jboss.weld.bean.AbstractReceiverBean.getReceiver(AbstractReceiverBean.java:77) > at org.jboss.weld.bean.AbstractProducerBean$AbstractProducer.produce(AbstractProducerBean.java:317) > at org.jboss.weld.bean.AbstractProducerBean.create(AbstractProducerBean.java:307) > at org.jboss.weld.context.unbound.DependentContextImpl.get(DependentContextImpl.java:68) > at org.jboss.weld.manager.BeanManagerImpl.getReference(BeanManagerImpl.java:608) > at org.jboss.weld.manager.BeanManagerImpl.getReference(BeanManagerImpl.java:674) > at org.jboss.weld.injection.FieldInjectionPoint.inject(FieldInjectionPoint.java:136) > at org.jboss.weld.util.Beans.injectBoundFields(Beans.java:763) > at org.jboss.weld.util.Beans.injectFieldsAndInitializers(Beans.java:772) > at org.jboss.weld.bean.ManagedBean$ManagedBeanInjectionTarget$1$1.proceed(ManagedBean.java:161) > at com.oracle.injection.provider.weld.WeldInjectionServicesAdapter.aroundInject(WeldInjectionServicesAdapter.java:103) > at org.jboss.weld.injection.InjectionContextImpl.run(InjectionContextImpl.java:46) > at org.jboss.weld.bean.ManagedBean$ManagedBeanInjectionTarget$1.work(ManagedBean.java:157) > at org.jboss.weld.bean.ManagedBean$FixInjectionPoint.run(ManagedBean.java:131) > at org.jboss.weld.bean.ManagedBean$ManagedBeanInjectionTarget.inject(ManagedBean.java:153) > at org.jboss.weld.bean.ManagedBean.create(ManagedBean.java:293) > at org.jboss.weld.context.AbstractContext.get(AbstractContext.java:103) > at org.jboss.weld.bean.proxy.ContextBeanInstance.getInstance(ContextBeanInstance.java:90) > at org.jboss.weld.bean.proxy.ProxyMethodHandler.invoke(ProxyMethodHandler.java:79) > at org.uberfire.backend.server.repositories.RepositoryServiceImpl$Proxy$_$$_WeldClientProxy.getRepository(RepositoryServiceImpl$Proxy$_$$_WeldClientProxy.java) > at org.drools.workbench.backend.server.AppSetup.assertPlayground(AppSetup.java:81) > at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) > at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) > at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) > at java.lang.reflect.Method.invoke(Method.java:601) > at org.jboss.weld.util.reflection.SecureReflections$13.work(SecureReflections.java:267) > at org.jboss.weld.util.reflection.SecureReflectionAccess.run(SecureReflectionAccess.java:52) > at org.jboss.weld.util.reflection.SecureReflectionAccess.runAsInvocation(SecureReflectionAccess.java:137) > at org.jboss.weld.util.reflection.SecureReflections.invoke(SecureReflections.java:263) > at org.jboss.weld.introspector.jlr.WeldMethodImpl.invoke(WeldMethodImpl.java:174) > at org.jboss.weld.bean.AbstractClassBean.defaultPostConstruct(AbstractClassBean.java:402) > at org.jboss.weld.bean.ManagedBean$ManagedBeanInjectionTarget.postConstruct(ManagedBean.java:174) > at org.jboss.weld.bean.ManagedBean.create(ManagedBean.java:294) > at org.jboss.weld.context.AbstractContext.get(AbstractContext.java:103) > at org.jboss.weld.bean.proxy.ContextBeanInstance.getInstance(ContextBeanInstance.java:90) > at org.jboss.weld.bean.proxy.ProxyMethodHandler.invoke(ProxyMethodHandler.java:79) > at org.drools.workbench.backend.server.AppSetup$Proxy$_$$_WeldClientProxy.toString(AppSetup$Proxy$_$$_WeldClientProxy.java) > at org.uberfire.commons.services.cdi.StartupBeanExtension.runPostConstruct(StartupBeanExtension.java:83) > at org.uberfire.commons.services.cdi.StartupBeanExtension.afterDeploymentValidation(StartupBeanExtension.java:67) > at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) > at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) > at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) > at java.lang.reflect.Method.invoke(Method.java:601) > at org.jboss.weld.util.reflection.SecureReflections$13.work(SecureReflections.java:267) > at org.jboss.weld.util.reflection.SecureReflectionAccess.run(SecureReflectionAccess.java:52) > at org.jboss.weld.util.reflection.SecureReflectionAccess.runAsInvocation(SecureReflectionAccess.java:137) > at org.jboss.weld.util.reflection.SecureReflections.invoke(SecureReflections.java:263) > at org.jboss.weld.introspector.jlr.WeldMethodImpl.invokeOnInstance(WeldMethodImpl.java:170) > at org.jboss.weld.introspector.ForwardingWeldMethod.invokeOnInstance(ForwardingWeldMethod.java:51) > at org.jboss.weld.injection.MethodInjectionPoint.invokeOnInstanceWithSpecialValue(MethodInjectionPoint.java:154) > at org.jboss.weld.event.ObserverMethodImpl.sendEvent(ObserverMethodImpl.java:245) > at org.jboss.weld.event.ObserverMethodImpl.sendEvent(ObserverMethodImpl.java:233) > at org.jboss.weld.event.ObserverMethodImpl.notify(ObserverMethodImpl.java:213) > at org.jboss.weld.bootstrap.events.AbstractContainerEvent.fire(AbstractContainerEvent.java:75) > at org.jboss.weld.bootstrap.events.AbstractDeploymentContainerEvent.fire(AbstractDeploymentContainerEvent.java:46) > at org.jboss.weld.bootstrap.events.AfterDeploymentValidationImpl.fire(AfterDeploymentValidationImpl.java:31) > at org.jboss.weld.bootstrap.WeldBootstrap.validateBeans(WeldBootstrap.java:382) > at com.oracle.injection.provider.weld.WeldInjectionContainer.start(WeldInjectionContainer.java:106) > at com.oracle.injection.integration.CDIAppDeploymentExtension.initCdi(CDIAppDeploymentExtension.java:70) > at com.oracle.injection.integration.CDIAppDeploymentExtension.activate(CDIAppDeploymentExtension.java:47) > at weblogic.application.internal.flow.AppDeploymentExtensionFlow.activate(AppDeploymentExtensionFlow.java:37) > at weblogic.application.internal.BaseDeployment$2.next(BaseDeployment.java:729) > at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:42) > at weblogic.application.internal.BaseDeployment.activate(BaseDeployment.java:258) > at weblogic.application.internal.SingleModuleDeployment.activate(SingleModuleDeployment.java:48) > at weblogic.application.internal.DeploymentStateChecker.activate(DeploymentStateChecker.java:165) > at weblogic.deploy.internal.targetserver.AppContainerInvoker.activate(AppContainerInvoker.java:80) > at weblogic.deploy.internal.targetserver.operations.AbstractOperation.activate(AbstractOperation.java:586) > at weblogic.deploy.internal.targetserver.operations.ActivateOperation.activateDeployment(ActivateOperation.java:148) > at weblogic.deploy.internal.targetserver.operations.ActivateOperation.doCommit(ActivateOperation.java:114) > at weblogic.deploy.internal.targetserver.operations.AbstractOperation.commit(AbstractOperation.java:339) > at weblogic.deploy.internal.targetserver.DeploymentManager.handleDeploymentCommit(DeploymentManager.java:846) > at weblogic.deploy.internal.targetserver.DeploymentManager.activateDeploymentList(DeploymentManager.java:1275) > at weblogic.deploy.internal.targetserver.DeploymentManager.handleCommit(DeploymentManager.java:442) > at weblogic.deploy.internal.targetserver.DeploymentServiceDispatcher.commit(DeploymentServiceDispatcher.java:176) > at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer.doCommitCallback(DeploymentReceiverCallbackDeliverer.java:195) > at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer.access$100(DeploymentReceiverCallbackDeliverer.java:13) > at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer$2.run(DeploymentReceiverCallbackDeliverer.java:68) > at weblogic.work.SelfTuningWorkManagerImpl$WorkAdapterImpl.run(SelfTuningWorkManagerImpl.java:550) > at weblogic.work.ExecuteThread.execute(ExecuteThread.java:295) > at weblogic.work.ExecuteThread.run(ExecuteThread.java:254) > Caused By: java.lang.NoClassDefFoundError: org/apache/lucene/store/NIOFSDirectory > at org.uberfire.metadata.backend.lucene.setups.NIOLuceneSetup.getDirectory(NIOLuceneSetup.java:40) > at org.uberfire.metadata.backend.lucene.setups.NIOLuceneSetup.(NIOLuceneSetup.java:31) > at org.drools.workbench.backend.server.ApplicationScopedProducer.(ApplicationScopedProducer.java:70) > at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) > at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:57) > at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45) > at java.lang.reflect.Constructor.newInstance(Constructor.java:525) > at org.jboss.weld.introspector.jlr.WeldConstructorImpl.newInstance(WeldConstructorImpl.java:206) > at org.jboss.weld.injection.ConstructorInjectionPoint.newInstance(ConstructorInjectionPoint.java:117) > at org.jboss.weld.bean.ManagedBean.createInstance(ManagedBean.java:336) > at org.jboss.weld.bean.ManagedBean$ManagedBeanInjectionTarget.produce(ManagedBean.java:200) > at org.jboss.weld.bean.ManagedBean.create(ManagedBean.java:292) > at org.jboss.weld.context.AbstractContext.get(AbstractContext.java:103) > at org.jboss.weld.manager.BeanManagerImpl.getReference(BeanManagerImpl.java:608) > at org.jboss.weld.bean.AbstractReceiverBean.getReceiver(AbstractReceiverBean.java:77) > at org.jboss.weld.bean.AbstractProducerBean$AbstractProducer.produce(AbstractProducerBean.java:317) > at org.jboss.weld.bean.AbstractProducerBean.create(AbstractProducerBean.java:307) > at org.jboss.weld.context.unbound.DependentContextImpl.get(DependentContextImpl.java:68) > at org.jboss.weld.manager.BeanManagerImpl.getReference(BeanManagerImpl.java:608) > at org.jboss.weld.manager.BeanManagerImpl.getReference(BeanManagerImpl.java:674) > at org.jboss.weld.injection.FieldInjectionPoint.inject(FieldInjectionPoint.java:136) > at org.jboss.weld.util.Beans.injectBoundFields(Beans.java:763) > at org.jboss.weld.util.Beans.injectFieldsAndInitializers(Beans.java:772) > at org.jboss.weld.bean.ManagedBean$ManagedBeanInjectionTarget$1$1.proceed(ManagedBean.java:161) > at com.oracle.injection.provider.weld.WeldInjectionServicesAdapter.aroundInject(WeldInjectionServicesAdapter.java:103) > at org.jboss.weld.injection.InjectionContextImpl.run(InjectionContextImpl.java:46) > at org.jboss.weld.bean.ManagedBean$ManagedBeanInjectionTarget$1.work(ManagedBean.java:157) > at org.jboss.weld.bean.ManagedBean$FixInjectionPoint.run(ManagedBean.java:131) > at org.jboss.weld.bean.ManagedBean$ManagedBeanInjectionTarget.inject(ManagedBean.java:153) > at org.jboss.weld.bean.ManagedBean.create(ManagedBean.java:293) > at org.jboss.weld.context.AbstractContext.get(AbstractContext.java:103) > at org.jboss.weld.bean.proxy.ContextBeanInstance.getInstance(ContextBeanInstance.java:90) > at org.jboss.weld.bean.proxy.ProxyMethodHandler.invoke(ProxyMethodHandler.java:79) > at org.uberfire.backend.server.repositories.RepositoryServiceImpl$Proxy$_$$_WeldClientProxy.getRepository(RepositoryServiceImpl$Proxy$_$$_WeldClientProxy.java) > at org.drools.workbench.backend.server.AppSetup.assertPlayground(AppSetup.java:81) > at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) > at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) > at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) > at java.lang.reflect.Method.invoke(Method.java:601) > at org.jboss.weld.util.reflection.SecureReflections$13.work(SecureReflections.java:267) > at org.jboss.weld.util.reflection.SecureReflectionAccess.run(SecureReflectionAccess.java:52) > at org.jboss.weld.util.reflection.SecureReflectionAccess.runAsInvocation(SecureReflectionAccess.java:137) > at org.jboss.weld.util.reflection.SecureReflections.invoke(SecureReflections.java:263) > at org.jboss.weld.introspector.jlr.WeldMethodImpl.invoke(WeldMethodImpl.java:174) > at org.jboss.weld.bean.AbstractClassBean.defaultPostConstruct(AbstractClassBean.java:402) > at org.jboss.weld.bean.ManagedBean$ManagedBeanInjectionTarget.postConstruct(ManagedBean.java:174) > at org.jboss.weld.bean.ManagedBean.create(ManagedBean.java:294) > at org.jboss.weld.context.AbstractContext.get(AbstractContext.java:103) > at org.jboss.weld.bean.proxy.ContextBeanInstance.getInstance(ContextBeanInstance.java:90) > at org.jboss.weld.bean.proxy.ProxyMethodHandler.invoke(ProxyMethodHandler.java:79) > at org.drools.workbench.backend.server.AppSetup$Proxy$_$$_WeldClientProxy.toString(AppSetup$Proxy$_$$_WeldClientProxy.java) > at org.uberfire.commons.services.cdi.StartupBeanExtension.runPostConstruct(StartupBeanExtension.java:83) > at org.uberfire.commons.services.cdi.StartupBeanExtension.afterDeploymentValidation(StartupBeanExtension.java:67) > at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) > at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) > at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) > at java.lang.reflect.Method.invoke(Method.java:601) > at org.jboss.weld.util.reflection.SecureReflections$13.work(SecureReflections.java:267) > at org.jboss.weld.util.reflection.SecureReflectionAccess.run(SecureReflectionAccess.java:52) > at org.jboss.weld.util.reflection.SecureReflectionAccess.runAsInvocation(SecureReflectionAccess.java:137) > at org.jboss.weld.util.reflection.SecureReflections.invoke(SecureReflections.java:263) > at org.jboss.weld.introspector.jlr.WeldMethodImpl.invokeOnInstance(WeldMethodImpl.java:170) > at org.jboss.weld.introspector.ForwardingWeldMethod.invokeOnInstance(ForwardingWeldMethod.java:51) > at org.jboss.weld.injection.MethodInjectionPoint.invokeOnInstanceWithSpecialValue(MethodInjectionPoint.java:154) > at org.jboss.weld.event.ObserverMethodImpl.sendEvent(ObserverMethodImpl.java:245) > at org.jboss.weld.event.ObserverMethodImpl.sendEvent(ObserverMethodImpl.java:233) > at org.jboss.weld.event.ObserverMethodImpl.notify(ObserverMethodImpl.java:213) > at org.jboss.weld.bootstrap.events.AbstractContainerEvent.fire(AbstractContainerEvent.java:75) > at org.jboss.weld.bootstrap.events.AbstractDeploymentContainerEvent.fire(AbstractDeploymentContainerEvent.java:46) > at org.jboss.weld.bootstrap.events.AfterDeploymentValidationImpl.fire(AfterDeploymentValidationImpl.java:31) > at org.jboss.weld.bootstrap.WeldBootstrap.validateBeans(WeldBootstrap.java:382) > at com.oracle.injection.provider.weld.WeldInjectionContainer.start(WeldInjectionContainer.java:106) > at com.oracle.injection.integration.CDIAppDeploymentExtension.initCdi(CDIAppDeploymentExtension.java:70) > at com.oracle.injection.integration.CDIAppDeploymentExtension.activate(CDIAppDeploymentExtension.java:47) > at weblogic.application.internal.flow.AppDeploymentExtensionFlow.activate(AppDeploymentExtensionFlow.java:37) > at weblogic.application.internal.BaseDeployment$2.next(BaseDeployment.java:729) > at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:42) > at weblogic.application.internal.BaseDeployment.activate(BaseDeployment.java:258) > at weblogic.application.internal.SingleModuleDeployment.activate(SingleModuleDeployment.java:48) > at weblogic.application.internal.DeploymentStateChecker.activate(DeploymentStateChecker.java:165) > at weblogic.deploy.internal.targetserver.AppContainerInvoker.activate(AppContainerInvoker.java:80) > at weblogic.deploy.internal.targetserver.operations.AbstractOperation.activate(AbstractOperation.java:586) > at weblogic.deploy.internal.targetserver.operations.ActivateOperation.activateDeployment(ActivateOperation.java:148) > at weblogic.deploy.internal.targetserver.operations.ActivateOperation.doCommit(ActivateOperation.java:114) > at weblogic.deploy.internal.targetserver.operations.AbstractOperation.commit(AbstractOperation.java:339) > at weblogic.deploy.internal.targetserver.DeploymentManager.handleDeploymentCommit(DeploymentManager.java:846) > at weblogic.deploy.internal.targetserver.DeploymentManager.activateDeploymentList(DeploymentManager.java:1275) > at weblogic.deploy.internal.targetserver.DeploymentManager.handleCommit(DeploymentManager.java:442) > at weblogic.deploy.internal.targetserver.DeploymentServiceDispatcher.commit(DeploymentServiceDispatcher.java:176) > at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer.doCommitCallback(DeploymentReceiverCallbackDeliverer.java:195) > at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer.access$100(DeploymentReceiverCallbackDeliverer.java:13) > at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer$2.run(DeploymentReceiverCallbackDeliverer.java:68) > at weblogic.work.SelfTuningWorkManagerImpl$WorkAdapterImpl.run(SelfTuningWorkManagerImpl.java:550) > at weblogic.work.ExecuteThread.execute(ExecuteThread.java:295) > at weblogic.work.ExecuteThread.run(ExecuteThread.java:254) > Caused By: java.lang.ClassNotFoundException: org.apache.lucene.store.NIOFSDirectory > at java.net.URLClassLoader$1.run(URLClassLoader.java:366) > at java.net.URLClassLoader$1.run(URLClassLoader.java:355) > at java.security.AccessController.doPrivileged(Native Method) > at java.net.URLClassLoader.findClass(URLClassLoader.java:354) > at java.lang.ClassLoader.loadClass(ClassLoader.java:423) > at java.lang.ClassLoader.loadClass(ClassLoader.java:356) > at org.uberfire.metadata.backend.lucene.setups.NIOLuceneSetup.getDirectory(NIOLuceneSetup.java:40) > at org.uberfire.metadata.backend.lucene.setups.NIOLuceneSetup.(NIOLuceneSetup.java:31) > at org.drools.workbench.backend.server.ApplicationScopedProducer.(ApplicationScopedProducer.java:70) > at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) > at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:57) > at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45) > at java.lang.reflect.Constructor.newInstance(Constructor.java:525) > at org.jboss.weld.introspector.jlr.WeldConstructorImpl.newInstance(WeldConstructorImpl.java:206) > at org.jboss.weld.injection.ConstructorInjectionPoint.newInstance(ConstructorInjectionPoint.java:117) > at org.jboss.weld.bean.ManagedBean.createInstance(ManagedBean.java:336) > at org.jboss.weld.bean.ManagedBean$ManagedBeanInjectionTarget.produce(ManagedBean.java:200) > at org.jboss.weld.bean.ManagedBean.create(ManagedBean.java:292) > at org.jboss.weld.context.AbstractContext.get(AbstractContext.java:103) > at org.jboss.weld.manager.BeanManagerImpl.getReference(BeanManagerImpl.java:608) > at org.jboss.weld.bean.AbstractReceiverBean.getReceiver(AbstractReceiverBean.java:77) > at org.jboss.weld.bean.AbstractProducerBean$AbstractProducer.produce(AbstractProducerBean.java:317) > at org.jboss.weld.bean.AbstractProducerBean.create(AbstractProducerBean.java:307) > at org.jboss.weld.context.unbound.DependentContextImpl.get(DependentContextImpl.java:68) > at org.jboss.weld.manager.BeanManagerImpl.getReference(BeanManagerImpl.java:608) > at org.jboss.weld.manager.BeanManagerImpl.getReference(BeanManagerImpl.java:674) > at org.jboss.weld.injection.FieldInjectionPoint.inject(FieldInjectionPoint.java:136) > at org.jboss.weld.util.Beans.injectBoundFields(Beans.java:763) > at org.jboss.weld.util.Beans.injectFieldsAndInitializers(Beans.java:772) > at org.jboss.weld.bean.ManagedBean$ManagedBeanInjectionTarget$1$1.proceed(ManagedBean.java:161) > at com.oracle.injection.provider.weld.WeldInjectionServicesAdapter.aroundInject(WeldInjectionServicesAdapter.java:103) > at org.jboss.weld.injection.InjectionContextImpl.run(InjectionContextImpl.java:46) > at org.jboss.weld.bean.ManagedBean$ManagedBeanInjectionTarget$1.work(ManagedBean.java:157) > at org.jboss.weld.bean.ManagedBean$FixInjectionPoint.run(ManagedBean.java:131) > at org.jboss.weld.bean.ManagedBean$ManagedBeanInjectionTarget.inject(ManagedBean.java:153) > at org.jboss.weld.bean.ManagedBean.create(ManagedBean.java:293) > at org.jboss.weld.context.AbstractContext.get(AbstractContext.java:103) > at org.jboss.weld.bean.proxy.ContextBeanInstance.getInstance(ContextBeanInstance.java:90) > at org.jboss.weld.bean.proxy.ProxyMethodHandler.invoke(ProxyMethodHandler.java:79) > at org.uberfire.backend.server.repositories.RepositoryServiceImpl$Proxy$_$$_WeldClientProxy.getRepository(RepositoryServiceImpl$Proxy$_$$_WeldClientProxy.java) > at org.drools.workbench.backend.server.AppSetup.assertPlayground(AppSetup.java:81) > at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) > at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) > at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) > at java.lang.reflect.Method.invoke(Method.java:601) > at org.jboss.weld.util.reflection.SecureReflections$13.work(SecureReflections.java:267) > at org.jboss.weld.util.reflection.SecureReflectionAccess.run(SecureReflectionAccess.java:52) > at org.jboss.weld.util.reflection.SecureReflectionAccess.runAsInvocation(SecureReflectionAccess.java:137) > at org.jboss.weld.util.reflection.SecureReflections.invoke(SecureReflections.java:263) > at org.jboss.weld.introspector.jlr.WeldMethodImpl.invoke(WeldMethodImpl.java:174) > at org.jboss.weld.bean.AbstractClassBean.defaultPostConstruct(AbstractClassBean.java:402) > at org.jboss.weld.bean.ManagedBean$ManagedBeanInjectionTarget.postConstruct(ManagedBean.java:174) > at org.jboss.weld.bean.ManagedBean.create(ManagedBean.java:294) > at org.jboss.weld.context.AbstractContext.get(AbstractContext.java:103) > at org.jboss.weld.bean.proxy.ContextBeanInstance.getInstance(ContextBeanInstance.java:90) > at org.jboss.weld.bean.proxy.ProxyMethodHandler.invoke(ProxyMethodHandler.java:79) > at org.drools.workbench.backend.server.AppSetup$Proxy$_$$_WeldClientProxy.toString(AppSetup$Proxy$_$$_WeldClientProxy.java) > at org.uberfire.commons.services.cdi.StartupBeanExtension.runPostConstruct(StartupBeanExtension.java:83) > at org.uberfire.commons.services.cdi.StartupBeanExtension.afterDeploymentValidation(StartupBeanExtension.java:67) > at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) > at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) > at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) > at java.lang.reflect.Method.invoke(Method.java:601) > at org.jboss.weld.util.reflection.SecureReflections$13.work(SecureReflections.java:267) > at org.jboss.weld.util.reflection.SecureReflectionAccess.run(SecureReflectionAccess.java:52) > at org.jboss.weld.util.reflection.SecureReflectionAccess.runAsInvocation(SecureReflectionAccess.java:137) > at org.jboss.weld.util.reflection.SecureReflections.invoke(SecureReflections.java:263) > at org.jboss.weld.introspector.jlr.WeldMethodImpl.invokeOnInstance(WeldMethodImpl.java:170) > at org.jboss.weld.introspector.ForwardingWeldMethod.invokeOnInstance(ForwardingWeldMethod.java:51) > at org.jboss.weld.injection.MethodInjectionPoint.invokeOnInstanceWithSpecialValue(MethodInjectionPoint.java:154) > at org.jboss.weld.event.ObserverMethodImpl.sendEvent(ObserverMethodImpl.java:245) > at org.jboss.weld.event.ObserverMethodImpl.sendEvent(ObserverMethodImpl.java:233) > at org.jboss.weld.event.ObserverMethodImpl.notify(ObserverMethodImpl.java:213) > at org.jboss.weld.bootstrap.events.AbstractContainerEvent.fire(AbstractContainerEvent.java:75) > at org.jboss.weld.bootstrap.events.AbstractDeploymentContainerEvent.fire(AbstractDeploymentContainerEvent.java:46) > at org.jboss.weld.bootstrap.events.AfterDeploymentValidationImpl.fire(AfterDeploymentValidationImpl.java:31) > at org.jboss.weld.bootstrap.WeldBootstrap.validateBeans(WeldBootstrap.java:382) > at com.oracle.injection.provider.weld.WeldInjectionContainer.start(WeldInjectionContainer.java:106) > at com.oracle.injection.integration.CDIAppDeploymentExtension.initCdi(CDIAppDeploymentExtension.java:70) > at com.oracle.injection.integration.CDIAppDeploymentExtension.activate(CDIAppDeploymentExtension.java:47) > at weblogic.application.internal.flow.AppDeploymentExtensionFlow.activate(AppDeploymentExtensionFlow.java:37) > at weblogic.application.internal.BaseDeployment$2.next(BaseDeployment.java:729) > at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:42) > at weblogic.application.internal.BaseDeployment.activate(BaseDeployment.java:258) > at weblogic.application.internal.SingleModuleDeployment.activate(SingleModuleDeployment.java:48) > at weblogic.application.internal.DeploymentStateChecker.activate(DeploymentStateChecker.java:165) > at weblogic.deploy.internal.targetserver.AppContainerInvoker.activate(AppContainerInvoker.java:80) > at weblogic.deploy.internal.targetserver.operations.AbstractOperation.activate(AbstractOperation.java:586) > at weblogic.deploy.internal.targetserver.operations.ActivateOperation.activateDeployment(ActivateOperation.java:148) > at weblogic.deploy.internal.targetserver.operations.ActivateOperation.doCommit(ActivateOperation.java:114) > at weblogic.deploy.internal.targetserver.operations.AbstractOperation.commit(AbstractOperation.java:339) > at weblogic.deploy.internal.targetserver.DeploymentManager.handleDeploymentCommit(DeploymentManager.java:846) > at weblogic.deploy.internal.targetserver.DeploymentManager.activateDeploymentList(DeploymentManager.java:1275) > at weblogic.deploy.internal.targetserver.DeploymentManager.handleCommit(DeploymentManager.java:442) > at weblogic.deploy.internal.targetserver.DeploymentServiceDispatcher.commit(DeploymentServiceDispatcher.java:176) > at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer.doCommitCallback(DeploymentReceiverCallbackDeliverer.java:195) > at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer.access$100(DeploymentReceiverCallbackDeliverer.java:13) > at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer$2.run(DeploymentReceiverCallbackDeliverer.java:68) > at weblogic.work.SelfTuningWorkManagerImpl$WorkAdapterImpl.run(SelfTuningWorkManagerImpl.java:550) > at weblogic.work.ExecuteThread.execute(ExecuteThread.java:295) > at weblogic.work.ExecuteThread.run(ExecuteThread.java:254) > > > Exception 0 : > org.jboss.weld.exceptions.WeldException: WELD-000049 Unable to invoke [method] @PostConstruct public org.drools.workbench.backend.server.AppSetup.assertPlayground() on org.drools.workbench.backend.server.AppSetup at 70f21c3b > at org.jboss.weld.bean.AbstractClassBean.defaultPostConstruct(AbstractClassBean.java:404) > at org.jboss.weld.bean.ManagedBean$ManagedBeanInjectionTarget.postConstruct(ManagedBean.java:174) > at org.jboss.weld.bean.ManagedBean.create(ManagedBean.java:294) > at org.jboss.weld.context.AbstractContext.get(AbstractContext.java:103) > at org.jboss.weld.bean.proxy.ContextBeanInstance.getInstance(ContextBeanInstance.java:90) > at org.jboss.weld.bean.proxy.ProxyMethodHandler.invoke(ProxyMethodHandler.java:79) > at org.drools.workbench.backend.server.AppSetup$Proxy$_$$_WeldClientProxy.toString(AppSetup$Proxy$_$$_WeldClientProxy.java) > at org.uberfire.commons.services.cdi.StartupBeanExtension.runPostConstruct(StartupBeanExtension.java:83) > at org.uberfire.commons.services.cdi.StartupBeanExtension.afterDeploymentValidation(StartupBeanExtension.java:67) > at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) > at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) > at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) > at java.lang.reflect.Method.invoke(Method.java:601) > at org.jboss.weld.util.reflection.SecureReflections$13.work(SecureReflections.java:267) > at org.jboss.weld.util.reflection.SecureReflectionAccess.run(SecureReflectionAccess.java:52) > at org.jboss.weld.util.reflection.SecureReflectionAccess.runAsInvocation(SecureReflectionAccess.java:137) > at org.jboss.weld.util.reflection.SecureReflections.invoke(SecureReflections.java:263) > at org.jboss.weld.introspector.jlr.WeldMethodImpl.invokeOnInstance(WeldMethodImpl.java:170) > at org.jboss.weld.introspector.ForwardingWeldMethod.invokeOnInstance(ForwardingWeldMethod.java:51) > at org.jboss.weld.injection.MethodInjectionPoint.invokeOnInstanceWithSpecialValue(MethodInjectionPoint.java:154) > at org.jboss.weld.event.ObserverMethodImpl.sendEvent(ObserverMethodImpl.java:245) > at org.jboss.weld.event.ObserverMethodImpl.sendEvent(ObserverMethodImpl.java:233) > at org.jboss.weld.event.ObserverMethodImpl.notify(ObserverMethodImpl.java:213) > at org.jboss.weld.bootstrap.events.AbstractContainerEvent.fire(AbstractContainerEvent.java:75) > at org.jboss.weld.bootstrap.events.AbstractDeploymentContainerEvent.fire(AbstractDeploymentContainerEvent.java:46) > at org.jboss.weld.bootstrap.events.AfterDeploymentValidationImpl.fire(AfterDeploymentValidationImpl.java:31) > at org.jboss.weld.bootstrap.WeldBootstrap.validateBeans(WeldBootstrap.java:382) > at com.oracle.injection.provider.weld.WeldInjectionContainer.start(WeldInjectionContainer.java:106) > at com.oracle.injection.integration.CDIAppDeploymentExtension.initCdi(CDIAppDeploymentExtension.java:70) > at com.oracle.injection.integration.CDIAppDeploymentExtension.activate(CDIAppDeploymentExtension.java:47) > at weblogic.application.internal.flow.AppDeploymentExtensionFlow.activate(AppDeploymentExtensionFlow.java:37) > at weblogic.application.internal.BaseDeployment$2.next(BaseDeployment.java:729) > at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:42) > at weblogic.application.internal.BaseDeployment.activate(BaseDeployment.java:258) > at weblogic.application.internal.SingleModuleDeployment.activate(SingleModuleDeployment.java:48) > at weblogic.application.internal.DeploymentStateChecker.activate(DeploymentStateChecker.java:165) > at weblogic.deploy.internal.targetserver.AppContainerInvoker.activate(AppContainerInvoker.java:80) > at weblogic.deploy.internal.targetserver.operations.AbstractOperation.activate(AbstractOperation.java:586) > at weblogic.deploy.internal.targetserver.operations.ActivateOperation.activateDeployment(ActivateOperation.java:148) > at weblogic.deploy.internal.targetserver.operations.ActivateOperation.doCommit(ActivateOperation.java:114) > at weblogic.deploy.internal.targetserver.operations.AbstractOperation.commit(AbstractOperation.java:339) > at weblogic.deploy.internal.targetserver.DeploymentManager.handleDeploymentCommit(DeploymentManager.java:846) > at weblogic.deploy.internal.targetserver.DeploymentManager.activateDeploymentList(DeploymentManager.java:1275) > at weblogic.deploy.internal.targetserver.DeploymentManager.handleCommit(DeploymentManager.java:442) > at weblogic.deploy.internal.targetserver.DeploymentServiceDispatcher.commit(DeploymentServiceDispatcher.java:176) > at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer.doCommitCallback(DeploymentReceiverCallbackDeliverer.java:195) > at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer.access$100(DeploymentReceiverCallbackDeliverer.java:13) > at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer$2.run(DeploymentReceiverCallbackDeliverer.java:68) > at weblogic.work.SelfTuningWorkManagerImpl$WorkAdapterImpl.run(SelfTuningWorkManagerImpl.java:550) > at weblogic.work.ExecuteThread.execute(ExecuteThread.java:295) > at weblogic.work.ExecuteThread.run(ExecuteThread.java:254) > Caused by: java.lang.reflect.InvocationTargetException > at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) > at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) > at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) > at java.lang.reflect.Method.invoke(Method.java:601) > at org.jboss.weld.util.reflection.SecureReflections$13.work(SecureReflections.java:267) > at org.jboss.weld.util.reflection.SecureReflectionAccess.run(SecureReflectionAccess.java:52) > at org.jboss.weld.util.reflection.SecureReflectionAccess.runAsInvocation(SecureReflectionAccess.java:137) > at org.jboss.weld.util.reflection.SecureReflections.invoke(SecureReflections.java:263) > at org.jboss.weld.introspector.jlr.WeldMethodImpl.invoke(WeldMethodImpl.java:174) > at org.jboss.weld.bean.AbstractClassBean.defaultPostConstruct(AbstractClassBean.java:402) > ... 50 more > Caused by: org.jboss.weld.exceptions.WeldException: WELD-000049 Unable to invoke [method] @PostConstruct public org.uberfire.backend.server.config.ConfigurationServiceImpl.setup() on org.uberfire.backend.server.config.ConfigurationServiceImpl at 78f06eac > at org.jboss.weld.bean.AbstractClassBean.defaultPostConstruct(AbstractClassBean.java:404) > at org.jboss.weld.bean.ManagedBean$ManagedBeanInjectionTarget.postConstruct(ManagedBean.java:174) > at org.jboss.weld.bean.ManagedBean.create(ManagedBean.java:294) > at org.jboss.weld.context.AbstractContext.get(AbstractContext.java:103) > at org.jboss.weld.bean.proxy.ContextBeanInstance.getInstance(ContextBeanInstance.java:90) > at org.jboss.weld.bean.proxy.ProxyMethodHandler.invoke(ProxyMethodHandler.java:79) > at org.uberfire.backend.server.config.ConfigurationServiceImpl$Proxy$_$$_WeldClientProxy.getConfiguration(ConfigurationServiceImpl$Proxy$_$$_WeldClientProxy.java) > at org.drools.workbench.backend.server.AppSetup.defineGlobalProperties(AppSetup.java:112) > at org.drools.workbench.backend.server.AppSetup.assertPlayground(AppSetup.java:106) > ... 60 more > Caused by: java.lang.reflect.InvocationTargetException > at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) > at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) > at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) > at java.lang.reflect.Method.invoke(Method.java:601) > at org.jboss.weld.util.reflection.SecureReflections$13.work(SecureReflections.java:267) > at org.jboss.weld.util.reflection.SecureReflectionAccess.run(SecureReflectionAccess.java:52) > at org.jboss.weld.util.reflection.SecureReflectionAccess.runAsInvocation(SecureReflectionAccess.java:137) > at org.jboss.weld.util.reflection.SecureReflections.invoke(SecureReflections.java:263) > at org.jboss.weld.introspector.jlr.WeldMethodImpl.invoke(WeldMethodImpl.java:174) > at org.jboss.weld.bean.AbstractClassBean.defaultPostConstruct(AbstractClassBean.java:402) > ... 68 more > Caused by: org.uberfire.java.nio.file.FileSystemNotFoundException: Provider 'git' not found > at org.uberfire.java.nio.file.api.FileSystemProviders.getProvider(FileSystemProviders.java:108) > at org.uberfire.java.nio.file.api.FileSystemProviders.resolveProvider(FileSystemProviders.java:98) > at org.uberfire.java.nio.file.FileSystems.newFileSystem(FileSystems.java:117) > at org.uberfire.java.nio.file.FileSystems.newFileSystem(FileSystems.java:83) > at org.uberfire.io.impl.AbstractIOService.newFileSystem(AbstractIOService.java:251) > at org.uberfire.backend.server.config.ConfigurationServiceImpl.setup(ConfigurationServiceImpl.java:77) > ... 78 more > " > weblogic.management.DeploymentException: org.jboss.weld.exceptions.DeploymentException: Exception List with 1 exceptions: > Exception 0 : > org.jboss.weld.exceptions.WeldException: WELD-000049 Unable to invoke [method] @PostConstruct public org.drools.workbench.backend.server.AppSetup.assertPlayground() on org.drools.workbench.backend.server.AppSetup at 70f21c3b > at org.jboss.weld.bean.AbstractClassBean.defaultPostConstruct(AbstractClassBean.java:404) > at org.jboss.weld.bean.ManagedBean$ManagedBeanInjectionTarget.postConstruct(ManagedBean.java:174) > at org.jboss.weld.bean.ManagedBean.create(ManagedBean.java:294) > at org.jboss.weld.context.AbstractContext.get(AbstractContext.java:103) > at org.jboss.weld.bean.proxy.ContextBeanInstance.getInstance(ContextBeanInstance.java:90) > at org.jboss.weld.bean.proxy.ProxyMethodHandler.invoke(ProxyMethodHandler.java:79) > at org.drools.workbench.backend.server.AppSetup$Proxy$_$$_WeldClientProxy.toString(AppSetup$Proxy$_$$_WeldClientProxy.java) > at org.uberfire.commons.services.cdi.StartupBeanExtension.runPostConstruct(StartupBeanExtension.java:83) > at org.uberfire.commons.services.cdi.StartupBeanExtension.afterDeploymentValidation(StartupBeanExtension.java:67) > at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) > at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) > at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) > at java.lang.reflect.Method.invoke(Method.java:601) > at org.jboss.weld.util.reflection.SecureReflections$13.work(SecureReflections.java:267) > at org.jboss.weld.util.reflection.SecureReflectionAccess.run(SecureReflectionAccess.java:52) > at org.jboss.weld.util.reflection.SecureReflectionAccess.runAsInvocation(SecureReflectionAccess.java:137) > at org.jboss.weld.util.reflection.SecureReflections.invoke(SecureReflections.java:263) > at org.jboss.weld.introspector.jlr.WeldMethodImpl.invokeOnInstance(WeldMethodImpl.java:170) > at org.jboss.weld.introspector.ForwardingWeldMethod.invokeOnInstance(ForwardingWeldMethod.java:51) > at org.jboss.weld.injection.MethodInjectionPoint.invokeOnInstanceWithSpecialValue(MethodInjectionPoint.java:154) > at org.jboss.weld.event.ObserverMethodImpl.sendEvent(ObserverMethodImpl.java:245) > at org.jboss.weld.event.ObserverMethodImpl.sendEvent(ObserverMethodImpl.java:233) > at org.jboss.weld.event.ObserverMethodImpl.notify(ObserverMethodImpl.java:213) > at org.jboss.weld.bootstrap.events.AbstractContainerEvent.fire(AbstractContainerEvent.java:75) > at org.jboss.weld.bootstrap.events.AbstractDeploymentContainerEvent.fire(AbstractDeploymentContainerEvent.java:46) > at org.jboss.weld.bootstrap.events.AfterDeploymentValidationImpl.fire(AfterDeploymentValidationImpl.java:31) > at org.jboss.weld.bootstrap.WeldBootstrap.validateBeans(WeldBootstrap.java:382) > at com.oracle.injection.provider.weld.WeldInjectionContainer.start(WeldInjectionContainer.java:106) > at com.oracle.injection.integration.CDIAppDeploymentExtension.initCdi(CDIAppDeploymentExtension.java:70) > at com.oracle.injection.integration.CDIAppDeploymentExtension.activate(CDIAppDeploymentExtension.java:47) > at weblogic.application.internal.flow.AppDeploymentExtensionFlow.activate(AppDeploymentExtensionFlow.java:37) > at weblogic.application.internal.BaseDeployment$2.next(BaseDeployment.java:729) > at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:42) > at weblogic.application.internal.BaseDeployment.activate(BaseDeployment.java:258) > at weblogic.application.internal.SingleModuleDeployment.activate(SingleModuleDeployment.java:48) > at weblogic.application.internal.DeploymentStateChecker.activate(DeploymentStateChecker.java:165) > at weblogic.deploy.internal.targetserver.AppContainerInvoker.activate(AppContainerInvoker.java:80) > at weblogic.deploy.internal.targetserver.operations.AbstractOperation.activate(AbstractOperation.java:586) > at weblogic.deploy.internal.targetserver.operations.ActivateOperation.activateDeployment(ActivateOperation.java:148) > at weblogic.deploy.internal.targetserver.operations.ActivateOperation.doCommit(ActivateOperation.java:114) > at weblogic.deploy.internal.targetserver.operations.AbstractOperation.commit(AbstractOperation.java:339) > at weblogic.deploy.internal.targetserver.DeploymentManager.handleDeploymentCommit(DeploymentManager.java:846) > at weblogic.deploy.internal.targetserver.DeploymentManager.activateDeploymentList(DeploymentManager.java:1275) > at weblogic.deploy.internal.targetserver.DeploymentManager.handleCommit(DeploymentManager.java:442) > at weblogic.deploy.internal.targetserver.DeploymentServiceDispatcher.commit(DeploymentServiceDispatcher.java:176) > at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer.doCommitCallback(DeploymentReceiverCallbackDeliverer.java:195) > at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer.access$100(DeploymentReceiverCallbackDeliverer.java:13) > at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer$2.run(DeploymentReceiverCallbackDeliverer.java:68) > at weblogic.work.SelfTuningWorkManagerImpl$WorkAdapterImpl.run(SelfTuningWorkManagerImpl.java:550) > at weblogic.work.ExecuteThread.execute(ExecuteThread.java:295) > at weblogic.work.ExecuteThread.run(ExecuteThread.java:254) > Caused by: java.lang.reflect.InvocationTargetException > at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) > at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) > at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) > at java.lang.reflect.Method.invoke(Method.java:601) > at org.jboss.weld.util.reflection.SecureReflections$13.work(SecureReflections.java:267) > at org.jboss.weld.util.reflection.SecureReflectionAccess.run(SecureReflectionAccess.java:52) > at org.jboss.weld.util.reflection.SecureReflectionAccess.runAsInvocation(SecureReflectionAccess.java:137) > at org.jboss.weld.util.reflection.SecureReflections.invoke(SecureReflections.java:263) > at org.jboss.weld.introspector.jlr.WeldMethodImpl.invoke(WeldMethodImpl.java:174) > at org.jboss.weld.bean.AbstractClassBean.defaultPostConstruct(AbstractClassBean.java:402) > ... 50 more > Caused by: org.jboss.weld.exceptions.WeldException: WELD-000049 Unable to invoke [method] @PostConstruct public org.uberfire.backend.server.config.ConfigurationServiceImpl.setup() on org.uberfire.backend.server.config.ConfigurationServiceImpl at 78f06eac > at org.jboss.weld.bean.AbstractClassBean.defaultPostConstruct(AbstractClassBean.java:404) > at org.jboss.weld.bean.ManagedBean$ManagedBeanInjectionTarget.postConstruct(ManagedBean.java:174) > at org.jboss.weld.bean.ManagedBean.create(ManagedBean.java:294) > at org.jboss.weld.context.AbstractContext.get(AbstractContext.java:103) > at org.jboss.weld.bean.proxy.ContextBeanInstance.getInstance(ContextBeanInstance.java:90) > at org.jboss.weld.bean.proxy.ProxyMethodHandler.invoke(ProxyMethodHandler.java:79) > at org.uberfire.backend.server.config.ConfigurationServiceImpl$Proxy$_$$_WeldClientProxy.getConfiguration(ConfigurationServiceImpl$Proxy$_$$_WeldClientProxy.java) > at org.drools.workbench.backend.server.AppSetup.defineGlobalProperties(AppSetup.java:112) > at org.drools.workbench.backend.server.AppSetup.assertPlayground(AppSetup.java:106) > ... 60 more > Caused by: java.lang.reflect.InvocationTargetException > at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) > at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) > at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) > at java.lang.reflect.Method.invoke(Method.java:601) > at org.jboss.weld.util.reflection.SecureReflections$13.work(SecureReflections.java:267) > at org.jboss.weld.util.reflection.SecureReflectionAccess.run(SecureReflectionAccess.java:52) > at org.jboss.weld.util.reflection.SecureReflectionAccess.runAsInvocation(SecureReflectionAccess.java:137) > at org.jboss.weld.util.reflection.SecureReflections.invoke(SecureReflections.java:263) > at org.jboss.weld.introspector.jlr.WeldMethodImpl.invoke(WeldMethodImpl.java:174) > at org.jboss.weld.bean.AbstractClassBean.defaultPostConstruct(AbstractClassBean.java:402) > ... 68 more > Caused by: org.uberfire.java.nio.file.FileSystemNotFoundException: Provider 'git' not found > at org.uberfire.java.nio.file.api.FileSystemProviders.getProvider(FileSystemProviders.java:108) > at org.uberfire.java.nio.file.api.FileSystemProviders.resolveProvider(FileSystemProviders.java:98) > at org.uberfire.java.nio.file.FileSystems.newFileSystem(FileSystems.java:117) > at org.uberfire.java.nio.file.FileSystems.newFileSystem(FileSystems.java:83) > at org.uberfire.io.impl.AbstractIOService.newFileSystem(AbstractIOService.java:251) > at org.uberfire.backend.server.config.ConfigurationServiceImpl.setup(ConfigurationServiceImpl.java:77) > ... 78 more > > at weblogic.application.internal.BaseDeployment.throwAppException(BaseDeployment.java:123) > at weblogic.application.internal.BaseDeployment.activate(BaseDeployment.java:260) > at weblogic.application.internal.SingleModuleDeployment.activate(SingleModuleDeployment.java:48) > at weblogic.application.internal.DeploymentStateChecker.activate(DeploymentStateChecker.java:165) > at weblogic.deploy.internal.targetserver.AppContainerInvoker.activate(AppContainerInvoker.java:80) > Truncated. see log file for complete stacktrace > Caused By: org.jboss.weld.exceptions.DeploymentException: Exception List with 1 exceptions: > Exception 0 : > org.jboss.weld.exceptions.WeldException: WELD-000049 Unable to invoke [method] @PostConstruct public org.drools.workbench.backend.server.AppSetup.assertPlayground() on org.drools.workbench.backend.server.AppSetup at 70f21c3b > at org.jboss.weld.bean.AbstractClassBean.defaultPostConstruct(AbstractClassBean.java:404) > at org.jboss.weld.bean.ManagedBean$ManagedBeanInjectionTarget.postConstruct(ManagedBean.java:174) > at org.jboss.weld.bean.ManagedBean.create(ManagedBean.java:294) > at org.jboss.weld.context.AbstractContext.get(AbstractContext.java:103) > at org.jboss.weld.bean.proxy.ContextBeanInstance.getInstance(ContextBeanInstance.java:90) > at org.jboss.weld.bean.proxy.ProxyMethodHandler.invoke(ProxyMethodHandler.java:79) > at org.drools.workbench.backend.server.AppSetup$Proxy$_$$_WeldClientProxy.toString(AppSetup$Proxy$_$$_WeldClientProxy.java) > at org.uberfire.commons.services.cdi.StartupBeanExtension.runPostConstruct(StartupBeanExtension.java:83) > at org.uberfire.commons.services.cdi.StartupBeanExtension.afterDeploymentValidation(StartupBeanExtension.java:67) > at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) > at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) > at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) > at java.lang.reflect.Method.invoke(Method.java:601) > at org.jboss.weld.util.reflection.SecureReflections$13.work(SecureReflections.java:267) > at org.jboss.weld.util.reflection.SecureReflectionAccess.run(SecureReflectionAccess.java:52) > at org.jboss.weld.util.reflection.SecureReflectionAccess.runAsInvocation(SecureReflectionAccess.java:137) > at org.jboss.weld.util.reflection.SecureReflections.invoke(SecureReflections.java:263) > at org.jboss.weld.introspector.jlr.WeldMethodImpl.invokeOnInstance(WeldMethodImpl.java:170) > at org.jboss.weld.introspector.ForwardingWeldMethod.invokeOnInstance(ForwardingWeldMethod.java:51) > at org.jboss.weld.injection.MethodInjectionPoint.invokeOnInstanceWithSpecialValue(MethodInjectionPoint.java:154) > at org.jboss.weld.event.ObserverMethodImpl.sendEvent(ObserverMethodImpl.java:245) > at org.jboss.weld.event.ObserverMethodImpl.sendEvent(ObserverMethodImpl.java:233) > at org.jboss.weld.event.ObserverMethodImpl.notify(ObserverMethodImpl.java:213) > at org.jboss.weld.bootstrap.events.AbstractContainerEvent.fire(AbstractContainerEvent.java:75) > at org.jboss.weld.bootstrap.events.AbstractDeploymentContainerEvent.fire(AbstractDeploymentContainerEvent.java:46) > at org.jboss.weld.bootstrap.events.AfterDeploymentValidationImpl.fire(AfterDeploymentValidationImpl.java:31) > at org.jboss.weld.bootstrap.WeldBootstrap.validateBeans(WeldBootstrap.java:382) > at com.oracle.injection.provider.weld.WeldInjectionContainer.start(WeldInjectionContainer.java:106) > at com.oracle.injection.integration.CDIAppDeploymentExtension.initCdi(CDIAppDeploymentExtension.java:70) > at com.oracle.injection.integration.CDIAppDeploymentExtension.activate(CDIAppDeploymentExtension.java:47) > at weblogic.application.internal.flow.AppDeploymentExtensionFlow.activate(AppDeploymentExtensionFlow.java:37) > at weblogic.application.internal.BaseDeployment$2.next(BaseDeployment.java:729) > at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:42) > at weblogic.application.internal.BaseDeployment.activate(BaseDeployment.java:258) > at weblogic.application.internal.SingleModuleDeployment.activate(SingleModuleDeployment.java:48) > at weblogic.application.internal.DeploymentStateChecker.activate(DeploymentStateChecker.java:165) > at weblogic.deploy.internal.targetserver.AppContainerInvoker.activate(AppContainerInvoker.java:80) > at weblogic.deploy.internal.targetserver.operations.AbstractOperation.activate(AbstractOperation.java:586) > at weblogic.deploy.internal.targetserver.operations.ActivateOperation.activateDeployment(ActivateOperation.java:148) > at weblogic.deploy.internal.targetserver.operations.ActivateOperation.doCommit(ActivateOperation.java:114) > at weblogic.deploy.internal.targetserver.operations.AbstractOperation.commit(AbstractOperation.java:339) > at weblogic.deploy.internal.targetserver.DeploymentManager.handleDeploymentCommit(DeploymentManager.java:846) > at weblogic.deploy.internal.targetserver.DeploymentManager.activateDeploymentList(DeploymentManager.java:1275) > at weblogic.deploy.internal.targetserver.DeploymentManager.handleCommit(DeploymentManager.java:442) > at weblogic.deploy.internal.targetserver.DeploymentServiceDispatcher.commit(DeploymentServiceDispatcher.java:176) > at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer.doCommitCallback(DeploymentReceiverCallbackDeliverer.java:195) > at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer.access$100(DeploymentReceiverCallbackDeliverer.java:13) > at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer$2.run(DeploymentReceiverCallbackDeliverer.java:68) > at weblogic.work.SelfTuningWorkManagerImpl$WorkAdapterImpl.run(SelfTuningWorkManagerImpl.java:550) > at weblogic.work.ExecuteThread.execute(ExecuteThread.java:295) > at weblogic.work.ExecuteThread.run(ExecuteThread.java:254) > Caused by: java.lang.reflect.InvocationTargetException > at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) > at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) > at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) > at java.lang.reflect.Method.invoke(Method.java:601) > at org.jboss.weld.util.reflection.SecureReflections$13.work(SecureReflections.java:267) > at org.jboss.weld.util.reflection.SecureReflectionAccess.run(SecureReflectionAccess.java:52) > at org.jboss.weld.util.reflection.SecureReflectionAccess.runAsInvocation(SecureReflectionAccess.java:137) > at org.jboss.weld.util.reflection.SecureReflections.invoke(SecureReflections.java:263) > at org.jboss.weld.introspector.jlr.WeldMethodImpl.invoke(WeldMethodImpl.java:174) > at org.jboss.weld.bean.AbstractClassBean.defaultPostConstruct(AbstractClassBean.java:402) > ... 50 more > Caused by: org.jboss.weld.exceptions.WeldException: WELD-000049 Unable to invoke [method] @PostConstruct public org.uberfire.backend.server.config.ConfigurationServiceImpl.setup() on org.uberfire.backend.server.config.ConfigurationServiceImpl at 78f06eac > at org.jboss.weld.bean.AbstractClassBean.defaultPostConstruct(AbstractClassBean.java:404) > at org.jboss.weld.bean.ManagedBean$ManagedBeanInjectionTarget.postConstruct(ManagedBean.java:174) > at org.jboss.weld.bean.ManagedBean.create(ManagedBean.java:294) > The e-mail message you have received and any files transmitted with it are intended solely for the addresses(s) and may be legally privileged and/or confidential. If you have received this e-mail message in error, please delete it and all copies of it from your system including all hard copies thereof. Any unauthorized use or disclosure may be unlawful. Any confidentiality or privilege is not waived or lost because this message and its contents have been sent to you by mistake. Allianz Ayudhya Assurance Pcl. or its affiliates accept no responsibility either jointly or severally for any loss or damage for use of this e-mail. > > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140728/e389fc97/attachment-0001.html From avramanaareddy at yahoo.com Mon Jul 28 10:22:03 2014 From: avramanaareddy at yahoo.com (Venkata Ramana Reddy Avula) Date: Mon, 28 Jul 2014 22:22:03 +0800 Subject: [rules-users] (no subject) Message-ID: <1406557323.17787.YahooMailNeo@web190205.mail.sg3.yahoo.com> Hi, I am implementing rules engine into my project, I have been referring the many technical resources about jboss drools. I did implement some set of rules which are much more needed for my project. All of a sudden after I placed all the rules in the spreadsheet(.xls) file, and executed it, it shows me strange exceptions like this below. It was reading the xls file, creating .drl file, that also we can see, but it is showing the errors. Can anyone help me please on this, I am very much tried, could not able to resolve. I need a clue how to do that. This is my class, where I will have conditional parameters package com.dfs.dsa.rules; public class QuarterlyBonusRules { private Double attendancePercentage = null; public Double getAttendancePercentage() { return attendancePercentage; } public void setAttendancePercentage(Double attendancePercentage) { this.attendancePercentage = attendancePercentage; } public int getMinorCollisionDays() { return minorCollisionDays; } public void setMinorCollisionDays(int minorCollisionDays) { this.minorCollisionDays = minorCollisionDays; } public int getMajorCollisionDays() { return majorCollisionDays; } public void setMajorCollisionDays(int majorCollisionDays) { this.majorCollisionDays = majorCollisionDays; } private int minorCollisionDays; private int majorCollisionDays; private int bonusAmount = 11; private boolean violationAssessed = false; public int getBonusAmount() { return bonusAmount; } public void setBonusAmount(int bonusAmount) { this.bonusAmount = bonusAmount; } public boolean isViolationAssessed() { return violationAssessed; } public void setViolationAssessed(boolean violationAssessed) { this.violationAssessed = violationAssessed; } } Then I do have one test class to execute the rules package com.dfs.dsa.rules; import java.io.BufferedWriter; import java.io.File; import java.io.FileInputStream; import java.io.FileNotFoundException; import java.io.FileWriter; import java.io.IOException; import java.io.InputStream; import java.util.Collection; import org.drools.KnowledgeBase; import org.drools.KnowledgeBaseFactory; import org.drools.builder.KnowledgeBuilder; import org.drools.builder.KnowledgeBuilderFactory; import org.drools.builder.ResourceType; import org.drools.decisiontable.InputType; import org.drools.decisiontable.SpreadsheetCompiler; import org.drools.event.rule.DebugAgendaEventListener; import org.drools.event.rule.DebugWorkingMemoryEventListener; import org.drools.io.ResourceFactory; import org.drools.runtime.StatefulKnowledgeSession; /** ?* This class will create a drl file from excel sheet and then execute the ?* rules. ?*/ @SuppressWarnings("restriction") public class QBResult { public static final void main(final String[] args) { // Create knowledge builder final KnowledgeBuilder kbuilder = KnowledgeBuilderFactory .newKnowledgeBuilder(); // Create drl file from excel sheet InputStream is = null; try { is = new FileInputStream("c:/myeclipse/DroolsProject/src/QuarterlyBonusRules.xls"); } catch (FileNotFoundException e) { e.printStackTrace(); } // Create compiler class instance SpreadsheetCompiler sc = new SpreadsheetCompiler(); // Compile the excel to generate the (.drl) file StringBuffer drl = new StringBuffer(sc.compile(is, InputType.XLS)); // Insert dialect value into drl file drl.insert(drl.indexOf("DROOLS") + 40, "dialect \"mvel\"" + "\n"); // Check the generated drl file System.out.println("Generate DRL file is showing below?: "); System.out.println(drl); // writing string into a drl file try { BufferedWriter out = new BufferedWriter(new FileWriter( "QuarterlyBonusRules.drl")); out.write(drl.toString()); out.close(); } catch (IOException e) { System.out.println("Exception "); } // Wait before using the drl file in the next section. try { Thread.sleep(100); } catch (InterruptedException e) { e.printStackTrace(); } kbuilder.add(ResourceFactory.newFileResource(new File( "QuarterlyBonusRules.drl")), ResourceType.DRL); if (kbuilder.hasErrors()) { System.out.println("kbuilder has errors"); System.out.println(kbuilder.getErrors().toString()); } // get the compiled packages (which are serializable) final Collection pkgs = kbuilder.getKnowledgePackages(); final KnowledgeBase kbase = KnowledgeBaseFactory.newKnowledgeBase(); kbase.addKnowledgePackages(pkgs); final StatefulKnowledgeSession ksession = kbase .newStatefulKnowledgeSession(); ksession.addEventListener(new DebugAgendaEventListener()); ksession.addEventListener(new DebugWorkingMemoryEventListener()); QuarterlyBonusRules qbr = new QuarterlyBonusRules(); qbr.setAttendancePercentage(new Double(0.75)); qbr.setMinorCollisionDays(0); qbr.setMajorCollisionDays(0); qbr.setViolationAssessed(false); ksession.insert(qbr); ksession.fireAllRules(); ksession.dispose(); System.out.println(qbr.getBonusAmount()); } } AFter executing the above program, here I am getting the error, and not able to rectify it SLF4J: Failed to load class "org.slf4j.impl.StaticLoggerBinder". SLF4J: Defaulting to no-operation (NOP) logger implementation SLF4J: See http://www.slf4j.org/codes.html#StaticLoggerBinder for further details. Warning: ?Cannot read name ranges for Excel_BuiltIn__FilterDatabase_1 - setting to empty Warning: ?Cell at D21 not present - adding a blank Generate DRL file is showing below?:? package DROOLS; //generated from Decision Table dialect "mvel" import com.dfs.dsa.rules.QuarterlyBonusRules; // rule values at B11, header at B6 rule "1" when qbr:QuarterlyBonusRules(attendancePercentage>=0.75) (minorCollisionDays>=0 && minorCollisionDays<=0); (majorCollisionDays>=0 && majorCollisionDays<=0); violationAssessed==false; then qbr.setBonusAmount(150); end // rule values at B12, header at B6 rule "2" when qbr:QuarterlyBonusRules(attendancePercentage>=0.56) (minorCollisionDays>=0 && minorCollisionDays<=90); (majorCollisionDays>=0 && majorCollisionDays<=90); violationAssessed==true; then qbr.setBonusAmount(0); end kbuilder has errors [9,21]: [ERR 102] Line 9:21 mismatched input '>=' in rule "1" [20,21]: [ERR 102] Line 20:21 mismatched input '>=' in rule "2" [0,0]: Parser returned a null Package ==>[ObjectInsertedEventImpl: getFactHandle()=[fact 0:1:2144330803:2144330803:1:DEFAULT:com.dfs.dsa.rules.QuarterlyBonusRules at 7fcfe433], getObject()=com.dfs.dsa.rules.QuarterlyBonusRules at 7fcfe433, getKnowledgeRuntime()=org.drools.impl.StatefulKnowledgeSessionImpl at 23efdc4, getPropagationContext()=PropagationContextImpl [activeActivations=0, dormantActivations=0, entryPoint=EntryPoint::DEFAULT, factHandle=[fact 0:1:2144330803:2144330803:1:DEFAULT:com.dfs.dsa.rules.QuarterlyBonusRules at 7fcfe433], leftTuple=null, originOffset=-1, propagationNumber=4, rule=null, type=0]] 11 Note: the number 11 is the value, it has printed, that I set to the bonus amount, but it should not print that value, it should pring 150. I am here attaching the spread sheet, where I have added all the rules in it. I appreciate you a lot for the help Thanks & Regards, Venkata. -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140728/eec2574f/attachment-0001.html -------------- next part -------------- A non-text attachment was scrubbed... Name: QuarterlyBonusRules.xls Type: application/vnd.ms-excel Size: 10752 bytes Desc: not available Url : http://lists.jboss.org/pipermail/rules-users/attachments/20140728/eec2574f/attachment-0001.xls From avramanaareddy at yahoo.com Mon Jul 28 10:31:04 2014 From: avramanaareddy at yahoo.com (avramanaareddy) Date: Mon, 28 Jul 2014 07:31:04 -0700 (PDT) Subject: [rules-users] I am getting errors for Decision Table rules Message-ID: <1406557864032-4030519.post@n3.nabble.com> Hi, I am implementing rules engine into my project, I have been referring the many technical resources about jboss drools. I did implement some set of rules which are much more needed for my project. All of a sudden after I placed all the rules in the spreadsheet(.xls) file, and executed it, it shows me strange exceptions like this below. It was reading the xls file, creating .drl file, that also we can see, but it is showing the errors. Can anyone help me please on this, I am very much tried, could not able to resolve. I need a clue how to do that. This is my class, where I will have conditional parameters package com.dfs.dsa.rules; public class QuarterlyBonusRules { private Double attendancePercentage = null; public Double getAttendancePercentage() { return attendancePercentage; } public void setAttendancePercentage(Double attendancePercentage) { this.attendancePercentage = attendancePercentage; } public int getMinorCollisionDays() { return minorCollisionDays; } public void setMinorCollisionDays(int minorCollisionDays) { this.minorCollisionDays = minorCollisionDays; } public int getMajorCollisionDays() { return majorCollisionDays; } public void setMajorCollisionDays(int majorCollisionDays) { this.majorCollisionDays = majorCollisionDays; } private int minorCollisionDays; private int majorCollisionDays; private int bonusAmount = 11; private boolean violationAssessed = false; public int getBonusAmount() { return bonusAmount; } public void setBonusAmount(int bonusAmount) { this.bonusAmount = bonusAmount; } public boolean isViolationAssessed() { return violationAssessed; } public void setViolationAssessed(boolean violationAssessed) { this.violationAssessed = violationAssessed; } } Then I do have one test class to execute the rules package com.dfs.dsa.rules; import java.io.BufferedWriter; import java.io.File; import java.io.FileInputStream; import java.io.FileNotFoundException; import java.io.FileWriter; import java.io.IOException; import java.io.InputStream; import java.util.Collection; import org.drools.KnowledgeBase; import org.drools.KnowledgeBaseFactory; import org.drools.builder.KnowledgeBuilder; import org.drools.builder.KnowledgeBuilderFactory; import org.drools.builder.ResourceType; import org.drools.decisiontable.InputType; import org.drools.decisiontable.SpreadsheetCompiler; import org.drools.event.rule.DebugAgendaEventListener; import org.drools.event.rule.DebugWorkingMemoryEventListener; import org.drools.io.ResourceFactory; import org.drools.runtime.StatefulKnowledgeSession; /** * This class will create a drl file from excel sheet and then execute the * rules. */ @SuppressWarnings("restriction") public class QBResult { public static final void main(final String[] args) { // Create knowledge builder final KnowledgeBuilder kbuilder = KnowledgeBuilderFactory .newKnowledgeBuilder(); // Create drl file from excel sheet InputStream is = null; try { is = new FileInputStream("c:/myeclipse/DroolsProject/src/QuarterlyBonusRules.xls"); } catch (FileNotFoundException e) { e.printStackTrace(); } // Create compiler class instance SpreadsheetCompiler sc = new SpreadsheetCompiler(); // Compile the excel to generate the (.drl) file StringBuffer drl = new StringBuffer(sc.compile(is, InputType.XLS)); // Insert dialect value into drl file drl.insert(drl.indexOf("DROOLS") + 40, "dialect \"mvel\"" + "\n"); // Check the generated drl file System.out.println("Generate DRL file is showing below?: "); System.out.println(drl); // writing string into a drl file try { BufferedWriter out = new BufferedWriter(new FileWriter( "QuarterlyBonusRules.drl")); out.write(drl.toString()); out.close(); } catch (IOException e) { System.out.println("Exception "); } // Wait before using the drl file in the next section. try { Thread.sleep(100); } catch (InterruptedException e) { e.printStackTrace(); } kbuilder.add(ResourceFactory.newFileResource(new File( "QuarterlyBonusRules.drl")), ResourceType.DRL); if (kbuilder.hasErrors()) { System.out.println("kbuilder has errors"); System.out.println(kbuilder.getErrors().toString()); } // get the compiled packages (which are serializable) final Collection pkgs = kbuilder.getKnowledgePackages(); final KnowledgeBase kbase = KnowledgeBaseFactory.newKnowledgeBase(); kbase.addKnowledgePackages(pkgs); final StatefulKnowledgeSession ksession = kbase .newStatefulKnowledgeSession(); ksession.addEventListener(new DebugAgendaEventListener()); ksession.addEventListener(new DebugWorkingMemoryEventListener()); QuarterlyBonusRules qbr = new QuarterlyBonusRules(); qbr.setAttendancePercentage(new Double(0.75)); qbr.setMinorCollisionDays(0); qbr.setMajorCollisionDays(0); qbr.setViolationAssessed(false); ksession.insert(qbr); ksession.fireAllRules(); ksession.dispose(); System.out.println(qbr.getBonusAmount()); } } AFter executing the above program, here I am getting the error, and not able to rectify it SLF4J: Failed to load class "org.slf4j.impl.StaticLoggerBinder". SLF4J: Defaulting to no-operation (NOP) logger implementation SLF4J: See http://www.slf4j.org/codes.html#StaticLoggerBinder for further details. Warning: Cannot read name ranges for Excel_BuiltIn__FilterDatabase_1 - setting to empty Warning: Cell at D21 not present - adding a blank Generate DRL file is showing below?: package DROOLS; //generated from Decision Table dialect "mvel" import com.dfs.dsa.rules.QuarterlyBonusRules; // rule values at B11, header at B6 rule "1" when qbr:QuarterlyBonusRules(attendancePercentage>=0.75) (minorCollisionDays>=0 && minorCollisionDays<=0); (majorCollisionDays>=0 && majorCollisionDays<=0); violationAssessed==false; then qbr.setBonusAmount(150); end // rule values at B12, header at B6 rule "2" when qbr:QuarterlyBonusRules(attendancePercentage>=0.56) (minorCollisionDays>=0 && minorCollisionDays<=90); (majorCollisionDays>=0 && majorCollisionDays<=90); violationAssessed==true; then qbr.setBonusAmount(0); end kbuilder has errors [9,21]: [ERR 102] Line 9:21 mismatched input '>=' in rule "1" [20,21]: [ERR 102] Line 20:21 mismatched input '>=' in rule "2" [0,0]: Parser returned a null Package ==>[ObjectInsertedEventImpl: getFactHandle()=[fact 0:1:2144330803:2144330803:1:DEFAULT:com.dfs.dsa.rules.QuarterlyBonusRules at 7fcfe433], getObject()=com.dfs.dsa.rules.QuarterlyBonusRules at 7fcfe433, getKnowledgeRuntime()=org.drools.impl.StatefulKnowledgeSessionImpl at 23efdc4, getPropagationContext()=PropagationContextImpl [activeActivations=0, dormantActivations=0, entryPoint=EntryPoint::DEFAULT, factHandle=[fact 0:1:2144330803:2144330803:1:DEFAULT:com.dfs.dsa.rules.QuarterlyBonusRules at 7fcfe433], leftTuple=null, originOffset=-1, propagationNumber=4, rule=null, type=0]] 11 Note: the number 11 is the value, it has printed, that I set to the bonus amount, but it should not print that value, it should pring 150. I am here attaching the spread sheet, where I have added all the rules in it. I appreciate you a lot for the help Thanks & Regards, Venkata. -- View this message in context: http://drools.46999.n3.nabble.com/I-am-getting-errors-for-Decision-Table-rules-tp4030519.html Sent from the Drools: User forum mailing list archive at Nabble.com. From avramanaareddy at yahoo.com Mon Jul 28 10:34:05 2014 From: avramanaareddy at yahoo.com (Venkata Ramana Reddy Avula) Date: Mon, 28 Jul 2014 22:34:05 +0800 Subject: [rules-users] Please help me I am getting errors in DecisionTable approach In-Reply-To: <1406557323.17787.YahooMailNeo@web190205.mail.sg3.yahoo.com> References: <1406557323.17787.YahooMailNeo@web190205.mail.sg3.yahoo.com> Message-ID: <1406558045.17787.YahooMailNeo@web190205.mail.sg3.yahoo.com> Hi, I am implementing rules engine into my project, I have been referring the many technical resources about jboss drools. I did implement some set of rules which are much more needed for my project. All of a sudden after I placed all the rules in the spreadsheet(.xls) file, and executed it, it shows me strange exceptions like this below. It was reading the xls file, creating .drl file, that also we can see, but it is showing the errors. Can anyone help me please on this, I am very much tried, could not able to resolve. I need a clue how to do that. This is my class, where I will have conditional parameters package com.dfs.dsa.rules; public class QuarterlyBonusRules { private Double attendancePercentage = null; public Double getAttendancePercentage() { return attendancePercentage; } public void setAttendancePercentage(Double attendancePercentage) { this.attendancePercentage = attendancePercentage; } public int getMinorCollisionDays() { return minorCollisionDays; } public void setMinorCollisionDays(int minorCollisionDays) { this.minorCollisionDays = minorCollisionDays; } public int getMajorCollisionDays() { return majorCollisionDays; } public void setMajorCollisionDays(int majorCollisionDays) { this.majorCollisionDays = majorCollisionDays; } private int minorCollisionDays; private int majorCollisionDays; private int bonusAmount = 11; private boolean violationAssessed = false; public int getBonusAmount() { return bonusAmount; } public void setBonusAmount(int bonusAmount) { this.bonusAmount = bonusAmount; } public boolean isViolationAssessed() { return violationAssessed; } public void setViolationAssessed(boolean violationAssessed) { this.violationAssessed = violationAssessed; } } Then I do have one test class to execute the rules package com.dfs.dsa.rules; import java.io.BufferedWriter; import java.io.File; import java.io.FileInputStream; import java.io.FileNotFoundException; import java.io.FileWriter; import java.io.IOException; import java.io.InputStream; import java.util.Collection; import org.drools.KnowledgeBase; import org.drools.KnowledgeBaseFactory; import org.drools.builder.KnowledgeBuilder; import org.drools.builder.KnowledgeBuilderFactory; import org.drools.builder.ResourceType; import org.drools.decisiontable.InputType; import org.drools.decisiontable.SpreadsheetCompiler; import org.drools.event.rule.DebugAgendaEventListener; import org.drools.event.rule.DebugWorkingMemoryEventListener; import org.drools.io.ResourceFactory; import org.drools.runtime.StatefulKnowledgeSession; /** ?* This class will create a drl file from excel sheet and then execute the ?* rules. ?*/ @SuppressWarnings("restriction") public class QBResult { public static final void main(final String[] args) { // Create knowledge builder final KnowledgeBuilder kbuilder = KnowledgeBuilderFactory .newKnowledgeBuilder(); // Create drl file from excel sheet InputStream is = null; try { is = new FileInputStream("c:/myeclipse/DroolsProject/src/QuarterlyBonusRules.xls"); } catch (FileNotFoundException e) { e.printStackTrace(); } // Create compiler class instance SpreadsheetCompiler sc = new SpreadsheetCompiler(); // Compile the excel to generate the (.drl) file StringBuffer drl = new StringBuffer(sc.compile(is, InputType.XLS)); // Insert dialect value into drl file drl.insert(drl.indexOf("DROOLS") + 40, "dialect \"mvel\"" + "\n"); // Check the generated drl file System.out.println("Generate DRL file is showing below?: "); System.out.println(drl); // writing string into a drl file try { BufferedWriter out = new BufferedWriter(new FileWriter( "QuarterlyBonusRules.drl")); out.write(drl.toString()); out.close(); } catch (IOException e) { System.out.println("Exception "); } // Wait before using the drl file in the next section. try { Thread.sleep(100); } catch (InterruptedException e) { e.printStackTrace(); } kbuilder.add(ResourceFactory.newFileResource(new File( "QuarterlyBonusRules.drl")), ResourceType.DRL); if (kbuilder.hasErrors()) { System.out.println("kbuilder has errors"); System.out.println(kbuilder.getErrors().toString()); } // get the compiled packages (which are serializable) final Collection pkgs = kbuilder.getKnowledgePackages(); final KnowledgeBase kbase = KnowledgeBaseFactory.newKnowledgeBase(); kbase.addKnowledgePackages(pkgs); final StatefulKnowledgeSession ksession = kbase .newStatefulKnowledgeSession(); ksession.addEventListener(new DebugAgendaEventListener()); ksession.addEventListener(new DebugWorkingMemoryEventListener()); QuarterlyBonusRules qbr = new QuarterlyBonusRules(); qbr.setAttendancePercentage(new Double(0.75)); qbr.setMinorCollisionDays(0); qbr.setMajorCollisionDays(0); qbr.setViolationAssessed(false); ksession.insert(qbr); ksession.fireAllRules(); ksession.dispose(); System.out.println(qbr.getBonusAmount()); } } AFter executing the above program, here I am getting the error, and not able to rectify it SLF4J: Failed to load class "org.slf4j.impl.StaticLoggerBinder". SLF4J: Defaulting to no-operation (NOP) logger implementation SLF4J: See http://www.slf4j.org/codes.html#StaticLoggerBinder for further details. Warning: ?Cannot read name ranges for Excel_BuiltIn__FilterDatabase_1 - setting to empty Warning: ?Cell at D21 not present - adding a blank Generate DRL file is showing below?:? package DROOLS; //generated from Decision Table dialect "mvel" import com.dfs.dsa.rules.QuarterlyBonusRules; // rule values at B11, header at B6 rule "1" when qbr:QuarterlyBonusRules(attendancePercentage>=0.75) (minorCollisionDays>=0 && minorCollisionDays<=0); (majorCollisionDays>=0 && majorCollisionDays<=0); violationAssessed==false; then qbr.setBonusAmount(150); end // rule values at B12, header at B6 rule "2" when qbr:QuarterlyBonusRules(attendancePercentage>=0.56) (minorCollisionDays>=0 && minorCollisionDays<=90); (majorCollisionDays>=0 && majorCollisionDays<=90); violationAssessed==true; then qbr.setBonusAmount(0); end kbuilder has errors [9,21]: [ERR 102] Line 9:21 mismatched input '>=' in rule "1" [20,21]: [ERR 102] Line 20:21 mismatched input '>=' in rule "2" [0,0]: Parser returned a null Package ==>[ObjectInsertedEventImpl: getFactHandle()=[fact 0:1:2144330803:2144330803:1:DEFAULT:com.dfs.dsa.rules.QuarterlyBonusRules at 7fcfe433], getObject()=com.dfs.dsa.rules.QuarterlyBonusRules at 7fcfe433, getKnowledgeRuntime()=org.drools.impl.StatefulKnowledgeSessionImpl at 23efdc4, getPropagationContext()=PropagationContextImpl [activeActivations=0, dormantActivations=0, entryPoint=EntryPoint::DEFAULT, factHandle=[fact 0:1:2144330803:2144330803:1:DEFAULT:com.dfs.dsa.rules.QuarterlyBonusRules at 7fcfe433], leftTuple=null, originOffset=-1, propagationNumber=4, rule=null, type=0]] 11 Note: the number 11 is the value, it has printed, that I set to the bonus amount, but it should not print that value, it should pring 150. I am here attaching the spread sheet, where I have added all the rules in it. I appreciate you a lot for the help Thanks & Regards, Venkata. -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140728/972b2013/attachment-0001.html -------------- next part -------------- A non-text attachment was scrubbed... Name: QuarterlyBonusRules.xls Type: application/vnd.ms-excel Size: 10752 bytes Desc: not available Url : http://lists.jboss.org/pipermail/rules-users/attachments/20140728/972b2013/attachment-0001.xls From mjr4184 at gmail.com Mon Jul 28 11:31:06 2014 From: mjr4184 at gmail.com (mikerod) Date: Mon, 28 Jul 2014 08:31:06 -0700 (PDT) Subject: [rules-users] Conflict resolution strategy - before vs after Phreak impl Message-ID: <1406561466589-4030521.post@n3.nabble.com> In version 5.x of Drools I see that it offered configurable conflict resolver strategies. I also read a few different Drools documentation sources that discussed varieties of "complex" conflict resolution strategies. One source discussed a tiered implementation by the name of CompositeConflictResolver - which was @ http://legacy.drools.codehaus.org/Conflict+Resolution. We have been experimenting with uplifting from Drools v5.6.0.Final to a v6.x version and we noted a fairly significant performance degradation /(a)/. When digging into some rule logging, we found that the issue was that our rule load order was not behaving well in terms of conflict resolution. The "wrong" rule activations were chosen to go first on the agenda, and this was causing a lot of unnecessary/redundant "movement" within the Rete network. After reading through the documentation on conflict resolution strategies and noting that it was configurable in Drools v5.x, I started thinking more about the importance a conflict resolution strategy on performance. Digging deeper, I believe Drools v5.6.0.Final uses `org.drools.core.conflict.DepthConflictResolver` as the default resolver (which is not the CompositeConflictResolver mentioned above interestingly). In Drools v6.x (around v6.2.x I believe) with Phreak enabled, there is a `org.drools.core.conflict.PhreakConflictResolver` that is used as the default resolver. This raises a few questions: /1)/ With Phreak enabled, it looks like the conflict resolver is *not* configurable anymore. I believe this is the case due to these lines . Why was this configuration options removed? /2)/ The PhreakConflictResolver does not seem to be doing anything very sophisticated now. I gather that it respects salience first, then falls back to rule load order. I found this around these lines . Why was this implementation chosen? Is it discussed or documented anywhere? Was it determined that this performs better than anything else or that there is no significant difference either way? There are about 4 conflict resolver impls in the org.drools.core.conflict package. In Drools v5.6.x I saw there were 10-11 of them in the similarly purposed org.drools.conflict package. /3)/ (related to /(2)/) Why was the default conflict resolution strategy changed to PhreakConflictResolver from the DepthConflictResolver used in v5.6.x? I do not think they are the same based on the source code, however, I cannot say I fully understand all of the semantics of the `Activation#getActivationNumber` used in the DepthConflictResolver. I know that my perf issue /(a)/ noted above could be solved by using salience, etc. I was wanting to avoid using salience where possible as it leads to more fragile, less declarative systems. We were able to fix the perf issue, by simply changing the rule load order anyways. My question is not specifically asking how to deal with this perf issue. Instead I'm asking about Drools choice of conflict resolution strategy in v6, as I have listed in points /1-3/ above. In the blog post @ http://blog.athico.com/2013/11/rip-rete-time-to-get-phreaky.html, I think the sentence, /"A simple heuristic, based on the rule most likely to result in firings, is used to select the next rule for evaluation; this delays the evaluation and firing of the other rules."/ is the only thing I see on the topic of conflict resolution (at least I think it is). I understand the parts about unlinked and linked rules, however, when the agenda is populated by multiple activations of the same salience, that's when things get interesting from the point of view of the topic discussed here. I appreciate any feedback with regards to this. -- View this message in context: http://drools.46999.n3.nabble.com/Conflict-resolution-strategy-before-vs-after-Phreak-impl-tp4030521.html Sent from the Drools: User forum mailing list archive at Nabble.com. From mproctor at codehaus.org Mon Jul 28 12:11:56 2014 From: mproctor at codehaus.org (Mark Proctor) Date: Mon, 28 Jul 2014 17:11:56 +0100 Subject: [rules-users] Conflict resolution strategy - before vs after Phreak impl In-Reply-To: <1406561466589-4030521.post@n3.nabble.com> References: <1406561466589-4030521.post@n3.nabble.com> Message-ID: Conflict resolution strategies are ?magic? things, it means how a set of rules behave cannot be determined from reading the rules alone, and could potentially change if someone changes the backend component (possibly without you knowing). Our preference is to ensure any execution behaviour is encoded and visible in the rules themselves. Over time we?d rather create additional declarative ways to do this on the rules themselves, rather than change some magic backend component; such as the experimental declarative agenda we?ve added. CRS in 6x is different to 5x, it?s now choosing the order or rules to evaluate, where as 5x the CRS controls the order in which rules are fired. We need to be free to change these type of things, without worrying about user compatibility - so less we expose to end suers the better; and as mentioned I consider it an anti-pattern in ease of rule authoring and maintenance. The only reason why we haven?t removed all of the implementations is that there is a degree of 5x compatibility in the system still. Phreak is just depth + load order, so it?s not a big change, all it does is remove the degree of arbitrary behaviour you were relying on for performance. Depth in 5x meant rules with the same salience were executed in an arbitrary order, it seems this arbitrary order was not so arbitrary in your case and makes an impact on performance - but as it?s arbitrary the repeatability of this cannot be ensured, even across environments let alone versions. In 6x this is no longer arbitrary, which will allow people more predictability in their rule executions. Load order is also much easier for people to understand and deal with, and often avoids the need to use salience at all - it?s also how people?s brains tend to think. Rules higher up in the file, fire first. We recommend one ?agenda-group? per file, so that it?s easy to keep control of those orders. Salience can still over-ride this; but over time we have further ideas to completely remove the need for salience. This didn?t make much sense in 5x as load order was not preserved between kbase updates, so if you add rules later you lose the load order. In 6x we fixed this, so load order is always preserved between versions, an thus adding this enhancement makes sense. So the key takeaway is for future systems it should make them easier to author and with more predictable performance results. You can still run the rete engine if you want, it?s available through configuration. Although it would be better to start working with Phreak, so you can provide feedback to us, for future improvements. Mark On 28 Jul 2014, at 16:31, mikerod wrote: > In version 5.x of Drools I see that it offered configurable conflict resolver > strategies. I also read a few different Drools documentation sources that > discussed varieties of "complex" conflict resolution strategies. One source > discussed a tiered implementation by the name of CompositeConflictResolver - > which was @ http://legacy.drools.codehaus.org/Conflict+Resolution. > > We have been experimenting with uplifting from Drools v5.6.0.Final to a v6.x > version and we noted a fairly significant performance degradation /(a)/. > When digging into some rule logging, > we found that the issue was that our rule load order was not behaving well > in terms of conflict resolution. The "wrong" rule activations were chosen > to go first on the agenda, and this > was causing a lot of unnecessary/redundant "movement" within the Rete > network. > > After reading through the documentation on conflict resolution strategies > and noting that it was configurable in Drools v5.x, I started thinking more > about the importance a conflict resolution strategy on performance. Digging > deeper, I believe Drools v5.6.0.Final uses > `org.drools.core.conflict.DepthConflictResolver` as the default resolver > (which is not the CompositeConflictResolver mentioned above interestingly). > In Drools v6.x (around v6.2.x I believe) with Phreak enabled, there is a > `org.drools.core.conflict.PhreakConflictResolver` that is used as the > default resolver. > > This raises a few questions: > > /1)/ With Phreak enabled, it looks like the conflict resolver is *not* > configurable anymore. I believe this is the case due to these lines > > . Why was this configuration options removed? > > /2)/ The PhreakConflictResolver does not seem to be doing anything very > sophisticated now. I gather that it respects salience first, then falls > back to rule load order. I found this around these lines > > . Why was this implementation chosen? Is it discussed or documented > anywhere? Was it determined that this performs better than anything else or > that there is no significant difference either way? There are about 4 > conflict resolver impls in the org.drools.core.conflict package. In Drools > v5.6.x I saw there were 10-11 of them in the similarly purposed > org.drools.conflict package. > > /3)/ (related to /(2)/) Why was the default conflict resolution strategy > changed to PhreakConflictResolver from the DepthConflictResolver used in > v5.6.x? I do not think they are the same based on the source code, however, > I cannot say I fully understand all of the semantics of the > `Activation#getActivationNumber` used in the DepthConflictResolver. > > > I know that my perf issue /(a)/ noted above could be solved by using > salience, etc. > I was wanting to avoid using salience where possible as it > leads to more fragile, less declarative systems. We were able to fix the > perf issue, by simply changing the rule load order anyways. My question is > not specifically asking how to deal with this perf issue. Instead I'm > asking about Drools choice of conflict resolution strategy in v6, as I have > listed in points /1-3/ above. > > In the blog post @ > http://blog.athico.com/2013/11/rip-rete-time-to-get-phreaky.html, > I think the sentence, > /"A simple heuristic, based on the rule most likely to result in firings, is > used to select the next rule for evaluation; this delays the evaluation and > firing of the other rules."/ > is the only thing I see on the topic of conflict resolution (at least I > think it is). I understand the parts about unlinked and linked rules, > however, when the agenda is populated by multiple activations of the same > salience, that's when things get interesting from the point of view of the > topic discussed here. > > I appreciate any feedback with regards to this. > > > > > -- > View this message in context: http://drools.46999.n3.nabble.com/Conflict-resolution-strategy-before-vs-after-Phreak-impl-tp4030521.html > Sent from the Drools: User forum mailing list archive at Nabble.com. > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users From mjr4184 at gmail.com Mon Jul 28 12:31:50 2014 From: mjr4184 at gmail.com (mikerod) Date: Mon, 28 Jul 2014 09:31:50 -0700 (PDT) Subject: [rules-users] Conflict resolution strategy - before vs after Phreak impl In-Reply-To: References: <1406561466589-4030521.post@n3.nabble.com> Message-ID: <1406565110068-4030523.post@n3.nabble.com> Thanks Mark for that explanation! I'd say that certainly addresses the questions I had and I can understand the points you make. We do intend to move to the Phreak implementation still. I was just looking for some clarity on this topic as we dealt with things, which I now have. -- View this message in context: http://drools.46999.n3.nabble.com/Conflict-resolution-strategy-before-vs-after-Phreak-impl-tp4030521p4030523.html Sent from the Drools: User forum mailing list archive at Nabble.com. From borris at chaos.org.uk Mon Jul 28 14:31:03 2014 From: borris at chaos.org.uk (Borris) Date: Mon, 28 Jul 2014 19:31:03 +0100 Subject: [rules-users] Defeasible: NPE: with multiple @Defeasible In-Reply-To: <53D2EAA3.2000308@gmail.com> References: <53CEBE2B.4070903@chaos.org.uk> <1FE456CF-C308-4AE5-A014-EBAB4A9C23A2@codehaus.org> <53D02212.6040307@chaos.org.uk> <53D2EAA3.2000308@gmail.com> Message-ID: <53D696E7.8080902@chaos.org.uk> Wow, excellent Davide. I've been travelling and will give a go over the next day (or so). Non-trivial @defeasible and constants in queries really open up lots of things I've been wanting to try! Regards Borris On Saturday 26/07/2014 00:39, Davide Sottara wrote: > Fixed, in PR status. It was indeed another bug. > https://github.com/sotty/drools/commit/7941a0c8d7e66c6c7719c14ca58d798337d067d8 > > Thanks for reporting, we really appreciate the feedback > Davide > > On 07/23/2014 10:58 PM, Borris wrote: >> On 22/07/2014 22:44, Mark Proctor wrote: >>> Stack trace shows the error: >>> org.drools.core.beliefsystem.defeasible.DefeasibleBeliefSet.removeUndefeated(DefeasibleBeliefSet.java:295) >>> https://github.com/sotty/drools/blob/master/drools-core/src/main/java/org/drools/core/beliefsystem/defeasible/DefeasibleBeliefSet.java >>> >>> Maybe have a go fixing it yourself? And submit the fix with a unit test, as a pull request? >>> http://docs.jboss.org/drools/release/5.6.0.Final/droolsjbpm-introduction-docs/html/gettingstarted.html >>> >> I might well have a go, but there's a whole bunch of learning I need to >> do before I can submit my first candidate patch. So don't expect >> something too quickly. >> >> Borris >> >> _______________________________________________ >> rules-users mailing list >> rules-users at lists.jboss.org >> https://lists.jboss.org/mailman/listinfo/rules-users >> > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users From michael.anstis at gmail.com Mon Jul 28 16:02:04 2014 From: michael.anstis at gmail.com (Michael Anstis) Date: Mon, 28 Jul 2014 21:02:04 +0100 Subject: [rules-users] [drools-wb] how to move an asset to another package ? In-Reply-To: <1406133289398-4030461.post@n3.nabble.com> References: <1406024712969-4030422.post@n3.nabble.com> <1406101293.3353.1.camel@localhost.localdomain> <1406133289398-4030461.post@n3.nabble.com> Message-ID: I didn't see your other questions.. was the list that short? ;) As for "move" if you raise a GUVNOR JIRA it'll get addressed when we get time --- of course, we're more than happy to mentor you with a pull request too :) On 23 July 2014 17:34, jps wrote: > Hi, > > Thank you for the reply and the workaround. > > Will you add this kind of functionnality in the future ? We expect to > deploy > drools-wb to business users so they have a "business-user-friendly" > environment to author their rules. But you know - we can't ask our business > users to do a git clone + git push :) > > This leads me to other questions about git operations, but that's going to > be another post. > > > Regards, > --jps > > > > > -- > View this message in context: > http://drools.46999.n3.nabble.com/drools-wb-how-to-move-an-asset-to-another-package-tp4030422p4030461.html > Sent from the Drools: User forum mailing list archive at Nabble.com. > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140728/d2789afb/attachment.html From Darshana.R at azay.co.th Mon Jul 28 22:10:40 2014 From: Darshana.R at azay.co.th (Darshana Rajapaksha (Thailand)) Date: Tue, 29 Jul 2014 02:10:40 +0000 Subject: [rules-users] Deploying drools workbench on weblogic In-Reply-To: <81522501-73CA-46FA-BB69-1AE2EED3A81F@codehaus.org> References: , <81522501-73CA-46FA-BB69-1AE2EED3A81F@codehaus.org> Message-ID: Thanks Mark for your reply. Is there anybody who have tried this before? ________________________________ From: rules-users-bounces at lists.jboss.org [rules-users-bounces at lists.jboss.org] on behalf of Mark Proctor [mproctor at codehaus.org] Sent: Monday, July 28, 2014 8:40 PM To: Rules Users List Subject: Re: [rules-users] Deploying drools workbench on weblogic We haven?t done any testing on Weblogic yet, we in the process of going through this now. Any feedback or pointers would be appreciated. Mark On 28 Jul 2014, at 11:34, Darshana Rajapaksha (Thailand) > wrote: Hi, I'm trying to deploy kie-drools-wb-distribution-wars-6.0.1.Final-tomcat7.0.war on weblogic 12C and I'm getting different kind of exceptions. When one get fixed another exception. Anybody got success doing this. Below is the latest exception I'm getting when deploying. Any helpful idea is really appreciated. (NIOLuceneSetup.java:31) at org.drools.workbench.backend.server.ApplicationScopedProducer.(ApplicationScopedProducer.java:70) at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:57) at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45) at java.lang.reflect.Constructor.newInstance(Constructor.java:525) at org.jboss.weld.introspector.jlr.WeldConstructorImpl.newInstance(WeldConstructorImpl.java:206) at org.jboss.weld.injection.ConstructorInjectionPoint.newInstance(ConstructorInjectionPoint.java:117) at org.jboss.weld.bean.ManagedBean.createInstance(ManagedBean.java:336) at org.jboss.weld.bean.ManagedBean$ManagedBeanInjectionTarget.produce(ManagedBean.java:200) at org.jboss.weld.bean.ManagedBean.create(ManagedBean.java:292) at org.jboss.weld.context.AbstractContext.get(AbstractContext.java:103) at org.jboss.weld.manager.BeanManagerImpl.getReference(BeanManagerImpl.java:608) at org.jboss.weld.bean.AbstractReceiverBean.getReceiver(AbstractReceiverBean.java:77) at org.jboss.weld.bean.AbstractProducerBean$AbstractProducer.produce(AbstractProducerBean.java:317) at org.jboss.weld.bean.AbstractProducerBean.create(AbstractProducerBean.java:307) at org.jboss.weld.context.unbound.DependentContextImpl.get(DependentContextImpl.java:68) at org.jboss.weld.manager.BeanManagerImpl.getReference(BeanManagerImpl.java:608) at org.jboss.weld.manager.BeanManagerImpl.getReference(BeanManagerImpl.java:674) at org.jboss.weld.injection.FieldInjectionPoint.inject(FieldInjectionPoint.java:136) at org.jboss.weld.util.Beans.injectBoundFields(Beans.java:763) at org.jboss.weld.util.Beans.injectFieldsAndInitializers(Beans.java:772) at org.jboss.weld.bean.ManagedBean$ManagedBeanInjectionTarget$1$1.proceed(ManagedBean.java:161) at com.oracle.injection.provider.weld.WeldInjectionServicesAdapter.aroundInject(WeldInjectionServicesAdapter.java:103) at org.jboss.weld.injection.InjectionContextImpl.run(InjectionContextImpl.java:46) at org.jboss.weld.bean.ManagedBean$ManagedBeanInjectionTarget$1.work(ManagedBean.java:157) at org.jboss.weld.bean.ManagedBean$FixInjectionPoint.run(ManagedBean.java:131) at org.jboss.weld.bean.ManagedBean$ManagedBeanInjectionTarget.inject(ManagedBean.java:153) at org.jboss.weld.bean.ManagedBean.create(ManagedBean.java:293) at org.jboss.weld.context.AbstractContext.get(AbstractContext.java:103) at org.jboss.weld.bean.proxy.ContextBeanInstance.getInstance(ContextBeanInstance.java:90) at org.jboss.weld.bean.proxy.ProxyMethodHandler.invoke(ProxyMethodHandler.java:79) at org.uberfire.backend.server.repositories.RepositoryServiceImpl$Proxy$_$$_WeldClientProxy.getRepository(RepositoryServiceImpl$Proxy$_$$_WeldClientProxy.java) at org.drools.workbench.backend.server.AppSetup.assertPlayground(AppSetup.java:81) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:601) at org.jboss.weld.util.reflection.SecureReflections$13.work(SecureReflections.java:267) at org.jboss.weld.util.reflection.SecureReflectionAccess.run(SecureReflectionAccess.java:52) at org.jboss.weld.util.reflection.SecureReflectionAccess.runAsInvocation(SecureReflectionAccess.java:137) at org.jboss.weld.util.reflection.SecureReflections.invoke(SecureReflections.java:263) at org.jboss.weld.introspector.jlr.WeldMethodImpl.invoke(WeldMethodImpl.java:174) at org.jboss.weld.bean.AbstractClassBean.defaultPostConstruct(AbstractClassBean.java:402) at org.jboss.weld.bean.ManagedBean$ManagedBeanInjectionTarget.postConstruct(ManagedBean.java:174) at org.jboss.weld.bean.ManagedBean.create(ManagedBean.java:294) at org.jboss.weld.context.AbstractContext.get(AbstractContext.java:103) at org.jboss.weld.bean.proxy.ContextBeanInstance.getInstance(ContextBeanInstance.java:90) at org.jboss.weld.bean.proxy.ProxyMethodHandler.invoke(ProxyMethodHandler.java:79) at org.drools.workbench.backend.server.AppSetup$Proxy$_$$_WeldClientProxy.toString(AppSetup$Proxy$_$$_WeldClientProxy.java) at org.uberfire.commons.services.cdi.StartupBeanExtension.runPostConstruct(StartupBeanExtension.java:83) at org.uberfire.commons.services.cdi.StartupBeanExtension.afterDeploymentValidation(StartupBeanExtension.java:67) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:601) at org.jboss.weld.util.reflection.SecureReflections$13.work(SecureReflections.java:267) at org.jboss.weld.util.reflection.SecureReflectionAccess.run(SecureReflectionAccess.java:52) at org.jboss.weld.util.reflection.SecureReflectionAccess.runAsInvocation(SecureReflectionAccess.java:137) at org.jboss.weld.util.reflection.SecureReflections.invoke(SecureReflections.java:263) at org.jboss.weld.introspector.jlr.WeldMethodImpl.invokeOnInstance(WeldMethodImpl.java:170) at org.jboss.weld.introspector.ForwardingWeldMethod.invokeOnInstance(ForwardingWeldMethod.java:51) at org.jboss.weld.injection.MethodInjectionPoint.invokeOnInstanceWithSpecialValue(MethodInjectionPoint.java:154) at org.jboss.weld.event.ObserverMethodImpl.sendEvent(ObserverMethodImpl.java:245) at org.jboss.weld.event.ObserverMethodImpl.sendEvent(ObserverMethodImpl.java:233) at org.jboss.weld.event.ObserverMethodImpl.notify(ObserverMethodImpl.java:213) at org.jboss.weld.bootstrap.events.AbstractContainerEvent.fire(AbstractContainerEvent.java:75) at org.jboss.weld.bootstrap.events.AbstractDeploymentContainerEvent.fire(AbstractDeploymentContainerEvent.java:46) at org.jboss.weld.bootstrap.events.AfterDeploymentValidationImpl.fire(AfterDeploymentValidationImpl.java:31) at org.jboss.weld.bootstrap.WeldBootstrap.validateBeans(WeldBootstrap.java:382) at com.oracle.injection.provider.weld.WeldInjectionContainer.start(WeldInjectionContainer.java:106) at com.oracle.injection.integration.CDIAppDeploymentExtension.initCdi(CDIAppDeploymentExtension.java:70) at com.oracle.injection.integration.CDIAppDeploymentExtension.activate(CDIAppDeploymentExtension.java:47) at weblogic.application.internal.flow.AppDeploymentExtensionFlow.activate(AppDeploymentExtensionFlow.java:37) at weblogic.application.internal.BaseDeployment$2.next(BaseDeployment.java:729) at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:42) at weblogic.application.internal.BaseDeployment.activate(BaseDeployment.java:258) at weblogic.application.internal.SingleModuleDeployment.activate(SingleModuleDeployment.java:48) at weblogic.application.internal.DeploymentStateChecker.activate(DeploymentStateChecker.java:165) at weblogic.deploy.internal.targetserver.AppContainerInvoker.activate(AppContainerInvoker.java:80) at weblogic.deploy.internal.targetserver.operations.AbstractOperation.activate(AbstractOperation.java:586) at weblogic.deploy.internal.targetserver.operations.ActivateOperation.activateDeployment(ActivateOperation.java:148) at weblogic.deploy.internal.targetserver.operations.ActivateOperation.doCommit(ActivateOperation.java:114) at weblogic.deploy.internal.targetserver.operations.AbstractOperation.commit(AbstractOperation.java:339) at weblogic.deploy.internal.targetserver.DeploymentManager.handleDeploymentCommit(DeploymentManager.java:846) at weblogic.deploy.internal.targetserver.DeploymentManager.activateDeploymentList(DeploymentManager.java:1275) at weblogic.deploy.internal.targetserver.DeploymentManager.handleCommit(DeploymentManager.java:442) at weblogic.deploy.internal.targetserver.DeploymentServiceDispatcher.commit(DeploymentServiceDispatcher.java:176) at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer.doCommitCallback(DeploymentReceiverCallbackDeliverer.java:195) at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer.access$100(DeploymentReceiverCallbackDeliverer.java:13) at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer$2.run(DeploymentReceiverCallbackDeliverer.java:68) at weblogic.work.SelfTuningWorkManagerImpl$WorkAdapterImpl.run(SelfTuningWorkManagerImpl.java:550) at weblogic.work.ExecuteThread.execute(ExecuteThread.java:295) at weblogic.work.ExecuteThread.run(ExecuteThread.java:254) Caused By: java.lang.ClassNotFoundException: org.apache.lucene.store.NIOFSDirectory at java.net.URLClassLoader$1.run(URLClassLoader.java:366) at java.net.URLClassLoader$1.run(URLClassLoader.java:355) at java.security.AccessController.doPrivileged(Native Method) at java.net.URLClassLoader.findClass(URLClassLoader.java:354) at java.lang.ClassLoader.loadClass(ClassLoader.java:423) at java.lang.ClassLoader.loadClass(ClassLoader.java:356) at org.uberfire.metadata.backend.lucene.setups.NIOLuceneSetup.getDirectory(NIOLuceneSetup.java:40) at org.uberfire.metadata.backend.lucene.setups.NIOLuceneSetup.(NIOLuceneSetup.java:31) at org.drools.workbench.backend.server.ApplicationScopedProducer.(ApplicationScopedProducer.java:70) at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:57) at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45) at java.lang.reflect.Constructor.newInstance(Constructor.java:525) at org.jboss.weld.introspector.jlr.WeldConstructorImpl.newInstance(WeldConstructorImpl.java:206) at org.jboss.weld.injection.ConstructorInjectionPoint.newInstance(ConstructorInjectionPoint.java:117) at org.jboss.weld.bean.ManagedBean.createInstance(ManagedBean.java:336) at org.jboss.weld.bean.ManagedBean$ManagedBeanInjectionTarget.produce(ManagedBean.java:200) at org.jboss.weld.bean.ManagedBean.create(ManagedBean.java:292) at org.jboss.weld.context.AbstractContext.get(AbstractContext.java:103) at org.jboss.weld.manager.BeanManagerImpl.getReference(BeanManagerImpl.java:608) at org.jboss.weld.bean.AbstractReceiverBean.getReceiver(AbstractReceiverBean.java:77) at org.jboss.weld.bean.AbstractProducerBean$AbstractProducer.produce(AbstractProducerBean.java:317) at org.jboss.weld.bean.AbstractProducerBean.create(AbstractProducerBean.java:307) at org.jboss.weld.context.unbound.DependentContextImpl.get(DependentContextImpl.java:68) at org.jboss.weld.manager.BeanManagerImpl.getReference(BeanManagerImpl.java:608) at org.jboss.weld.manager.BeanManagerImpl.getReference(BeanManagerImpl.java:674) at org.jboss.weld.injection.FieldInjectionPoint.inject(FieldInjectionPoint.java:136) at org.jboss.weld.util.Beans.injectBoundFields(Beans.java:763) at org.jboss.weld.util.Beans.injectFieldsAndInitializers(Beans.java:772) at org.jboss.weld.bean.ManagedBean$ManagedBeanInjectionTarget$1$1.proceed(ManagedBean.java:161) at com.oracle.injection.provider.weld.WeldInjectionServicesAdapter.aroundInject(WeldInjectionServicesAdapter.java:103) at org.jboss.weld.injection.InjectionContextImpl.run(InjectionContextImpl.java:46) at org.jboss.weld.bean.ManagedBean$ManagedBeanInjectionTarget$1.work(ManagedBean.java:157) at org.jboss.weld.bean.ManagedBean$FixInjectionPoint.run(ManagedBean.java:131) at org.jboss.weld.bean.ManagedBean$ManagedBeanInjectionTarget.inject(ManagedBean.java:153) at org.jboss.weld.bean.ManagedBean.create(ManagedBean.java:293) at org.jboss.weld.context.AbstractContext.get(AbstractContext.java:103) at org.jboss.weld.bean.proxy.ContextBeanInstance.getInstance(ContextBeanInstance.java:90) at org.jboss.weld.bean.proxy.ProxyMethodHandler.invoke(ProxyMethodHandler.java:79) at org.uberfire.backend.server.repositories.RepositoryServiceImpl$Proxy$_$$_WeldClientProxy.getRepository(RepositoryServiceImpl$Proxy$_$$_WeldClientProxy.java) at org.drools.workbench.backend.server.AppSetup.assertPlayground(AppSetup.java:81) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:601) at org.jboss.weld.util.reflection.SecureReflections$13.work(SecureReflections.java:267) at org.jboss.weld.util.reflection.SecureReflectionAccess.run(SecureReflectionAccess.java:52) at org.jboss.weld.util.reflection.SecureReflectionAccess.runAsInvocation(SecureReflectionAccess.java:137) at org.jboss.weld.util.reflection.SecureReflections.invoke(SecureReflections.java:263) at org.jboss.weld.introspector.jlr.WeldMethodImpl.invoke(WeldMethodImpl.java:174) at org.jboss.weld.bean.AbstractClassBean.defaultPostConstruct(AbstractClassBean.java:402) at org.jboss.weld.bean.ManagedBean$ManagedBeanInjectionTarget.postConstruct(ManagedBean.java:174) at org.jboss.weld.bean.ManagedBean.create(ManagedBean.java:294) at org.jboss.weld.context.AbstractContext.get(AbstractContext.java:103) at org.jboss.weld.bean.proxy.ContextBeanInstance.getInstance(ContextBeanInstance.java:90) at org.jboss.weld.bean.proxy.ProxyMethodHandler.invoke(ProxyMethodHandler.java:79) at org.drools.workbench.backend.server.AppSetup$Proxy$_$$_WeldClientProxy.toString(AppSetup$Proxy$_$$_WeldClientProxy.java) at org.uberfire.commons.services.cdi.StartupBeanExtension.runPostConstruct(StartupBeanExtension.java:83) at org.uberfire.commons.services.cdi.StartupBeanExtension.afterDeploymentValidation(StartupBeanExtension.java:67) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:601) at org.jboss.weld.util.reflection.SecureReflections$13.work(SecureReflections.java:267) at org.jboss.weld.util.reflection.SecureReflectionAccess.run(SecureReflectionAccess.java:52) at org.jboss.weld.util.reflection.SecureReflectionAccess.runAsInvocation(SecureReflectionAccess.java:137) at org.jboss.weld.util.reflection.SecureReflections.invoke(SecureReflections.java:263) at org.jboss.weld.introspector.jlr.WeldMethodImpl.invokeOnInstance(WeldMethodImpl.java:170) at org.jboss.weld.introspector.ForwardingWeldMethod.invokeOnInstance(ForwardingWeldMethod.java:51) at org.jboss.weld.injection.MethodInjectionPoint.invokeOnInstanceWithSpecialValue(MethodInjectionPoint.java:154) at org.jboss.weld.event.ObserverMethodImpl.sendEvent(ObserverMethodImpl.java:245) at org.jboss.weld.event.ObserverMethodImpl.sendEvent(ObserverMethodImpl.java:233) at org.jboss.weld.event.ObserverMethodImpl.notify(ObserverMethodImpl.java:213) at org.jboss.weld.bootstrap.events.AbstractContainerEvent.fire(AbstractContainerEvent.java:75) at org.jboss.weld.bootstrap.events.AbstractDeploymentContainerEvent.fire(AbstractDeploymentContainerEvent.java:46) at org.jboss.weld.bootstrap.events.AfterDeploymentValidationImpl.fire(AfterDeploymentValidationImpl.java:31) at org.jboss.weld.bootstrap.WeldBootstrap.validateBeans(WeldBootstrap.java:382) at com.oracle.injection.provider.weld.WeldInjectionContainer.start(WeldInjectionContainer.java:106) at com.oracle.injection.integration.CDIAppDeploymentExtension.initCdi(CDIAppDeploymentExtension.java:70) at com.oracle.injection.integration.CDIAppDeploymentExtension.activate(CDIAppDeploymentExtension.java:47) at weblogic.application.internal.flow.AppDeploymentExtensionFlow.activate(AppDeploymentExtensionFlow.java:37) at weblogic.application.internal.BaseDeployment$2.next(BaseDeployment.java:729) at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:42) at weblogic.application.internal.BaseDeployment.activate(BaseDeployment.java:258) at weblogic.application.internal.SingleModuleDeployment.activate(SingleModuleDeployment.java:48) at weblogic.application.internal.DeploymentStateChecker.activate(DeploymentStateChecker.java:165) at weblogic.deploy.internal.targetserver.AppContainerInvoker.activate(AppContainerInvoker.java:80) at weblogic.deploy.internal.targetserver.operations.AbstractOperation.activate(AbstractOperation.java:586) at weblogic.deploy.internal.targetserver.operations.ActivateOperation.activateDeployment(ActivateOperation.java:148) at weblogic.deploy.internal.targetserver.operations.ActivateOperation.doCommit(ActivateOperation.java:114) at weblogic.deploy.internal.targetserver.operations.AbstractOperation.commit(AbstractOperation.java:339) at weblogic.deploy.internal.targetserver.DeploymentManager.handleDeploymentCommit(DeploymentManager.java:846) at weblogic.deploy.internal.targetserver.DeploymentManager.activateDeploymentList(DeploymentManager.java:1275) at weblogic.deploy.internal.targetserver.DeploymentManager.handleCommit(DeploymentManager.java:442) at weblogic.deploy.internal.targetserver.DeploymentServiceDispatcher.commit(DeploymentServiceDispatcher.java:176) at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer.doCommitCallback(DeploymentReceiverCallbackDeliverer.java:195) at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer.access$100(DeploymentReceiverCallbackDeliverer.java:13) at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer$2.run(DeploymentReceiverCallbackDeliverer.java:68) at weblogic.work.SelfTuningWorkManagerImpl$WorkAdapterImpl.run(SelfTuningWorkManagerImpl.java:550) at weblogic.work.ExecuteThread.execute(ExecuteThread.java:295) at weblogic.work.ExecuteThread.run(ExecuteThread.java:254) > https://lists.jboss.org/mailman/listinfo/rules-users The e-mail message you have received and any files transmitted with it are intended solely for the addresses(s) and may be legally privileged and/or confidential. If you have received this e-mail message in error, please delete it and all copies of it from your system including all hard copies thereof. Any unauthorized use or disclosure may be unlawful. Any confidentiality or privilege is not waived or lost because this message and its contents have been sent to you by mistake. Allianz Ayudhya Assurance Pcl. or its affiliates accept no responsibility either jointly or severally for any loss or damage for use of this e-mail. -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140729/ae55d66a/attachment-0001.html From jps at jps.ch Tue Jul 29 03:03:09 2014 From: jps at jps.ch (jps) Date: Tue, 29 Jul 2014 00:03:09 -0700 (PDT) Subject: [rules-users] [drools-wb] how to move an asset to another package ? In-Reply-To: References: <1406024712969-4030422.post@n3.nabble.com> <1406101293.3353.1.camel@localhost.localdomain> <1406133289398-4030461.post@n3.nabble.com> Message-ID: <1406617389482-4030528.post@n3.nabble.com> Related Jira : https://issues.jboss.org/browse/GUVNOR-2111 -- View this message in context: http://drools.46999.n3.nabble.com/drools-wb-how-to-move-an-asset-to-another-package-tp4030422p4030528.html Sent from the Drools: User forum mailing list archive at Nabble.com. From federico.bertola88 at gmail.com Tue Jul 29 10:14:35 2014 From: federico.bertola88 at gmail.com (Federico Bertola) Date: Tue, 29 Jul 2014 16:14:35 +0200 Subject: [rules-users] Serialization issue. In-Reply-To: <1406617389482-4030528.post@n3.nabble.com> References: <1406024712969-4030422.post@n3.nabble.com> <1406101293.3353.1.camel@localhost.localdomain> <1406133289398-4030461.post@n3.nabble.com> <1406617389482-4030528.post@n3.nabble.com> Message-ID: <53D7AC4B.3090207@gmail.com> Dear all, Some time ago I've submitted a pull request (#353) fixing a situation where a rule with large text prevent the serialization of the knowledge package. This is now the only thing that prevent us form using the original distribution. If there's nothing wrong or risky in it, it is possible for you apply the fix so we can use the latest snapshot? Thank you very much for your patience :) Regards, Federico. From Vance.A.Arocho at uscis.dhs.gov Tue Jul 29 12:31:27 2014 From: Vance.A.Arocho at uscis.dhs.gov (Arocho, Vance A (CTR)) Date: Tue, 29 Jul 2014 16:31:27 +0000 Subject: [rules-users] Need to create condition based on current date and time, start date and time, and duration Message-ID: <68D87985A8661740B4A84D9A2D0992680BC8C7@D2ASEPREA002> I'm using Drools 5.4, and am developing an Excel spreadsheet containing a decision table that requires another condition based on * The current date and time specified as an attribute on a Java object * The start date and duration of an event that are both specified within the spreadsheet (duration should be specified in hours) Is there a way to do this? Vance Arocho (CTR) Java Developer - TAP III Contract Office of Information Technology U.S. Citizenship and Immigration Services (USCIS), Department of Homeland Security (DHS) Vance.A.Arocho at uscis.dhs.gov Vance.Arocho at agilex.com 202.649.2283 (office) 703.201.7398 (mobile) -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140729/4cb1d777/attachment.html From Vance.A.Arocho at uscis.dhs.gov Tue Jul 29 14:08:29 2014 From: Vance.A.Arocho at uscis.dhs.gov (Arocho, Vance A (CTR)) Date: Tue, 29 Jul 2014 18:08:29 +0000 Subject: [rules-users] FW: Need to create condition based on current date and time, start date and time, and duration Message-ID: <68D87985A8661740B4A84D9A2D0992680BC9A8@D2ASEPREA002> To be a little clearer, the current date and time needs to be within the time interval specified by the start date and time and the 'start date and time + duration', something like start-datetime <= current-datetime <= start-datetime + duration But I'm not sure how to express the above properly. Can this be done with just one condition, or will I need two conditions? From: Arocho, Vance A (CTR) Sent: Tuesday, July 29, 2014 12:31 PM To: 'rules-users at lists.jboss.org' Subject: Need to create condition based on current date and time, start date and time, and duration I'm using Drools 5.4, and am developing an Excel spreadsheet containing a decision table that requires another condition based on * The current date and time specified as an attribute on a Java object * The start date and duration of an event that are both specified within the spreadsheet (duration should be specified in hours) Is there a way to do this? -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140729/7675fba6/attachment.html From federico.bertola88 at gmail.com Wed Jul 30 12:28:57 2014 From: federico.bertola88 at gmail.com (Federico Bertola) Date: Wed, 30 Jul 2014 18:28:57 +0200 Subject: [rules-users] StackOverflow when serializing KieBase In-Reply-To: <68D87985A8661740B4A84D9A2D0992680BC9A8@D2ASEPREA002> References: <68D87985A8661740B4A84D9A2D0992680BC9A8@D2ASEPREA002> Message-ID: <53D91D49.7010309@gmail.com> Hi all, when I try to serialize a rather large KieBase I constantly get the aforementioned error. After a bit of tracking I see that the error seems to appear when the KnowledgeBase try to serialize the Rete object. I belive this is not an infinite loop because it seems that the graph is quite deep and the serializer recursively calls writeExternal in a (sort of) depth-first fashion. Increasing the stack size didn't really help, so I'm asking if there's a better way or if I should give up. Thanks :) Federico. From mproctor at codehaus.org Wed Jul 30 19:25:55 2014 From: mproctor at codehaus.org (Mark Proctor) Date: Thu, 31 Jul 2014 00:25:55 +0100 Subject: [rules-users] StackOverflow when serializing KieBase In-Reply-To: <53D91D49.7010309@gmail.com> References: <68D87985A8661740B4A84D9A2D0992680BC9A8@D2ASEPREA002> <53D91D49.7010309@gmail.com> Message-ID: <2DB61D4A-D1E5-45DA-A8E3-E33E93ED09A4@codehaus.org> It should work, there should not be too much recursion. I?d suggest digging deeper to see if you can point us to the references that are suspect. Mark On 30 Jul 2014, at 17:28, Federico Bertola wrote: > Hi all, > when I try to serialize a rather large KieBase I constantly get the > aforementioned error. After a bit of tracking I see that the error seems > to appear when the KnowledgeBase try to serialize the Rete object. > I belive this is not an infinite loop because it seems that the graph is > quite deep and the serializer recursively calls writeExternal in a (sort > of) depth-first fashion. > > Increasing the stack size didn't really help, so I'm asking if there's a > better way or if I should give up. > > Thanks :) > > Federico. > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users From dzeigler at gmail.com Wed Jul 30 21:40:53 2014 From: dzeigler at gmail.com (David Zeigler) Date: Wed, 30 Jul 2014 21:40:53 -0400 Subject: [rules-users] NPE in LeftTupleSetsImpl.removeUpdate Message-ID: Hi, I'm using drools 6.0.1.Final. I received a NPE in the org.drools.core.common.LeftTupleSetsImpl.removeUpdate() method on line 172, which corresponds to this line for 6.0.1.Final: previous.setStagedNext( next ); I see 2 commits in 6.1.0 to address NPEs in this class but I'm not sure if either of those cover this particular NPE. I'm unable to reproduce this issue with my code after the first occurrence. Does anyone know if this has been fixed in 6.1.0? Please let me know if I can provide additional info or if I should open a defect in Jira. Thanks, David Here is the stack trace: java.lang.NullPointerException at org.drools.core.common.LeftTupleSetsImpl.removeUpdate( LeftTupleSetsImpl.java:172) at org.drools.core.common.LeftTupleSetsImpl.addDelete( LeftTupleSetsImpl.java:84) at org.drools.core.common.SynchronizedLeftTupleSets.addDelete( SynchronizedLeftTupleSets.java:20) at org.drools.core.reteoo.LeftInputAdapterNode.doDeleteSegmentMemory( LeftInputAdapterNode.java:339) at org.drools.core.reteoo.LeftInputAdapterNode.doDeleteObject( LeftInputAdapterNode.java:301) at org.drools.core.reteoo.LeftInputAdapterNode.retractLeftTuple( LeftInputAdapterNode.java:417) at org.drools.core.reteoo.ObjectTypeNode.doRetractObject( ObjectTypeNode.java:352) at org.drools.core.reteoo.ObjectTypeNode.retractObject(ObjectTypeNode.java:335) at org.drools.core.reteoo.EntryPointNode.retractObject(EntryPointNode.java:395) at org.drools.core.common.NamedEntryPoint.delete(NamedEntryPoint.java:605) at org.drools.core.common.AbstractWorkingMemory.delete( AbstractWorkingMemory.java:1184) at org.drools.core.common.AbstractWorkingMemory.delete( AbstractWorkingMemory.java:1176) at org.drools.core.impl.StatefulKnowledgeSessionImpl.delete( StatefulKnowledgeSessionImpl.java:316) -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140730/29179019/attachment.html From dsotty at gmail.com Wed Jul 30 21:48:57 2014 From: dsotty at gmail.com (Davide Sottara) Date: Thu, 31 Jul 2014 03:48:57 +0200 Subject: [rules-users] NPE in LeftTupleSetsImpl.removeUpdate In-Reply-To: References: Message-ID: <53D9A089.2000008@gmail.com> It has almost certainly been fixed in 6.1 Davide On 07/31/2014 03:40 AM, David Zeigler wrote: > Hi, > I'm using drools 6.0.1.Final. I received a NPE in > the org.drools.core.common.LeftTupleSetsImpl.removeUpdate() method on > line 172, which corresponds to this line for 6.0.1.Final: > previous.setStagedNext( next ); > > I see 2 commits in 6.1.0 to address NPEs in this class but I'm not > sure if either of those cover this particular NPE. I'm unable > to reproduce this issue with my code after the first occurrence. Does > anyone know if this has been fixed in 6.1.0? Please let me know if I > can provide additional info or if I should open a defect in Jira. > > Thanks, > David > > Here is the stack trace: > java.lang.NullPointerException > at > org.drools.core.common.LeftTupleSetsImpl.removeUpdate(LeftTupleSetsImpl.java:172) > at > org.drools.core.common.LeftTupleSetsImpl.addDelete(LeftTupleSetsImpl.java:84) > at > org.drools.core.common.SynchronizedLeftTupleSets.addDelete(SynchronizedLeftTupleSets.java:20) > at > org.drools.core.reteoo.LeftInputAdapterNode.doDeleteSegmentMemory(LeftInputAdapterNode.java:339) > at > org.drools.core.reteoo.LeftInputAdapterNode.doDeleteObject(LeftInputAdapterNode.java:301) > at > org.drools.core.reteoo.LeftInputAdapterNode.retractLeftTuple(LeftInputAdapterNode.java:417) > at > org.drools.core.reteoo.ObjectTypeNode.doRetractObject(ObjectTypeNode.java:352) > at > org.drools.core.reteoo.ObjectTypeNode.retractObject(ObjectTypeNode.java:335) > at > org.drools.core.reteoo.EntryPointNode.retractObject(EntryPointNode.java:395) > at > org.drools.core.common.NamedEntryPoint.delete(NamedEntryPoint.java:605) > at > org.drools.core.common.AbstractWorkingMemory.delete(AbstractWorkingMemory.java:1184) > at > org.drools.core.common.AbstractWorkingMemory.delete(AbstractWorkingMemory.java:1176) > at > org.drools.core.impl.StatefulKnowledgeSessionImpl.delete(StatefulKnowledgeSessionImpl.java:316) > > > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140731/9b4ef329/attachment.html From mproctor at codehaus.org Wed Jul 30 22:39:42 2014 From: mproctor at codehaus.org (Mark Proctor) Date: Thu, 31 Jul 2014 03:39:42 +0100 Subject: [rules-users] NPE in LeftTupleSetsImpl.removeUpdate In-Reply-To: <53D9A089.2000008@gmail.com> References: <53D9A089.2000008@gmail.com> Message-ID: <8B8BB6B0-2F43-4809-ADB0-53BC178D4035@codehaus.org> try 6.1.x, this is being released as we speak: http://downloads.jboss.org/drools/release/snapshot/6.1.x/ Mark On 31 Jul 2014, at 02:48, Davide Sottara wrote: > It has almost certainly been fixed in 6.1 > Davide > > On 07/31/2014 03:40 AM, David Zeigler wrote: >> Hi, >> I'm using drools 6.0.1.Final. I received a NPE in the org.drools.core.common.LeftTupleSetsImpl.removeUpdate() method on line 172, which corresponds to this line for 6.0.1.Final: >> previous.setStagedNext( next ); >> >> I see 2 commits in 6.1.0 to address NPEs in this class but I'm not sure if either of those cover this particular NPE. I'm unable to reproduce this issue with my code after the first occurrence. Does anyone know if this has been fixed in 6.1.0? Please let me know if I can provide additional info or if I should open a defect in Jira. >> >> Thanks, >> David >> >> Here is the stack trace: >> java.lang.NullPointerException >> at >> org.drools.core.common.LeftTupleSetsImpl.removeUpdate(LeftTupleSetsImpl.java:172) >> at >> org.drools.core.common.LeftTupleSetsImpl.addDelete(LeftTupleSetsImpl.java:84) >> at >> org.drools.core.common.SynchronizedLeftTupleSets.addDelete(SynchronizedLeftTupleSets.java:20) >> at >> org.drools.core.reteoo.LeftInputAdapterNode.doDeleteSegmentMemory(LeftInputAdapterNode.java:339) >> at >> org.drools.core.reteoo.LeftInputAdapterNode.doDeleteObject(LeftInputAdapterNode.java:301) >> at >> org.drools.core.reteoo.LeftInputAdapterNode.retractLeftTuple(LeftInputAdapterNode.java:417) >> at >> org.drools.core.reteoo.ObjectTypeNode.doRetractObject(ObjectTypeNode.java:352) >> at >> org.drools.core.reteoo.ObjectTypeNode.retractObject(ObjectTypeNode.java:335) >> at >> org.drools.core.reteoo.EntryPointNode.retractObject(EntryPointNode.java:395) >> at >> org.drools.core.common.NamedEntryPoint.delete(NamedEntryPoint.java:605) >> at >> org.drools.core.common.AbstractWorkingMemory.delete(AbstractWorkingMemory.java:1184) >> at >> org.drools.core.common.AbstractWorkingMemory.delete(AbstractWorkingMemory.java:1176) >> at >> org.drools.core.impl.StatefulKnowledgeSessionImpl.delete(StatefulKnowledgeSessionImpl.java:316) >> >> >> _______________________________________________ >> rules-users mailing list >> rules-users at lists.jboss.org >> https://lists.jboss.org/mailman/listinfo/rules-users > > _______________________________________________ > rules-users mailing list > rules-users at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140731/b70321e2/attachment-0001.html From Vance.A.Arocho at uscis.dhs.gov Thu Jul 31 11:07:56 2014 From: Vance.A.Arocho at uscis.dhs.gov (Arocho, Vance A (CTR)) Date: Thu, 31 Jul 2014 15:07:56 +0000 Subject: [rules-users] Using an Excel rule file Message-ID: <68D87985A8661740B4A84D9A2D0992680BCF98@D2ASEPREA002> I'm using an Excel file containing a decision table, and have code that generates the rules file from this Excel file. I only want to have this happen when the Excel file is actually changed. Is there a way to do this? -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/rules-users/attachments/20140731/d6e12139/attachment.html