Re: [rules-users] Guvnor 5.2 CR1 under IE8
On 2011/6/20 22:24, Vincent LEGENDRE wrote: Hi all I was using firefox for Guvnor, every thing was well. But here, users use IE 8, and under IE8, Guvnor displays some strange list of icons in place of some other icons : - validate rule dialog : in place of the check (or error icon) : a big image containing all icons - new rule dialog : category icons are replaced by the same big image - history part of a rule : one more time the same big image Does anyone has the problem ? Does anyone uses IE :) ? I suspect something like GWT using a big image as a cache, and some javascript to display only a small part of it, and this javascript is not compatible with IE. Make sense ? If yes, is there a workaround ? ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users Hi can you create a jira with some screen shots please? I dont have an environment that can run IE8 at the moment, but I ll look into this problem (and other similar problems) as soon as I have the env ready. Thanks, Jervis ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users
[rules-users] NullPointerException in RightTupleIndexHashTable.remove()
Hi all! I encountered that null pointer exceptions occur when retracting an object from the working memory. Sometimes the problem occurs sooner sometimes later but it certainly happens. I think it also depends on the workload on the machine. Sometimes the NPE is thrown in 'LeftTupleIndexHashTable' but mainly in 'RightTupleIndexHashTable'. After the exception is thrown, the object to retract is still in the working memory. When I remove the line 'retract($obj)' in my rule, I don't get an exception. The problem occurs mainly in this rule, but also in other rules: rule remove a cross talk agenda-group evaluation activation-group ag-crossTalk lock-on-active true salience 40 when $ctf : CrossTalkFact($persID : uniquePersonID, $ctfTimestamp : timestamp) $pers : AnalysisCue(cueType == AnalysisCue.ACTION_STOP_TALKING, uniquePersonID == $persID, timestamp $ctfTimestamp) from entry-point LowLevelCueStream then retract($ctf); //the suspicious line //... do some other things end My configuration: drools.dialect.java.compiler = JANINO EventProcessingOption = STREAM I was able to reproduce the problem with following versions: 5.1.1 5.2.0.M1 5.2.0.CR1 Stack trace from the version: 5.2.0.CR1 org.drools.runtime.rule.ConsequenceException: rule: remove a cross talk at org.drools.runtime.rule.impl.DefaultConsequenceExceptionHandler.handleException(DefaultConsequenceExceptionHandler.java:39) at org.drools.common.DefaultAgenda.fireActivation(DefaultAgenda.java:915) at org.drools.common.DefaultAgenda.fireNextItem(DefaultAgenda.java:844) at org.drools.common.DefaultAgenda.fireAllRules(DefaultAgenda.java:1055) at org.drools.common.AbstractWorkingMemory.fireAllRules(AbstractWorkingMemory.java:733) at org.drools.common.AbstractWorkingMemory.fireAllRules(AbstractWorkingMemory.java:699) at org.drools.impl.StatefulKnowledgeSessionImpl.fireAllRules(StatefulKnowledgeSessionImpl.java:218) ... Caused by: java.lang.NullPointerException at org.drools.core.util.RightTupleIndexHashTable.remove(RightTupleIndexHashTable.java:351) at org.drools.reteoo.NotNode.retractRightTuple(NotNode.java:178) at org.drools.reteoo.ObjectTypeNode.retractObject(ObjectTypeNode.java:235) at org.drools.reteoo.EntryPointNode.retractObject(EntryPointNode.java:229) at org.drools.common.NamedEntryPoint.retract(NamedEntryPoint.java:529) at org.drools.base.DefaultKnowledgeHelper.retract(DefaultKnowledgeHelper.java:226) at eu.ta2.orchestration.engine.cueLifter.Rule_remove_a_cross_talk_0.defaultConsequence(Unknown Source) at eu.ta2.orchestration.engine.cueLifter.Rule_remove_a_cross_talk_0DefaultConsequenceInvoker.evaluate(Unknown Source) at org.drools.common.DefaultAgenda.fireActivation(DefaultAgenda.java:905) ... 31 more Sometimes the exception occurs in the LeftTupleIndexHashTable: org.drools.runtime.rule.ConsequenceException: rule: remove a cross talk at org.drools.runtime.rule.impl.DefaultConsequenceExceptionHandler.handleException(DefaultConsequenceExceptionHandler.java:39) at org.drools.common.DefaultAgenda.fireActivation(DefaultAgenda.java:915) at org.drools.common.DefaultAgenda.fireNextItem(DefaultAgenda.java:844) at org.drools.common.DefaultAgenda.fireAllRules(DefaultAgenda.java:1055) at org.drools.common.AbstractWorkingMemory.fireAllRules(AbstractWorkingMemory.java:733) at org.drools.common.AbstractWorkingMemory.fireAllRules(AbstractWorkingMemory.java:699) at org.drools.impl.StatefulKnowledgeSessionImpl.fireAllRules(StatefulKnowledgeSessionImpl.java:218) ... Caused by: java.lang.NullPointerException at org.drools.core.util.LeftTupleIndexHashTable.remove(LeftTupleIndexHashTable.java:275) at org.drools.reteoo.NotNode.retractLeftTuple(NotNode.java:231) at org.drools.reteoo.SingleLeftTupleSinkAdapter.doPropagateRetractLeftTuple(SingleLeftTupleSinkAdapter.java:212) at org.drools.reteoo.SingleLeftTupleSinkAdapter.propagateRetractLeftTuple(SingleLeftTupleSinkAdapter.java:86) at org.drools.reteoo.JoinNode.retractLeftTuple(JoinNode.java:210) at org.drools.reteoo.SingleLeftTupleSinkAdapter.doPropagateRetractLeftTuple(SingleLeftTupleSinkAdapter.java:212) at org.drools.reteoo.SingleLeftTupleSinkAdapter.propagateRetractRightTuple(SingleLeftTupleSinkAdapter.java:119) at org.drools.reteoo.JoinNode.retractRightTuple(JoinNode.java:192) at org.drools.reteoo.ObjectTypeNode.retractObject(ObjectTypeNode.java:235) at
Re: [rules-users] Guvnor guided editor problem - add more options
I am also having the same problem and wousl also appreciate any advice -- Best Regards, Marros -- View this message in context: http://drools.46999.n3.nabble.com/Guvnor-guided-editor-problem-add-more-options-tp3087495p3089865.html Sent from the Drools: User forum mailing list archive at Nabble.com. ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users
Re: [rules-users] Guvnor guided editor problem - add more options
I don't have the book to which you refer and therefore don't know exactly what icon is missing. If Guvnor 5.2 (and I assume 5.1) you add more options to a rule by clicking on the (show options...) text at the bottom of a rule (assuming you're meaning in the guided rule editor). What version of Guvnor are you using? On 21 June 2011 10:00, marros martin.ros...@vships.com wrote: I am also having the same problem and wousl also appreciate any advice -- Best Regards, Marros -- View this message in context: http://drools.46999.n3.nabble.com/Guvnor-guided-editor-problem-add-more-options-tp3087495p3089865.html Sent from the Drools: User forum mailing list archive at Nabble.com. ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users
Re: [rules-users] can not use mvel to access object in a map in THEN
I am sorry for missing information in question. I am using Drools 5.1. I find out the reason just now. I added Generic on Map on the get method for dataMap and now it works. public Maplt;String, Datagt; getDataMap() { return dataMap; } Thank you for replying! -- View this message in context: http://drools.46999.n3.nabble.com/can-not-use-mvel-to-access-object-in-a-map-in-THEN-tp3062652p3090003.html Sent from the Drools: User forum mailing list archive at Nabble.com. ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users
Re: [rules-users] Guvnor guided editor problem - add more options
The book is the PAKT Publishing book JBoss Drools Business Rules by Paul Browne. Am using Drools 5.1 and Guvnor 5.0.0.SNAPSHOT 25673M Using the guided editor to create a rule that states if a sale has a value of over 100 then discount it by 10. Have partly created a rule as exactly how the book says as follows: 1. Create a new rule and add a condition using a sales fact (This has been done OK.) 2. When adding the first constraint, enter a variable name (mySales) (this has been doen OK) 3. Select GREATER THAN OR EQUAL TO in the PLEASE CHOOSE drop-down box, and use the pencil icon to enter the value (100) - (this has been done OK) 4. On the second line of the newly created rule, click on the green arrow above SALES. An option to bind the actual sales total to a variable is shown. In this dialog box, assign it to salesValue (this has been done OK) 5. In the guided editor, The Add new Action dialog box now has additonal options. Click on the green + sign whcih is next to THEN to make these options appear. In this dialog box choose to modify the mySales fact (This has been done OK) The next bit is the bit that I cannot get to work: Back in the guided editor, click on the pencil icon and enter the formula (=salesValue-10) What happens is that when you click to add the formula - you do not get that option, you only get an option to ADD A FIELD and it shows a list of available fields I have gone upt to step 5 and viewed the source which is as follows: 1. rule SalesDiscount 2. no-loop true 3. dialect mvel 4. when 5. mySales : Sales( salesvalues : sales = 100 ) 6. then 7. update( mySales ); 8. end Which is as it should be up to step 5 (according to the book) What it should look like after adding the formula is: rule SalesDiscount no-loop true dialect mvel when mySales : Sales( salesvalues : sales = 100 ) then mySales:setSales( salesValue-10) update( mySales ); end Hope this explains - I am also very new to Drools and trying to learn Many Tanks -- Best Regards Marros -- View this message in context: http://drools.46999.n3.nabble.com/Guvnor-guided-editor-problem-add-more-options-tp3087495p3090032.html Sent from the Drools: User forum mailing list archive at Nabble.com. ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users
Re: [rules-users] Guvnor guided editor problem - add more options
OK. I tried here (admittedly with 5.2, but I don't believe we've changed the area in question much - if at all). These are the steps I followed (which might highlight an additional step not clear in the book):- - Complete up to step 5 - Click on the pencil icon (as you have done) - Select the sales field - The field sales will be shown with another pencil icon - Click on the new pencil icon and you are given the option of a literal value or a formula. - Choose formula Let me know if this helps? Thanks, Mike On 21 June 2011 11:05, marros martin.ros...@vships.com wrote: The book is the PAKT Publishing book JBoss Drools Business Rules by Paul Browne. Am using Drools 5.1 and Guvnor 5.0.0.SNAPSHOT 25673M Using the guided editor to create a rule that states if a sale has a value of over 100 then discount it by 10. Have partly created a rule as exactly how the book says as follows: 1. Create a new rule and add a condition using a sales fact (This has been done OK.) 2. When adding the first constraint, enter a variable name (mySales) (this has been doen OK) 3. Select GREATER THAN OR EQUAL TO in the PLEASE CHOOSE drop-down box, and use the pencil icon to enter the value (100) - (this has been done OK) 4. On the second line of the newly created rule, click on the green arrow above SALES. An option to bind the actual sales total to a variable is shown. In this dialog box, assign it to salesValue (this has been done OK) 5. In the guided editor, The Add new Action dialog box now has additonal options. Click on the green + sign whcih is next to THEN to make these options appear. In this dialog box choose to modify the mySales fact (This has been done OK) The next bit is the bit that I cannot get to work: Back in the guided editor, click on the pencil icon and enter the formula (=salesValue-10) What happens is that when you click to add the formula - you do not get that option, you only get an option to ADD A FIELD and it shows a list of available fields I have gone upt to step 5 and viewed the source which is as follows: 1. rule SalesDiscount 2. no-loop true 3. dialect mvel 4. when 5. mySales : Sales( salesvalues : sales = 100 ) 6. then 7. update( mySales ); 8. end Which is as it should be up to step 5 (according to the book) What it should look like after adding the formula is: rule SalesDiscount no-loop true dialect mvel when mySales : Sales( salesvalues : sales = 100 ) then mySales:setSales( salesValue-10) update( mySales ); end Hope this explains - I am also very new to Drools and trying to learn Many Tanks -- Best Regards Marros -- View this message in context: http://drools.46999.n3.nabble.com/Guvnor-guided-editor-problem-add-more-options-tp3087495p3090032.html Sent from the Drools: User forum mailing list archive at Nabble.com. ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users
Re: [rules-users] Guvnor guided editor problem - add more options
Hi Mike, Thnaks for your help. Still a problem I am afraid. I have done what you sugested (up to step 5) I have clicked the pencil icon and added the sales field nad as you say the sales is shown with another pencil icon. HOwever when you try to click on the new pencil icon - nothing happens at all. It's as if you cannot edit it. Brgds, Martin - -- Best Regards Marros -- View this message in context: http://drools.46999.n3.nabble.com/Guvnor-guided-editor-problem-add-more-options-tp3087495p3090186.html Sent from the Drools: User forum mailing list archive at Nabble.com. ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users
Re: [rules-users] Guvnor guided editor problem - add more options
Hi again Mike, If it helps here is a creenshot of how it looks in the guided editor: http://drools.46999.n3.nabble.com/file/n3090196/jboss.jpg - -- Best Regards Marros -- View this message in context: http://drools.46999.n3.nabble.com/Guvnor-guided-editor-problem-add-more-options-tp3087495p3090196.html Sent from the Drools: User forum mailing list archive at Nabble.com. ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users
Re: [rules-users] Guvnor guided editor problem - add more options
That sounds very bug-like ;) I will try to find a copy of Guvnor 5.0.0.SNAPSHOT 25673M , but it is (a) quite old now, (b) a SNAPSHOT so not the final 5.0.0 release anyway I suspect (but can't be certain) that the book might have mentioned use of this version because it needed features added to that release in order to go to print - if so a newer version should be usable just the same. Any reason you can't use Guvnor 5.1 (5.2 *should* be available later this week too)? With kind regards, Mike On 21 June 2011 12:15, marros martin.ros...@vships.com wrote: Hi again Mike, If it helps here is a creenshot of how it looks in the guided editor: http://drools.46999.n3.nabble.com/file/n3090196/jboss.jpg - -- Best Regards Marros -- View this message in context: http://drools.46999.n3.nabble.com/Guvnor-guided-editor-problem-add-more-options-tp3087495p3090196.html Sent from the Drools: User forum mailing list archive at Nabble.com. ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users
Re: [rules-users] Guvnor guided editor problem - add more options
Hi Mike, Thanks for your advice. I have downloaded drools-5.1.1-guvnor.war and then copied it to the Jboss Deploy directory On the JBoss server screen I saw it attempting to deploy but then it failed with Deplyment Exception: invalid block type; - nested throwable: (java.util.zip.Zipexception: invalid block type) at org.jboss.web.AbstractWebContainer.init(AbstractWebContainer.java:374) Now I cannot restart Drools - -- Best Regards Marros -- View this message in context: http://drools.46999.n3.nabble.com/Guvnor-guided-editor-problem-add-more-options-tp3087495p3090362.html Sent from the Drools: User forum mailing list archive at Nabble.com. ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users
[rules-users] Drools' use of hashCode
Hi all, I have encountered a situation I don't quite understand, I would be happy to have some explanations about it. This is my first post here and I'm quite new to all this so don't be afraid to go back to basics if I'm missing something: I have 3 classes : public class Child { private Date time; +get +set +constructor } public class Father { private Child child; private int value; +get +set +constructor public void setTime(Date d) { child.setTime(d); } } public class GdFather { private Father father; +get +set +constructor } then 2 rules : rule 1 when $father : Father(value==1) then $father.setTime(new Date(2)); $father.setValue(0); update($father); end rule 2 when $father : Father() $GdFather : GdFather(father==$father) then System.out.println($father); end I didn't change the identity assert behavior, I insert a father and the corresponding GdFather in the workingMemory, and all seems to work OK. The issue occurs when I override the hashCode function in the Father class : if I use this definition : @Override public int hashCode() { return child.getTime().hashCode(); } then rule 2 is not fired after modification of the father, and is not either if I change the function to return child.hashCode() with a Child hashCode returning time.hashCode(). This also happens with a properly overriden equals function, and both Drools 5.1.1 and 5.2.0.CR1. What I don't understand is why is it using the overriden hashCode function with an identity assert behavior? What is it used for? And it looks like it is using the overriden hashCode, but not equals, is that correct, and if so, why? How can I get the second rule to fire and have a custom hashCode() ? Thank you in advance for your answers, M.H. -- View this message in context: http://drools.46999.n3.nabble.com/Drools-use-of-hashCode-tp3090419p3090419.html Sent from the Drools: User forum mailing list archive at Nabble.com. ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users
[rules-users] Drools' use of hashCode
Hi all, I have encountered a situation I don't quite understand, I would be happy to have some explanations about it. This is my first post here and I'm quite new to all this so don't be afraid to go back to basics if I'm missing something: I have 3 classes : public class Child { private Date time; +get +set +constructor } public class Father { private Child child; private int value; +get +set +constructor public void setTime(Date d) { child.setTime(d); } } public class GdFather { private Father father; +get +set +constructor } then 2 rules : rule 1 when $father : Father(value==1) then $father.setTime(new Date(2)); $father.setValue(0); update($father); end rule 2 when $father : Father() $GdFather : GdFather(father==$father) then System.out.println($father); end I didn't change the identity assert behavior, I insert a father and the corresponding GdFather in the workingMemory, and all seems to work OK. The issue occurs when I override the hashCode function in the Father class : if I use this definition : @Override public int hashCode() { return child.getTime().hashCode(); } then rule 2 is not fired after modification of the father, and is not either if I change the function to return child.hashCode() with a Child hashCode returning time.hashCode(). This also happens with a properly overriden equals function, and both Drools 5.1.1 and 5.2.0.CR1. What I don't understand is why is it using the overriden hashCode function with an identity assert behavior? What is it used for? And it looks like it is using the overriden hashCode, but not equals, is that correct, and if so, why? How can I get the second rule to fire and have a custom hashCode() ? Thank you in advance for your answers, M.H. -- View this message in context: http://drools.46999.n3.nabble.com/Drools-use-of-hashCode-tp3090424p3090424.html Sent from the Drools: User forum mailing list archive at Nabble.com. ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users
Re: [rules-users] Drools' use of hashCode
Assert behaviour merely defines the engine's reaction w.r.t. to the insertion of another fact that might be considered being the same as one that's already in the WM. This is due to the simple truth that facts represent true propositions (and that you aren't the Bellmanhttp://www.theotherpages.org/poems/carrol03.html.) For hashCode() and equals() you must follow the usual Java rules. -W On 21 June 2011 14:29, M. H. hugues...@hotmail.com wrote: Hi all, I have encountered a situation I don't quite understand, I would be happy to have some explanations about it. This is my first post here and I'm quite new to all this so don't be afraid to go back to basics if I'm missing something: I have 3 classes : public class Child { private Date time; +get +set +constructor } public class Father { private Child child; private int value; +get +set +constructor public void setTime(Date d) { child.setTime(d); } } public class GdFather { private Father father; +get +set +constructor } then 2 rules : rule 1 when $father : Father(value==1) then $father.setTime(new Date(2)); $father.setValue(0); update($father); end rule 2 when $father : Father() $GdFather : GdFather(father==$father) then System.out.println($father); end I didn't change the identity assert behavior, I insert a father and the corresponding GdFather in the workingMemory, and all seems to work OK. The issue occurs when I override the hashCode function in the Father class : if I use this definition : @Override public int hashCode() { return child.getTime().hashCode(); } then rule 2 is not fired after modification of the father, and is not either if I change the function to return child.hashCode() with a Child hashCode returning time.hashCode(). This also happens with a properly overriden equals function, and both Drools 5.1.1 and 5.2.0.CR1. What I don't understand is why is it using the overriden hashCode function with an identity assert behavior? What is it used for? And it looks like it is using the overriden hashCode, but not equals, is that correct, and if so, why? How can I get the second rule to fire and have a custom hashCode() ? Thank you in advance for your answers, M.H. -- View this message in context: http://drools.46999.n3.nabble.com/Drools-use-of-hashCode-tp3090419p3090419.html Sent from the Drools: User forum mailing list archive at Nabble.com. ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users
Re: [rules-users] Drools' use of hashCode
Ok Thanks for your answer. I just looked more closely, and actually it looks like what I was doing just can't work this way: when I update the father in rule 1, then I can't join it with its GdFather anymore without updating it too, am I right? Or I would have to use eval(father==$father) instead of simply father==$father which uses equals() and hashCode(), but then I'll lose all the performance? -- View this message in context: http://drools.46999.n3.nabble.com/rules-users-Drools-use-of-hashCode-tp3090455p3090757.html Sent from the Drools: User forum mailing list archive at Nabble.com. ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users
[rules-users] named query TasksAssignedAsPotentialOwner doesn't work with MySql db
Hi, When I add a task (having two potential owners) by calling the method addTask followed by calling the method getTasksAssignedAsPotentialOwner of org.jbpm.task.service.TaskClient I expect to receive a list of TaskSummaries containing at least the previously added task. But I actually get an empty list! Here is my setup and possible solution: I am using the trunk version of ./jbpm-human-task/src/main/resources/META-INF/orm.xml and a MYSQL database. When calling addTask the Task table will be populated with a NULL actualOwner_id. The named query TasksAssignedAsPotentialOwner select new org.jbpm.task.query.TaskSummary(...t.taskData.actualOwner...) from ... left join t.taskData.actualOwner ... of orm.xml generates SQL consisting of an inner join inner join OrganizationalEntity user7_ on task0_.actualOwner_id=user7_.id which doesn't take the NULL actualOwner_id correctly into account. When I replace the named query TasksAssignedAsPotentialOwner with select new org.jbpm.task.query.TaskSummary(...actualOwner...) from ...left join t.taskData.actualOwner as actualOwner ..., then the generated SQL consists of an left outer join OrganizationalEntity user2_ on task0_.actualOwner_id=user2_.id which takes the NULL actualOwner_id correctly into account. So I get a List of TaskSummaries containing the added task. Is this a correct fix? Cheers, Frank -- View this message in context: http://drools.46999.n3.nabble.com/named-query-TasksAssignedAsPotentialOwner-doesn-t-work-with-MySql-db-tp3091117p3091117.html Sent from the Drools: User forum mailing list archive at Nabble.com. ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users
Re: [rules-users] Guvnor guided editor problem - add more options
lol - glad I could help ;) java.util.zip.Zipexception: invalid block type sounds like the WAR file is somehow corrupt. Where did you get it from (and can you re-try?). Send me the link (and what AS you're using) and I'll try here too Cheers, Mike On 21 June 2011 13:07, marros martin.ros...@vships.com wrote: Hi Mike, Thanks for your advice. I have downloaded drools-5.1.1-guvnor.war and then copied it to the Jboss Deploy directory On the JBoss server screen I saw it attempting to deploy but then it failed with Deplyment Exception: invalid block type; - nested throwable: (java.util.zip.Zipexception: invalid block type) at org.jboss.web.AbstractWebContainer.init(AbstractWebContainer.java:374) Now I cannot restart Drools - -- Best Regards Marros -- View this message in context: http://drools.46999.n3.nabble.com/Guvnor-guided-editor-problem-add-more-options-tp3087495p3090362.html Sent from the Drools: User forum mailing list archive at Nabble.com. ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users
[rules-users] Rule Templates - comma separated data
I have successfully generated a .drl file from a decision table. The column headers in this table made use of the forall(||) construct which happily parsed the corresponding comma separated data in the relevant spreadsheet cell to nice || separated conditions. We have since decided to use the template approach so we can store rule data in a db. We ideally want to store this data as key/value pairs in a db table where the values may contain comma separated data. The intention being these values would be processed as per the decision table. How is this achieved using a template ? I note that a column can be denoted as an array column by adding [] i.e. template header column[] However, although this appears create an ArrayColumn parser, and splits the comma separated data when running through a debugger, any attempt to access it in the template falls over in mvel code trying to call HashMap.column Any examples on how to set this up ? Thx ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users
Re: [rules-users] Drools' use of hashCode
Updating a fact does not affect any other fact containing a reference to that updated fact. Thus, father == $father isn't changed. If, however, the Child object changed via the Father method were a fact, an update() of that Child fact would usually be required. -W On 21 June 2011 16:02, M. H. hugues...@hotmail.com wrote: Ok Thanks for your answer. I just looked more closely, and actually it looks like what I was doing just can't work this way: when I update the father in rule 1, then I can't join it with its GdFather anymore without updating it too, am I right? Or I would have to use eval(father==$father) instead of simply father==$father which uses equals() and hashCode(), but then I'll lose all the performance? -- View this message in context: http://drools.46999.n3.nabble.com/rules-users-Drools-use-of-hashCode-tp3090455p3090757.html Sent from the Drools: User forum mailing list archive at Nabble.com. ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users
Re: [rules-users] Rule Templates - comma separated data
The operators in and not in operate on parenthesized lists of operands. They can be used with a single template parameter expanding as a list. Person( likes in ( apple, banana, chili ) ) is the same as Person( likes == apple || == banana || == chili ) -W On 21 June 2011 18:34, Witham, Darren darren.wit...@citi.com wrote: I have successfully generated a .drl file from a decision table. The column headers in this table made use of the forall(||) construct which happily parsed the corresponding comma separated data in the relevant spreadsheet cell to nice || separated conditions. We have since decided to use the template approach so we can store rule data in a db. We ideally want to store this data as key/value pairs in a db table where the values may contain comma separated data. The intention being these values would be processed as per the decision table. How is this achieved using a template ? I note that a column can be denoted as an array column by adding [] i.e. template header column[] However, although this appears create an ArrayColumn parser, and splits the comma separated data when running through a debugger, any attempt to access it in the template falls over in mvel code trying to call HashMap.column Any examples on how to set this up ? Thx ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users
[rules-users] comma on LHS in dsl
Hi there, I had something like this in drools 3.0 and it used to work but after I upgraded to drools 5.0 it doesn't work. [when]The Roof is not Type A , Type B , Type C , or RC=LM(rda != null, rda != A, rda != B, rda != C, rda != R) But to compile it now I had to make the following changes on both LHS and RHS: [when]The Roof is not Type A not Type B not Type C not RC=LM(rda != null rda != A rda != B rda != C rda != R) Why does the , on the LHS doesn't compile? Thanks, Saleem ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users
Re: [rules-users] Guvnor guided editor problem - add more options
I have managed to reproduce the problem with drools guvnor standalone 5.1. Or actually i get the pen icon on my laptop while Pekka does not. Same windows 7 same FireFox 4 On Jun 21, 2011 6:14 PM, Michael Anstis michael.ans...@gmail.com wrote: lol - glad I could help ;) java.util.zip.Zipexception: invalid block type sounds like the WAR file is somehow corrupt. Where did you get it from (and can you re-try?). Send me the link (and what AS you're using) and I'll try here too Cheers, Mike On 21 June 2011 13:07, marros martin.ros...@vships.com wrote: Hi Mike, Thanks for your advice. I have downloaded drools-5.1.1-guvnor.war and then copied it to the Jboss Deploy directory On the JBoss server screen I saw it attempting to deploy but then it failed with Deplyment Exception: invalid block type; - nested throwable: (java.util.zip.Zipexception: invalid block type) at org.jboss.web.AbstractWebContainer.init(AbstractWebContainer.java:374) Now I cannot restart Drools - -- Best Regards Marros -- View this message in context: http://drools.46999.n3.nabble.com/Guvnor-guided-editor-problem-add-more-options-tp3087495p3090362.html Sent from the Drools: User forum mailing list archive at Nabble.com. ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users