Re: [rules-users] Data comparing in CONDITION column decision table
I inserted Account column with values that are always true. Works fine. :) Will try the same with 5.3 . Thanks & Regards, Sumeet From: Wolfgang Laun To: Rules Users List Date: 03/15/2012 05:30 PM Subject:Re: [rules-users] Data comparing in CONDITION column decision table Sent by:rules-users-boun...@lists.jboss.org The documentation for 5.3.0 says To include a pattern without constraints, you can write the pattern in front of the text for another pattern. but it does not work with 5.2.0 and (likely) later versions. As a workaround, re-insert the Account column and use a redundant condition that is certainly true for all facts. I'll have to look into this. -W On 15/03/2012, Sumeet Karawal wrote: > Hi Wolfgang > > any other way to achieve this. I have tried many times, but no success till > now :( > > Thanks, > Sumeet > > > > > From: Sumeet Karawal > > > To: Rules Users List > > > Date: 03/15/2012 04:24 PM > > > Subject:Re: [rules-users] Data comparing in CONDITION column decision > table > > Sent by:rules-users-boun...@lists.jboss.org > > > > > > > > > > After doing the changes, its taking the rules as: > > rule "Discount_10" > when > > $a:Account(type == $a.getType(), accno == 1001) > $c:Customer > then > > $c.setDiscount(1); > end > > > and if I put it as $a: Account() $c: Customer(), it takes the rules as: > > rule "Discount_10" > when > > $a:Account(type == $a.getType(), accno == 1001) > $c:Customer() > then > > $c.setDiscount(1); > end > > Both these throw error.. > > > > neither putting the $c:Customer before $a:Account is getting executed. > > > Thanks & Regards, > Sumeet > Mailto: sumeet.kara...@tcs.com > > > > From: Wolfgang Laun > > > To: Rules Users List > > > Date: 03/15/2012 04:06 PM > > > Subject:Re: [rules-users] Data comparing in CONDITION column decision > table > > Sent by:rules-users-boun...@lists.jboss.org > > > > > > > > On 15/03/2012, Sumeet Karawal wrote: >> >> How to make changes to the decision table entries to get a drl of this >> kind: >> > > Put >$a: Account() $c: Customer > into the cell where you now have $c : Customer and delete the Account > column. > -W > >> >> rule "Discount_10" >> when >> $a : Account() >> $c : Customer(type == > $a.getType(), accno == 1001) >> then >> $c.setDiscount(1); >> end >> >> >> Thanks, >> Sumeet >> Mailto: sumeet.kara...@tcs.com >> >> >> >> From: Wolfgang Laun >> >> >> To: Rules Users List >> >> >> Date: 03/15/2012 02:47 PM >> >> >> Subject:Re: [rules-users] Data comparing in CONDITION column > decision >> table &
Re: [rules-users] Data comparing in CONDITION column decision table
Hi Wolfgang any other way to achieve this. I have tried many times, but no success till now :( Thanks, Sumeet From: Sumeet Karawal To: Rules Users List Date: 03/15/2012 04:24 PM Subject:Re: [rules-users] Data comparing in CONDITION column decision table Sent by:rules-users-boun...@lists.jboss.org After doing the changes, its taking the rules as: rule "Discount_10" when $a:Account(type == $a.getType(), accno == 1001) $c:Customer then $c.setDiscount(1); end and if I put it as $a: Account() $c: Customer(), it takes the rules as: rule "Discount_10" when $a:Account(type == $a.getType(), accno == 1001) $c:Customer() then $c.setDiscount(1); end Both these throw error.. neither putting the $c:Customer before $a:Account is getting executed. Thanks & Regards, Sumeet Mailto: sumeet.kara...@tcs.com From: Wolfgang Laun To: Rules Users List Date: 03/15/2012 04:06 PM Subject:Re: [rules-users] Data comparing in CONDITION column decision table Sent by:rules-users-boun...@lists.jboss.org On 15/03/2012, Sumeet Karawal wrote: > > How to make changes to the decision table entries to get a drl of this > kind: > Put $a: Account() $c: Customer into the cell where you now have $c : Customer and delete the Account column. -W > > rule "Discount_10" > when > $a : Account() > $c : > Customer(type == $a.getType(), accno == 1001) > then > > $c.setDiscount(1); > end > > > Thanks, > Sumeet > Mailto: sumeet.kara...@tcs.com > > > > From: Wolfgang Laun > > > To: Rules Users List > > > Date: 03/15/2012 02:47 PM > > > Subject:Re: [rules-users] Data comparing in CONDITION column decision > table > > Sent by:rules-users-boun...@lists.jboss.org > > > > > > > > Line breaks were lost in transit, but I think that you should remove > the quotes from > >type == "$param" > > if you insert an expression $a.getType(). > > -W > > > On 15/03/2012, Sumeet Karawal wrote: >> >> Hi, >> >> Can we use a data value of another object in the condition column of a >> Spreadsheet. >> >> For example: I have two data types(POJOs) one com.bank.Customer and other >> com.bank.Account >> >> in the rules I want to check whether the value entered for a particular >> field in Customer class is equal to the value entered for the > corresponding >> field in the Account class. eg Customer.accType = Account.accType() >> >> >> How can we achieve this using Decision table (CONDITION Column). I have >> tried this: >> >> >>|RuleTable >>|Discount >> >>|CONDITION |CONDITION | >> ---+| >>|$a : Account |$c : Customer | >> ---+--
Re: [rules-users] Data comparing in CONDITION column decision table
After doing the changes, its taking the rules as: rule "Discount_10" when $a:Account(type == $a.getType(), accno == 1001) $c:Customer then $c.setDiscount(1); end and if I put it as $a: Account() $c: Customer(), it takes the rules as: rule "Discount_10" when $a:Account(type == $a.getType(), accno == 1001) $c:Customer() then $c.setDiscount(1); end Both these throw error.. neither putting the $c:Customer before $a:Account is getting executed. Thanks & Regards, Sumeet Mailto: sumeet.kara...@tcs.com From: Wolfgang Laun To: Rules Users List Date: 03/15/2012 04:06 PM Subject:Re: [rules-users] Data comparing in CONDITION column decision table Sent by:rules-users-boun...@lists.jboss.org On 15/03/2012, Sumeet Karawal wrote: > > How to make changes to the decision table entries to get a drl of this > kind: > Put $a: Account() $c: Customer into the cell where you now have $c : Customer and delete the Account column. -W > > rule "Discount_10" >when >$a : Account() >$c : Customer(type == $a.getType(), accno == > 1001) >then >$c.setDiscount(1); > end > > > Thanks, > Sumeet > Mailto: sumeet.kara...@tcs.com > > > > From: Wolfgang Laun > > > To: Rules Users List > > > Date: 03/15/2012 02:47 PM > > > Subject:Re: [rules-users] Data comparing in CONDITION column decision > table > > Sent by:rules-users-boun...@lists.jboss.org > > > > > > > > Line breaks were lost in transit, but I think that you should remove > the quotes from > >type == "$param" > > if you insert an expression $a.getType(). > > -W > > > On 15/03/2012, Sumeet Karawal wrote: >> >> Hi, >> >> Can we use a data value of another object in the condition column of a >> Spreadsheet. >> >> For example: I have two data types(POJOs) one com.bank.Customer and other >> com.bank.Account >> >> in the rules I want to check whether the value entered for a particular >> field in Customer class is equal to the value entered for the > corresponding >> field in the Account class. eg Customer.accType = Account.accType() >> >> >> How can we achieve this using Decision table (CONDITION Column). I have >> tried this: >> >> >>|RuleTable >>|Discount >> >>|CONDITION |CONDITION | >> ---+| >>|$a : Account |$c : Customer | >> ---+| >>| |type == "$param" >> --+---+ >> | Discount |Account|Type| >> | Rules | || >> |--+---+| >> |1 | |$a.getType()| >> |--+---+| >> |2 | |$a.getType()| >> |--+---+
Re: [rules-users] Data comparing in CONDITION column decision table
Sent by:rules-users-boun...@lists.jboss.org Line breaks were lost in transit, but I think that you should remove the quotes from type == "$param" if you insert an expression $a.getType(). -W On 15/03/2012, Sumeet Karawal wrote: > > Hi, > > Can we use a data value of another object in the condition column of a > Spreadsheet. > > For example: I have two data types(POJOs) one com.bank.Customer and other > com.bank.Account > > in the rules I want to check whether the value entered for a particular > field in Customer class is equal to the value entered for the corresponding > field in the Account class. eg Customer.accType = Account.accType() > > > How can we achieve this using Decision table (CONDITION Column). I have > tried this: > > >|RuleTable >|Discount > >|CONDITION |CONDITION | > ---+| >|$a : Account |$c : Customer | > ---+| >| |type == "$param" > --+---+ > | Discount |Account|Type| > | Rules | || > |--+---+| > |1 | |$a.getType()| > |--+---+| > |2 | |$a.getType()| > |--+---+| > |3 | |$a.getType()| > |--+---+| > |4 | |$a.getType()| > |--+---+| > |5 | |$a.getType()| > |--+---+| > |6 | | $a.getType()| > |--+---+| > > > > > But it won't work. It would be great if somebody could help me on this. > > Thanks & Regards, > Sumeet Karawal > Mailto: sumeet.kara...@tcs.com > > =-=-= > Notice: The information contained in this e-mail > message and/or attachments to it may contain > confidential or privileged information. If you are > not the intended recipient, any dissemination, use, > review, distribution, printing or copying of the > information contained in this e-mail message > and/or attachments to it are strictly prohibited. If > you have received this communication in error, > please notify us by reply e-mail or telephone and > immediately and permanently delete the message > and any attachments. Thank you > > > > ___ > rules-users mailing list > rules-users@lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users > ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users
[rules-users] Data comparing in CONDITION column decision table
Hi, Can we use a data value of another object in the condition column of a Spreadsheet. For example: I have two data types(POJOs) one com.bank.Customer and other com.bank.Account in the rules I want to check whether the value entered for a particular field in Customer class is equal to the value entered for the corresponding field in the Account class. eg Customer.accType = Account.accType() How can we achieve this using Decision table (CONDITION Column). I have tried this: |RuleTable |Discount |CONDITION |CONDITION | ---+| |$a : Account |$c : Customer | ---+| | |type == "$param" --+---+ | Discount |Account|Type| | Rules | || |--+---+| |1 | |$a.getType()| |--+---+| |2 | |$a.getType()| |--+---+| |3 | |$a.getType()| |--+---+| |4 | |$a.getType()| |--+---+| |5 | |$a.getType()| |--+---+| |6 | |$a.getType()| |--+---+| But it won't work. It would be great if somebody could help me on this. Thanks & Regards, Sumeet Karawal Mailto: sumeet.kara...@tcs.com =-=-= Notice: The information contained in this e-mail message and/or attachments to it may contain confidential or privileged information. If you are not the intended recipient, any dissemination, use, review, distribution, printing or copying of the information contained in this e-mail message and/or attachments to it are strictly prohibited. If you have received this communication in error, please notify us by reply e-mail or telephone and immediately and permanently delete the message and any attachments. Thank you ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users
[rules-users] Unable to do Guvnor Authentiation with MySQL
Hi, Has anybody encountered the similar problem, could someone please help me on this. TIA, Sumeet Mailto: sumeet.kara...@tcs.com - Forwarded by Sumeet Karawal/MUM/TCS on 01/11/2012 05:16 PM - From: Sumeet Karawal To: rules-users@lists.jboss.org Date: 01/09/2012 08:18 PM Subject:[rules-users] Unable to do Guvnor Authentiation with MySQL Sent by:rules-users-boun...@lists.jboss.org Hi All, I am trying to enable authentication in Guvnor using MySQL. I am using MySQL 5.1, Guvnor 5.2 and JBoss AS 5.0.4 I searched over a lot of docs and tried to do as mentioned below : I have created a GuvnorDB in MySQL with two tables create table Principals(principal_id VARCHAR(64),password VARCHAR (64)); create table roles(principal_id VARCHAR(64),user_role VARCHAR (64),role_group VARCHAR(64)); and have entered some values accordingly (admin, admin123) and (admin, admin, admin); My components.xml in drools-guvnor.war is as follows : http://jboss.com/products/seam/components"; xmlns:core="http://jboss.com/products/seam/core"; xmlns:security="http://jboss.com/products/seam/security"; xmlns:web="http://jboss.com/products/seam/web"; xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"; xmlns:transaction="http://jboss.com/products/seam/transaction"; xsi:schemaLocation="http://jboss.com/products/seam/core http://jboss.com/products/seam/core-2.0.xsd http://jboss.com/products/seam/security http://jboss.com/products/seam/security-2.0.xsd http://jboss.com/products/seam/components http://jboss.com/products/seam/components-2.0.xsd http://jboss.com/products/seam/web http://jboss.com/products/seam/web-2.0.xsd http://jboss.com/products/seam/transaction http://jboss.com/products/seam/transaction-2.0.xsd";> org.drools.repository.configuratororg.drools.repository.jackrabbit.JackrabbitRepositoryConfigurator true I have also changed my login-config.xml accordingly and added a application policy : java:/MySqlDS select password from principals where principal_id=? select user_role,'Roles' from roles where principal_id=? I have also created a mysql-ds.xml and saved it in the default/deploy folder; its contents : MySqlDS jdbc:mysql://localhost:3306/GuvnorDB com.mysql.jdbc.Driver root org.jboss.resource.adapter.jdbc.vendor.MySQLValidConnectionChecker mySQL getting an exceptiogetting After all these changes, when I run guvnor and try to login, I am getting an exception thrown at the console: 01:36:41,212 INFO [STDOUT] INFO 10-01 01:36:41,211 (SecurityServiceImpl.java:login:57) Logging in user [admin] 01:36:41,360 INFO [STDOUT] ERROR 10-01 01:36:41,357 (SecurityServiceImpl.java:login:77) Unable to login. javax.security.auth.login.FailedLoginException: Password Incorrect/Password Required at org.jboss.security.auth.spi.UsernamePasswordLoginModule.login (UsernamePasswordLoginModule.java:213) 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:616) at javax.security.auth.login.LoginContext.invoke (LoginContext.java:784) at javax.security.
[rules-users] Unable to do Guvnor Authentiation with MySQL
Hi All, I am trying to enable authentication in Guvnor using MySQL. I am using MySQL 5.1, Guvnor 5.2 and JBoss AS 5.0.4 I searched over a lot of docs and tried to do as mentioned below : I have created a GuvnorDB in MySQL with two tables create table Principals(principal_id VARCHAR(64),password VARCHAR (64)); create table roles(principal_id VARCHAR(64),user_role VARCHAR (64),role_group VARCHAR(64)); and have entered some values accordingly (admin, admin123) and (admin, admin, admin); My components.xml in drools-guvnor.war is as follows : http://jboss.com/products/seam/components"; xmlns:core="http://jboss.com/products/seam/core"; xmlns:security="http://jboss.com/products/seam/security"; xmlns:web="http://jboss.com/products/seam/web"; xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"; xmlns:transaction="http://jboss.com/products/seam/transaction"; xsi:schemaLocation="http://jboss.com/products/seam/core http://jboss.com/products/seam/core-2.0.xsd http://jboss.com/products/seam/security http://jboss.com/products/seam/security-2.0.xsd http://jboss.com/products/seam/components http://jboss.com/products/seam/components-2.0.xsd http://jboss.com/products/seam/web http://jboss.com/products/seam/web-2.0.xsd http://jboss.com/products/seam/transaction http://jboss.com/products/seam/transaction-2.0.xsd";> org.drools.repository.configuratororg.drools.repository.jackrabbit.JackrabbitRepositoryConfigurator true I have also changed my login-config.xml accordingly and added a application policy : java:/MySqlDS select password from principals where principal_id=? select user_role,'Roles' from roles where principal_id=? I have also created a mysql-ds.xml and saved it in the default/deploy folder; its contents : MySqlDS jdbc:mysql://localhost:3306/GuvnorDB com.mysql.jdbc.Driver root org.jboss.resource.adapter.jdbc.vendor.MySQLValidConnectionChecker mySQL getting an exceptiogetting After all these changes, when I run guvnor and try to login, I am getting an exception thrown at the console: 01:36:41,212 INFO [STDOUT] INFO 10-01 01:36:41,211 (SecurityServiceImpl.java:login:57) Logging in user [admin] 01:36:41,360 INFO [STDOUT] ERROR 10-01 01:36:41,357 (SecurityServiceImpl.java:login:77) Unable to login. javax.security.auth.login.FailedLoginException: Password Incorrect/Password Required at org.jboss.security.auth.spi.UsernamePasswordLoginModule.login (UsernamePasswordLoginModule.java:213) 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:616) at javax.security.auth.login.LoginContext.invoke (LoginContext.java:784) at javax.security.auth.login.LoginContext.access$000 (LoginContext.java:203) at javax.security.auth.login.LoginContext$4.run (LoginContext.java:698) at javax.security.auth.login.LoginContext$4.run (LoginContext.java:696) at java.security.AccessController.doPrivileged(Native Method) at javax.security.auth.login.LoginContext.invokePriv (LoginContext.java:695) at javax.security.auth.login.LoginContext.login (LoginContext.java:594) at org.jboss.seam.security.Identity.authenticate(Identity.java:335) at org.jboss.seam.security.Identity.authenticate(Identity.java:324) at org.drools.guvnor.server.security.SecurityServiceImpl.login (SecurityServiceImpl.java:75) at org.drools.guvnor.server.SecurityServiceServlet.login (SecurityServiceServlet.java:71) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke (NativeMethodAccessorImpl.java:57).. . I tried a lot but not getting through on how to do this. It would really helpful if somebody could guide me on this. Thanks & Regards, Sumeet Mailto: sumeet.kara...@tcs.com =-=-= Notice: The information contained in this e-mail message and/or attachments to it may contain confidential or privileged information. If you are not the intended recipient, any dissemination, use, review, distribution, printing or copying of the information contained in this e-mail message and/or attachments to it are strictly prohibited. If you have received this communication in error, please notify us by reply e-mail or telephone and immediately and permanently delete the message and any attachments. Thank you ___ rules-users mailing list rules-users@lists.jboss.org http
Re: [rules-users] Decision table multiple sheets...
10:38 > To: Rules Users List > Subject: Re: [rules-users] Decision table multiple sheets... > > By definition (see the "Expert" manual) only sheet 1 is used for generating > rules. > > For controlling rule firing you may consider using any of the rule attributes > supported by spreadsheets, e.g., agenda-group. > > -W > > On 21/12/2011, Sumeet Karawal wrote: > > > > Hi, > > > > I am having my rules in a Decision Table (.xls) > > > > There I have 3 sheets for rules. > > > > Like in Sheet1 there are two Rule Tables... In Sheet2 there are 2 and > > in > > Sheet3 there is only 1. > > > > When I am creating the knowledgebase and firing rules, the rules that > > are in the Sheet1 are getting fired. But the rules in other sheets are > > not getting fired. > > > > When I convert them to String to check using this code : > > > > String str = DecisionTableFactory.loadFromInputStream > > (ResourceFactory.newClassPathResource > > ("com/sample/MemberDiscountRules.xls").getInputStream(), dtconf); > > System.out.println(str); > > > > I can see the rules that are present in Sheet1 only. > > > > Please anybody help me on this. How can I get the rules in other two > > sheets to get fired. > > Also how can we fire the rules of only a particular Rule table in the > > decision table. > > > > Thanks & Regards, > > Sumeet > > > > Mailto: sumeet.kara...@tcs.com > > > > > > =-=-= > > Notice: The information contained in this e-mail message and/or > > attachments to it may contain confidential or privileged information. > > If you are not the intended recipient, any dissemination, use, review, > > distribution, printing or copying of the information contained in this > > e-mail message and/or attachments to it are strictly prohibited. If > > you have received this communication in error, please notify us by > > reply e-mail or telephone and immediately and permanently delete the > > message and any attachments. Thank you > > > > > > > > ___ > > 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 ** This message is confidential and intended only for the addressee. If you have received this message in error, please immediately notify the postmas...@nds.com and delete it from your system as well as any copies. The content of e-mails as well as traffic data may be monitored by NDS for employment and security purposes. To protect the environment please do not print this e-mail unless necessary. NDS Limited. Registered Office: One London Road, Staines, Middlesex, TW18 4EX, United Kingdom. A company registered in England and Wales. Registered no. 3080780. VAT no. GB 603 8808 40-00 ** ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users
[rules-users] Decision table multiple sheets...
Hi, I am having my rules in a Decision Table (.xls) There I have 3 sheets for rules. Like in Sheet1 there are two Rule Tables... In Sheet2 there are 2 and in Sheet3 there is only 1. When I am creating the knowledgebase and firing rules, the rules that are in the Sheet1 are getting fired. But the rules in other sheets are not getting fired. When I convert them to String to check using this code : String str = DecisionTableFactory.loadFromInputStream (ResourceFactory.newClassPathResource ("com/sample/MemberDiscountRules.xls").getInputStream(), dtconf); System.out.println(str); I can see the rules that are present in Sheet1 only. Please anybody help me on this. How can I get the rules in other two sheets to get fired. Also how can we fire the rules of only a particular Rule table in the decision table. Thanks & Regards, Sumeet Mailto: sumeet.kara...@tcs.com =-=-= Notice: The information contained in this e-mail message and/or attachments to it may contain confidential or privileged information. If you are not the intended recipient, any dissemination, use, review, distribution, printing or copying of the information contained in this e-mail message and/or attachments to it are strictly prohibited. If you have received this communication in error, please notify us by reply e-mail or telephone and immediately and permanently delete the message and any attachments. Thank you ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users
Re: [rules-users] jbpm 3.2.x verssion .....
Its ok Mauricio, I didn't find it harsh at all, thanks for the help. :) Regards, Sumeet From: Mauricio Salatino To: marco.rietv...@redhat.com, Rules Users List Cc: Sumeet Karawal Date: 11/14/2011 06:35 PM Subject:Re: [rules-users] jbpm 3.2.x verssion . Sumeet, Marco, Sorry I didn't want to be harsh with my response :) Cheers 2011/11/14 Marco Rietveld Summeet (and others), As mentioned, this is indeed a drools (user) mailing list. The proper mailing lists for jbpm (3, 4 or 5) are: jbpm-us...@lists.jboss.org (for these types of questions) jbpm-us...@lists.jboss.org (for developers and people who look at jbpm code/internals) Most of the jbpm core developers monitor both lists. Thanks, Marco 11/14/2011 02:00 PM, Marco Rietveld: Hi Summeet, jbpm 3.2.x works with jBoss AS 5.1 -- and obviously also with Drools 5.3, since there's no overlap between those two versions of jbpm and drools. I'm not sure if Drools 5.3 works with jBoss AS 5.1, although I think it does. There is a difference between jbpm 3.2.8 and the supported version of jbpm 3.2. It's hard to quantify the difference exactly, but since late 2009 when 3.2.8 was released, a number of bugs have been fixed in the supported version. . Marco 11/11/2011 10:39 AM, Sumeet Karawal: Thanks Thomas No, I am a little confused which version to use. I visited the site http://sourceforge.net/projects/jbpm/files/jBPM%203/. Here the maximum downloads are for v 3.2.2 and the latest among these is v3.2.8. It would be very helpful if you could suggest me which one to use among the versions 3.2.x. As my requirement is to use jbpm v3.2.x with Drools and Jboss AS, and later on Mule ESB v3.1 will also be used. So I am thinking of installing jbpm among v3.2.x with Drools v5.3 Final and JBoss AS v 5.1. Will these components work together? Also, jbpm Enterprise Supports v3. So is there much difference between the enterprise version of jbpm v3 and the community versions of v3.2.x Thanks & Regards, Sumeet Karawal Mailto: sumeet.kara...@tcs.com -- jBPM/Drools developer Utrecht, the Netherlands -- jBPM/Drools developer Utrecht, the Netherlands ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users -- - CTO @ http://www.plugtree.com - MyJourney @ http://salaboy.wordpress.com - Co-Founder @ http://www.jugargentina.org - Co-Founder @ http://www.jbug.com.ar - Salatino "Salaboy" Mauricio - =-=-= Notice: The information contained in this e-mail message and/or attachments to it may contain confidential or privileged information. If you are not the intended recipient, any dissemination, use, review, distribution, printing or copying of the information contained in this e-mail message and/or attachments to it are strictly prohibited. If you have received this communication in error, please notify us by reply e-mail or telephone and immediately and permanently delete the message and any attachments. Thank you ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users
[rules-users] Fw: jbpm 3.2.x verssion .....
Hi, I have to meet an urgent requirement and not getting any information regarding which of these version is stable. Could any body please help me on this. Is it better to use jbpm v 3.2.2 or jbpm v 3.2.8 with Drools v5.3 and JBoss AS v5.1. or any other version of jbpm among v3.2.x Thanks & Regards, Sumeet Karawal Mailto: sumeet.kara...@tcs.com - Forwarded by Sumeet Karawal/MUM/TCS on 11/11/2011 11:16 PM - From: Sumeet Karawal To: Rules Users List Date: 11/11/2011 03:11 PM Subject:Re: [rules-users] jbpm 3.2.x verssion . Sent by:rules-users-boun...@lists.jboss.org Thanks Thomas No, I am a little confused which version to use. I visited the site http://sourceforge.net/projects/jbpm/files/jBPM%203/. Here the maximum downloads are for v 3.2.2 and the latest among these is v3.2.8. It would be very helpful if you could suggest me which one to use among the versions 3.2.x. As my requirement is to use jbpm v3.2.x with Drools and Jboss AS, and later on Mule ESB v3.1 will also be used. So I am thinking of installing jbpm among v3.2.x with Drools v5.3 Final and JBoss AS v 5.1. Will these components work together? Also, jbpm Enterprise Supports v3. So is there much difference between the enterprise version of jbpm v3 and the community versions of v3.2.x Thanks & Regards, Sumeet Karawal Mailto: sumeet.kara...@tcs.com From: "Swindells, Thomas" To: Rules Users List Date: 11/11/2011 02:56 PM Subject:Re: [rules-users] jbpm 3.2.x verssion . Sent by:rules-users-boun...@lists.jboss.org It's java. As long as you have a compatible JVM then it should run. Have you encountered any problems using it? Thomas > -Original Message- > From: rules-users-boun...@lists.jboss.org [mailto:rules-users- > boun...@lists.jboss.org] On Behalf Of Sumeet Karawal > Sent: 11 November 2011 09:12 > To: rules-users@lists.jboss.org > Subject: [rules-users] jbpm 3.2.x verssion . > > > Hi, > > Can any body let me know whether jbpm v 3.2.8 is compatible with sun > solaris. If not then which of the versions among v3.2.x is compatible with it. > As I have to install it in both Windows and Sun Solaris. > > > Thanks in advance, > Sumeet Karawal > Mailto: sumeet.kara...@tcs.com > > =-=-= > Notice: The information contained in this e-mail message and/or > attachments to it may contain confidential or privileged information. If you > are not the intended recipient, any dissemination, use, review, distribution, > printing or copying of the information contained in this e-mail message > and/or attachments to it are strictly prohibited. If you have received this > communication in error, please notify us by reply e-mail or telephone and > immediately and permanently delete the message and any attachments. > Thank you > > > > ___ > rules-users mailing list > rules-users@lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users ** This message is confidential and intended only for the addressee. If you have received this message in error, please immediately notify the postmas...@nds.com and delete it from your system as well as any copies. The content of e-mails as well as traffic data may be monitored by NDS for employment and security purposes. To protect the environment please do not print this e-mail unless necessary. NDS Limited. Registered Office: One London Road, Staines, M
Re: [rules-users] jbpm 3.2.x verssion .....
Thanks Thomas No, I am a little confused which version to use. I visited the site http://sourceforge.net/projects/jbpm/files/jBPM%203/. Here the maximum downloads are for v 3.2.2 and the latest among these is v3.2.8. It would be very helpful if you could suggest me which one to use among the versions 3.2.x. As my requirement is to use jbpm v3.2.x with Drools and Jboss AS, and later on Mule ESB v3.1 will also be used. So I am thinking of installing jbpm among v3.2.x with Drools v5.3 Final and JBoss AS v 5.1. Will these components work together? Also, jbpm Enterprise Supports v3. So is there much difference between the enterprise version of jbpm v3 and the community versions of v3.2.x Thanks & Regards, Sumeet Karawal Mailto: sumeet.kara...@tcs.com From: "Swindells, Thomas" To: Rules Users List Date: 11/11/2011 02:56 PM Subject:Re: [rules-users] jbpm 3.2.x verssion . Sent by:rules-users-boun...@lists.jboss.org It's java. As long as you have a compatible JVM then it should run. Have you encountered any problems using it? Thomas > -Original Message- > From: rules-users-boun...@lists.jboss.org [mailto:rules-users- > boun...@lists.jboss.org] On Behalf Of Sumeet Karawal > Sent: 11 November 2011 09:12 > To: rules-users@lists.jboss.org > Subject: [rules-users] jbpm 3.2.x verssion . > > > Hi, > > Can any body let me know whether jbpm v 3.2.8 is compatible with sun > solaris. If not then which of the versions among v3.2.x is compatible with it. > As I have to install it in both Windows and Sun Solaris. > > > Thanks in advance, > Sumeet Karawal > Mailto: sumeet.kara...@tcs.com > > =-=-= > Notice: The information contained in this e-mail message and/or > attachments to it may contain confidential or privileged information. If you > are not the intended recipient, any dissemination, use, review, distribution, > printing or copying of the information contained in this e-mail message > and/or attachments to it are strictly prohibited. If you have received this > communication in error, please notify us by reply e-mail or telephone and > immediately and permanently delete the message and any attachments. > Thank you > > > > ___ > rules-users mailing list > rules-users@lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users ** This message is confidential and intended only for the addressee. If you have received this message in error, please immediately notify the postmas...@nds.com and delete it from your system as well as any copies. The content of e-mails as well as traffic data may be monitored by NDS for employment and security purposes. To protect the environment please do not print this e-mail unless necessary. NDS Limited. Registered Office: One London Road, Staines, Middlesex, TW18 4EX, United Kingdom. A company registered in England and Wales. Registered no. 3080780. VAT no. GB 603 8808 40-00 ** ___ 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] jbpm 3.2.x verssion .....
Hi, Can any body let me know whether jbpm v 3.2.8 is compatible with sun solaris. If not then which of the versions among v3.2.x is compatible with it. As I have to install it in both Windows and Sun Solaris. Thanks in advance, Sumeet Karawal Mailto: sumeet.kara...@tcs.com =-=-= Notice: The information contained in this e-mail message and/or attachments to it may contain confidential or privileged information. If you are not the intended recipient, any dissemination, use, review, distribution, printing or copying of the information contained in this e-mail message and/or attachments to it are strictly prohibited. If you have received this communication in error, please notify us by reply e-mail or telephone and immediately and permanently delete the message and any attachments. Thank you ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users
Re: [rules-users] Regarding BPEL
Thank you. This was really helpful. Regards, Sumeet Mailto: sumeet.kara...@tcs.com From: Mauricio Salatino To: Rules Users List Date: 10/21/2011 04:15 PM Subject:Re: [rules-users] Regarding BPEL Sent by:rules-users-boun...@lists.jboss.org Definitely we are not in the same page :) BPMN is also a semi-structured language to define business processes (BP from BPEL and BPMN). The version 2 of the standard defines the language and the execution semantic for defining Business Processes with a wider scope than BPEL. Of course that BPEL and BPMN are not the same, but I think that you can achieve most of the things that you want to achieve with BPEL with BPMN (I'm not sure what are you trying to achieve, but we can discuss that in another thread). In the case of BPMN, Drools is not the one responsible for the process execution and jBPM5 is. Where jBPM5 is right now a former module of the Drools Project. jBPM5 provides you a generic process engine capable of understanding more than one process definition language, but right now the project is focused on running BPMN models. In other words, jBPM5 is capable of running BPEL process, but right now the parsers for the BPEL models are not in place. Most of the BPMS vendors are adopting BPMN as a defacto notation and I think that for that reason jBPM5 is only focused in this language now. Hope it helps.. Cheers On Thu, Oct 20, 2011 at 2:18 PM, Jamie wrote: I'm not sure your answer directly addresses the question. BPMN and BPEL aren't the same thing - BPMN is an unstructured diagramming notation that an be directly executed from within Drools, where as BPEL is a semi-structured language. While most BPMN flows can be translated to BPEL, not everything in BPMN can be represented in BPEL. I don't believe that Drools can directly execute BPEL (but I'm sure others will correct me if I'm wrong about that) -- View this message in context: http://drools.46999.n3.nabble.com/rules-users-Regarding-BPEL-tp3437430p3438367.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 -- - CTO @ http://www.plugtree.com - MyJourney @ http://salaboy.wordpress.com - Co-Founder @ http://www.jugargentina.org - Co-Founder @ http://www.jbug.com.ar - Salatino "Salaboy" Mauricio - ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users =-=-= Notice: The information contained in this e-mail message and/or attachments to it may contain confidential or privileged information. If you are not the intended recipient, any dissemination, use, review, distribution, printing or copying of the information contained in this e-mail message and/or attachments to it are strictly prohibited. If you have received this communication in error, please notify us by reply e-mail or telephone and immediately and permanently delete the message and any attachments. Thank you ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users
[rules-users] Regarding BPEL
Hi, I required some information whether jBPM supports BPEL. I searched and found something regarding its use in jBPM v3.x. But got nothing regarding BPEL for versions 4.x and 5.x. Is jBPM compatible with BPEL or is there anyway to have BPEL functionality with jBPM. jBPM creates the process using JPDL. Is it better in someway or the other than BPEL ? Could anybody please help me on this. Thanks & Regards, Sumeet Karawal Mailto: sumeet.kara...@tcs.com =-=-= Notice: The information contained in this e-mail message and/or attachments to it may contain confidential or privileged information. If you are not the intended recipient, any dissemination, use, review, distribution, printing or copying of the information contained in this e-mail message and/or attachments to it are strictly prohibited. If you have received this communication in error, please notify us by reply e-mail or telephone and immediately and permanently delete the message and any attachments. Thank you ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users
[rules-users] Fw: Guvnor Sample Rule
Hi For this I saved the schema (change-set-1.0.0.xsd) on my local machine and gave the path in the ChangeSet.xml Now its working fine... Regards, Sumeet Karawal Mailto: sumeet.kara...@tcs.com - Forwarded by Sumeet Karawal/MUM/TCS on 08/22/2011 03:44 PM - From: Sumeet Karawal To: rules-users@lists.jboss.org Date: 08/18/2011 06:24 PM Subject:[rules-users] Guvnor Sample Rule Sent by:rules-users-boun...@lists.jboss.org Hi, I am trying to create rule in Guvnor and runnig it in Java Application on Eclipse. I have gone through the mortgages example provided in the distribution. I am not sure that I am doing it correctly The steps I did are as follows : 1) Uploaded a POJO jar in Guvnor 2) Created a rule for checking the value of POJO data member 3) Built the package 4) Downloaded the ChangeSet.xml provided 5) Imported that ChangeSet.xml in Eclipse project under com.test package. 6) Created KnowledgeBase and fired the rules My POJO : package com.test; public class CardHolder { private int accno; private double discount; public int getAccno() { return accno; } public void setAccno(int accno) { this.accno = accno; } public double getDiscount() { return discount; } public void setDiscount(double discount) { this.discount = discount; } } My Rule Running Class : package com.test; import org.drools.KnowledgeBase; import org.drools.agent.KnowledgeAgent; import org.drools.agent.KnowledgeAgentFactory; import org.drools.io.Resource; import org.drools.io.ResourceFactory; import org.drools.runtime.StatefulKnowledgeSession; public class Discount_Provider { public static void main(String[] args) { CardHolder c1 = new CardHolder(); c1.setAccno(1005); try{ KnowledgeBase kbase = readKnowledgeBase(); StatefulKnowledgeSession ksession = kbase.newStatefulKnowledgeSession(); ksession.insert(c1); ksession.fireAllRules(); System.out.println("The discount applied is : "+ c1.getDiscount()); } catch (Exception ex) { System.out.println("Exception is : "+ex); } } private static KnowledgeBase readKnowledgeBase() { KnowledgeAgent kagent = KnowledgeAgentFactory.newKnowledgeAgent ("DiscAgent"); Resource changeset = ResourceFactory.newClassPathResource ("com/test/ChangeSet.xml"); kagent.applyChangeSet(changeset); KnowledgeBase kbase = kagent.getKnowledgeBase(); kagent.dispose(); return kbase; } } My Rule Content : 1.|rule "Discount_CardHolder" 2.|dialect "mvel" 3.|when 4.|$c : CardHolder( accno > 1001 ) 5.|then 6.|$c.setDiscount( 10 ); 7.|update( $c ); 8.|end Link from where I download the ChangeSet from Guvnor : Change Set: |> | http://localhost:8080
[rules-users] Guvnor Sample Rule
Hi, I am trying to create rule in Guvnor and runnig it in Java Application on Eclipse. I have gone through the mortgages example provided in the distribution. I am not sure that I am doing it correctly The steps I did are as follows : 1) Uploaded a POJO jar in Guvnor 2) Created a rule for checking the value of POJO data member 3) Built the package 4) Downloaded the ChangeSet.xml provided 5) Imported that ChangeSet.xml in Eclipse project under com.test package. 6) Created KnowledgeBase and fired the rules My POJO : package com.test; public class CardHolder { private int accno; private double discount; public int getAccno() { return accno; } public void setAccno(int accno) { this.accno = accno; } public double getDiscount() { return discount; } public void setDiscount(double discount) { this.discount = discount; } } My Rule Running Class : package com.test; import org.drools.KnowledgeBase; import org.drools.agent.KnowledgeAgent; import org.drools.agent.KnowledgeAgentFactory; import org.drools.io.Resource; import org.drools.io.ResourceFactory; import org.drools.runtime.StatefulKnowledgeSession; public class Discount_Provider { public static void main(String[] args) { CardHolder c1 = new CardHolder(); c1.setAccno(1005); try{ KnowledgeBase kbase = readKnowledgeBase(); StatefulKnowledgeSession ksession = kbase.newStatefulKnowledgeSession(); ksession.insert(c1); ksession.fireAllRules(); System.out.println("The discount applied is : "+ c1.getDiscount()); } catch (Exception ex) { System.out.println("Exception is : "+ex); } } private static KnowledgeBase readKnowledgeBase() { KnowledgeAgent kagent = KnowledgeAgentFactory.newKnowledgeAgent ("DiscAgent"); Resource changeset = ResourceFactory.newClassPathResource ("com/test/ChangeSet.xml"); kagent.applyChangeSet(changeset); KnowledgeBase kbase = kagent.getKnowledgeBase(); kagent.dispose(); return kbase; } } My Rule Content : 1.|rule "Discount_CardHolder" 2.|dialect "mvel" 3.|when 4.|$c : CardHolder( accno > 1001 ) 5.|then 6.|$c.setDiscount( 10 ); 7.|update( $c ); 8.|end Link from where I download the ChangeSet from Guvnor : Change Set: |> |http://localhost:8080/drools-guvnor/org.drools.guvnor.Guvnor/package/TestPackage/LATEST/ChangeSet.xml | |> >-| |(Embedded| |image moved | |to file: | |pic19477.gif)| >-| Contents of ChangeSet.xml : Errors that I get : (null: 3, 175): schema_reference.4: Failed to read schema document 'http://anonsvn.jboss.org/repos/labs/labs/jbossrules/trunk/drools-api/src/main/resources/change-set-1.0.0.xsd', because 1) could not find the document; 2) the document could not be read; 3) the root element of the document is not . (null: 3, 175): cvc-elt.1: Cannot find the declaration of element 'change-set'. (null: 4, 10): schema_reference.4: Failed to read schema document 'http://anonsvn.jboss.org/repos/labs/labs/jbossrules/trunk/drools-api/src/main/resources/change-set-1.0.0.xsd', because 1) could not find the document; 2) the document could not be read; 3) the root element of the document is not . (null: 5, 130): schema_reference.4: Failed to read schema document 'http://anonsvn.jboss.org/repos/labs/labs/jbossrules/trunk/drools-api/src/main/resources/change-set-1.0.0.xsd', because 1) could not find the document; 2) the document could not be read; 3) the root element of the document is not . The discount applied is : 0.0 I am not able to get what should be done to make it run properly. Earlier also I had tried to do this but faced many issues. By referring the Mortgages example I tried to create the calling class. It would be very helpful if some body could help me on this. Thanks & Regards, Sumeet Mailto: sumeet.kara...@tcs.com =-=-= Notice: The information contained in this e-mail message and/or attachments to it may contain confidential or privileged information. If you are not the intended recipient, any dissemination, use, review, distribution, printing or copying of the information contained in this e-mail message and/or attachments to it are strictly prohibited. If you have received this communication in error, please notify us by r
Re: [rules-users] Rule Flow in Guvnor 5.2
Thanks Tihomir. I have installed the designer for Guvnor and have started referencing to the links provided by you. But I have small query : In the rule flow we could design an order in which the rules would be fired. Will that be possible using BPMN 2.0 process? Aslo if the user wants to make the changes to the flow, then can these changes be done on the fly? Thanks & Regards, Sumeet Mailto: sumeet.kara...@tcs.com From: Tihomir Surdilovic To: rules-users@lists.jboss.org Date: 08/12/2011 08:07 PM Subject:Re: [rules-users] Rule Flow in Guvnor 5.2 Sent by:rules-users-boun...@lists.jboss.org Hi Sumeet, jBPM5 allows you to execute processes defined using the BPMN 2.0 XML format (see more in docs http://docs.jboss.org/jbpm/v5.1/userguide/ch06.html). It is the default format in jBPM5 and our web tooling support focuses on creating/editing BPMN 2.0 processes. To get started with this, please reference docs: https://hudson.jboss.org/hudson/job/jBPM/lastSuccessfulBuild/artifact/jbpm-distribution/target/jbpm-5.2.0-SNAPSHOT-docs-build/jbpm-docs/html/ch10.html and several blogs+videos: http://blog.athico.com/search?q=oryx. If you use the jBPM-installer ( http://docs.jboss.org/jbpm/v5.1/userguide/ch03.html) it will help you set everything up for the demo setup. I would strongly suggest converting your processes to BPMN 2.0 since .rfm is considered legacy at this point and will AFAIK receive no more development attention. You are also always welcome to ask questions regarding the jBPM Web Designer on IRC (http://www.jboss.org/jbpm/irc) as well as user forum ( http://community.jboss.org/en/jbpm?view=discussions). Hope this helps. Tihomir On 8/12/11 9:14 AM, Sumeet Karawal wrote: Hi, Is there a possibility that we can create/edit a RuleFlow in Guvnor 5.2. I have read the documents where it mentions the creation of Rule Flow in Eclipse IDE and then importing the .rfm file in Guvnor, is there a way that we can have the whole functionality of creating/editing Ruleflow in Guvnor only. I searched for it and found something related to Orxy designer but not able to get the whole thing. Can anybody help me on this. Thanks & Regards, Sumeet Mailto: sumeet.kara...@tcs.com =-=-= Notice: The information contained in this e-mail message and/or attachments to it may contain confidential or privileged information. If you are not the intended recipient, any dissemination, use, review, distribution, printing or copying of the information contained in this e-mail message and/or attachments to it are strictly prohibited. If you have received this communication in error, please notify us by reply e-mail or telephone and immediately and permanently delete the message and any attachments. Thank you ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users
[rules-users] Rule Flow in Guvnor 5.2
Hi, Is there a possibility that we can create/edit a RuleFlow in Guvnor 5.2. I have read the documents where it mentions the creation of Rule Flow in Eclipse IDE and then importing the .rfm file in Guvnor, is there a way that we can have the whole functionality of creating/editing Ruleflow in Guvnor only. I searched for it and found something related to Orxy designer but not able to get the whole thing. Can anybody help me on this. Thanks & Regards, Sumeet Mailto: sumeet.kara...@tcs.com =-=-= Notice: The information contained in this e-mail message and/or attachments to it may contain confidential or privileged information. If you are not the intended recipient, any dissemination, use, review, distribution, printing or copying of the information contained in this e-mail message and/or attachments to it are strictly prohibited. If you have received this communication in error, please notify us by reply e-mail or telephone and immediately and permanently delete the message and any attachments. Thank you ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users
Re: [rules-users] Calling a method in when part
Hi, Below is the drl that I am using and the class that it is referring to: Drl: package rules.person import com.person.Age Import com.person.Classification rule "Check_person.option1" when $age : com.person.Age() $classification : com.person.Classification() eval ($age.getClassification("16")) then modify ($classification) {$classification.setResult('"Teenager"; } end rule "Check_person.option2" when $age : com.person.Age() $classification : com.person.Classification() eval ($age.getClassification("40")) then modify ($classification) {$classification.setResult('"Adult"; } end Application Class : public class Age { public string getClassification(String name) { return str; } } public class Classification { public void setResult(String name) { } } Queries : Please let me know if I am using the 'when' part correctly. And please check for the use of the object 'classification' in my application (as return value to the application) Thanks & Regards, Sumeet Karawal Mailto: sumeet.kara...@tcs.com From: Wolfgang Laun To: Rules Users List Date: 08/10/2011 03:03 PM Subject:Re: [rules-users] Calling a method in when part Sent by:rules-users-boun...@lists.jboss.org If you don't show your code we can't tell you what is wrong with it. So I think what you may have to do is when $someObj: SomeClass() # matches each WME of SomeClass eval( $someObj.getValueBoolean("abc")) then There is not much to be gained by using a DRL function; it would have to be called like eval( someFunction( $someObj, "abc" ) ) -W On 10 August 2011 11:05, Sumeet Karawal wrote: Hi, I have a requirement where there is a customized Java class having a method that returns some value. like: getValueBoolean("Some String") { //some calculation // returns a boolean value } The default getters and setters are not being used in the Application. The value that is being returned by the method needs to be checked in the .drl file. There are different Java classes with these kind of methods. Where the string and integer value is also returned. I have gone through the documentation for Drools-Expert but have only found the implementation for the method in the consequence part, i.e., the then part. This is how I tried: importing the class in when binding the a variable to the Class name suppose $c eval ($c.getValueBoolean("abc")) then System.out.println("the value is true") It didn't work this way. I tried by another way like : creating a function in the .drl itself that calls the method of that class and returns a value then calling this drl function in the when part and carrying on. It would be very helpful if some body could let me know how to do this in the .drl. Thanks & Regards, Sumeet Karawal Mailto: sumeet.kara...@tcs.com =-=-= Notice: The information contained in this e-mail message and/or attachments to it may contain confidential or privileged information. If you are not the intended recipient, any dissemination, use, review, distribution, printing or copying of the information contained in this e-mail message and/or attachments to it are strictly prohibited. If you have received this communication in error, please notify us by reply e-mail or telephone and immediately and permanently delete the message and any attachments. Thank you ___ rules-users mailing
[rules-users] Calling a method in when part
Hi, I have a requirement where there is a customized Java class having a method that returns some value. like: getValueBoolean("Some String") { //some calculation // returns a boolean value } The default getters and setters are not being used in the Application. The value that is being returned by the method needs to be checked in the .drl file. There are different Java classes with these kind of methods. Where the string and integer value is also returned. I have gone through the documentation for Drools-Expert but have only found the implementation for the method in the consequence part, i.e., the then part. This is how I tried: importing the class in when binding the a variable to the Class name suppose $c eval ($c.getValueBoolean("abc")) then System.out.println("the value is true") It didn't work this way. I tried by another way like : creating a function in the .drl itself that calls the method of that class and returns a value then calling this drl function in the when part and carrying on. It would be very helpful if some body could let me know how to do this in the .drl. Thanks & Regards, Sumeet Karawal Mailto: sumeet.kara...@tcs.com =-=-= Notice: The information contained in this e-mail message and/or attachments to it may contain confidential or privileged information. If you are not the intended recipient, any dissemination, use, review, distribution, printing or copying of the information contained in this e-mail message and/or attachments to it are strictly prohibited. If you have received this communication in error, please notify us by reply e-mail or telephone and immediately and permanently delete the message and any attachments. Thank you ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users
Re: [rules-users] Java 1.4 Application
Thanks for the reply. Actually I have to work on an Application that is based on Java 1.4 and there haven't been any major changes in the code, currently business logic is managed through Java code only. But now we are trying to have a rule engine for the purpose. There will be a migration to Java 6 but not in the near future. Regards, Sumeet Karawal Mailto: sumeet.kara...@tcs.com From: "Swindells, Thomas" To: Rules Users List Date: 08/01/2011 01:09 PM Subject:Re: [rules-users] Java 1.4 Application Sent by:rules-users-boun...@lists.jboss.org Any reason why you are still on java 1.4? You are using a java version that is now 3 major versions out of date and that hasn't been supported by sun/oracle for the last 3 years! It's the equivalent of still using windows 98! Thomas > -Original Message- > From: rules-users-boun...@lists.jboss.org [mailto:rules-users- > boun...@lists.jboss.org] On Behalf Of DroolersEye > Sent: 27 July 2011 17:06 > To: rules-users@lists.jboss.org > Subject: Re: [rules-users] Java 1.4 Application > > > Drools5 works with JDK1.5 and above. > > Drools 5.0 will split up into 4 main sub projects, > > Drools Guvnor (BRMS/BPMS) > > Drools Expert (rule engine), > > Drools Flow (process/workflow) > > Drools Fusion (cep/temporal reasoning) > > the above projects are not available in drools 4.0 except drools rule engine > even drools expert 5.x is a major update over the previous Drools 4. > Drools4 works fine with jdk 1.4. > selecting drools 4.version based on the jdk version may not be good idea, we > may lose lots of advanced functionalities provided by drools current versions. > Current version is 5.2 Final (Auguest 2011 Mark team going to release 5.3). > > > - > with kind regards, > > -- > View this message in context: http://drools.46999.n3.nabble.com/rules- > users-Java-1-4-Application-tp3199965p3203906.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 ** This message is confidential and intended only for the addressee. If you have received this message in error, please immediately notify the postmas...@nds.com and delete it from your system as well as any copies. The content of e-mails as well as traffic data may be monitored by NDS for employment and security purposes. To protect the environment please do not print this e-mail unless necessary. NDS Limited. Registered Office: One London Road, Staines, Middlesex, TW18 4EX, United Kingdom. A company registered in England and Wales. Registered no. 3080780. VAT no. GB 603 8808 40-00 ** ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users =-=-= Notice: The information contained in this e-mail message and/or attachments to it may contain confidential or privileged information. If you are not the intended recipient, any dissemination, use, review, distribution, printing or copying of the information contained in this e-mail message and/or attachments to it are strictly prohibited. If you have received this communication in error, please notify us by reply e-mail or telephone and immediately and permanently delete the message and any attachments. Thank you ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users
[rules-users] Java 1.4 Application
Hi All, I have to use Drools in a Java Application with Java version 1.4 Can I use Drools 5.0 for that or do I have to use Drools 4.0.x version? Please help me on this. Thanks & Regards Sumeet Karawal Mailto: sumeet.kara...@tcs.com =-=-= Notice: The information contained in this e-mail message and/or attachments to it may contain confidential or privileged information. If you are not the intended recipient, any dissemination, use, review, distribution, printing or copying of the information contained in this e-mail message and/or attachments to it are strictly prohibited. If you have received this communication in error, please notify us by reply e-mail or telephone and immediately and permanently delete the message and any attachments. Thank you ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users
Re: [rules-users] Guvnor Rules!!!
I downloaded from the link, but I am not able to find the mortgages example there. Thanks & Regards, Sumeet Karawal From: Michael Anstis To: Rules Users List Date: 06/23/2011 03:19 PM Subject:Re: [rules-users] Guvnor Rules!!! Sent by:rules-users-boun...@lists.jboss.org Have you looked at the "mortgages" example under the "examples" folder in the guvnor-distribution; http://download.jboss.org/drools/release/5.2.0.CR1/drools-distribution-5.2.0.CR1.zip ? There is a similar example for 5.1, but TBH I'm not sure of the location in either the download or internet. 2011/6/22 Sumeet Karawal Hi, I am not able to run Guvnor rules on eclipse. I have read the Knowledge Agent part from the user guide but not able to get through. I am doing the following steps: I have created a Java class in eclipse and exported it as a .jar file. Then I import it in Guvnor under the upload POJO Model. I create some rules for it Then I build the package and get the following URLs : URL for package documentation: http://localhost:8080/drools-guvnor/org.drools.guvnor.Guvnor/package/com.JBoss/LATEST/documentation.pdf (Embedded image moved to file: pic32197.gif) URL for package source: http://localhost:8080/drools-guvnor/org.drools.guvnor.Guvnor/package/com.JBoss/LATEST.drl (Embedded image moved to file: pic02151.gif) URL for package binary: http://localhost:8080/drools-guvnor/org.drools.guvnor.Guvnor/package/com.JBoss/LATEST (Embedded image moved to file: pic18827.gif) URL for running tests: http://localhost:8080/drools-guvnor/org.drools.guvnor.Guvnor/package/com.JBoss/LATEST/SCENARIOS (Embedded image moved to file: pic20956.gif) Change Set: http://localhost:8080/drools-guvnor/org.drools.guvnor.Guvnor/package/com.JBoss/LATEST/ChangeSet.xml (Embedded image moved to file: pic21205.gif) I have gone through use of KnowledgeAgent in the user guide but not getting how to do it. I mean what code should I write to get the KnowledgeBase from these URLs. It would be really helpful if someone could guide me on this. Thanks & Regards, Sumeet Karawal Mailto: sumeet.kara...@tcs.com =-=-= Notice: The information contained in this e-mail message and/or attachments to it may contain confidential or privileged information. If you are not the intended recipient, any dissemination, use, review, distribution, printing or copying of the information contained in this e-mail message and/or attachments to it are strictly prohibited. If you have received this communication in error, please notify us by reply e-mail or telephone and immediately and permanently delete the message and any attachments. Thank you ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users
[rules-users] Guvnor Rules!!!
Hi, I am not able to run Guvnor rules on eclipse. I have read the Knowledge Agent part from the user guide but not able to get through. I am doing the following steps: I have created a Java class in eclipse and exported it as a .jar file. Then I import it in Guvnor under the upload POJO Model. I create some rules for it Then I build the package and get the following URLs : URL for package documentation: http://localhost:8080/drools-guvnor/org.drools.guvnor.Guvnor/package/com.JBoss/LATEST/documentation.pdf (Embedded image moved to file: pic32197.gif) URL for package source: http://localhost:8080/drools-guvnor/org.drools.guvnor.Guvnor/package/com.JBoss/LATEST.drl (Embedded image moved to file: pic02151.gif) URL for package binary: http://localhost:8080/drools-guvnor/org.drools.guvnor.Guvnor/package/com.JBoss/LATEST (Embedded image moved to file: pic18827.gif) URL for running tests: http://localhost:8080/drools-guvnor/org.drools.guvnor.Guvnor/package/com.JBoss/LATEST/SCENARIOS (Embedded image moved to file: pic20956.gif) Change Set: http://localhost:8080/drools-guvnor/org.drools.guvnor.Guvnor/package/com.JBoss/LATEST/ChangeSet.xml (Embedded image moved to file: pic21205.gif) I have gone through use of KnowledgeAgent in the user guide but not getting how to do it. I mean what code should I write to get the KnowledgeBase from these URLs. It would be really helpful if someone could guide me on this. Thanks & Regards, Sumeet Karawal Mailto: sumeet.kara...@tcs.com =-=-= Notice: The information contained in this e-mail message and/or attachments to it may contain confidential or privileged information. If you are not the intended recipient, any dissemination, use, review, distribution, printing or copying of the information contained in this e-mail message and/or attachments to it are strictly prohibited. If you have received this communication in error, please notify us by reply e-mail or telephone and immediately and permanently delete the message and any attachments. Thank you <><><><><>___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users
Re: [rules-users] Exposing rules as services
Hi, Thanks Xinhua!!! Here I am able to get that using drools server, we could expose the knowledgebases as RESTful services, and those could be consumed by the Application. As in the normal application, we create a Knowledgebase, then session and insert facts,. after that we fireAllRules(); So will the procedure be same in this case, to insert fact,creating knowledgebases and firing rules. Also can't we expose the rules as SOAP services? Actually I have never come across using rules as services. But in the new implementation I have this requirement. So, I am totally confused on how to go ahead, how to actually do this. Thanks for the help... Regards, Sumeet Karawal Mailto: sumeet.kara...@tcs.com From: Xinhua Zhu To: Rules Users List Date: 06/09/2011 11:55 AM Subject:Re: [rules-users] Exposing rules as services Sent by:rules-users-boun...@lists.jboss.org Hi, Maybe this link can be helpful. http://docs.jboss.org/drools/release/5.2.0.CR1/droolsjbpm-integration-docs/html_single/index.html#d0e488 BR Xinhua On Thu, Jun 9, 2011 at 4:02 PM, Sumeet Karawal wrote: Is there any documentation available regarding that or any link that I could refer. It would be really helpful if I get an idea on how to proceed further. Thanks & Regards, Sumeet Karawal Mailto: sumeet.kara...@tcs.com From: Xinhua Zhu To: Rules Users List Date: 06/09/2011 05:51 AM Subject: Re: [rules-users] Exposing rules as services Sent by: rules-users-boun...@lists.jboss.org Hi, You can have a look at drools server. BR Xinhua On Wed, Jun 8, 2011 at 11:38 PM, Sumeet Karawal wrote: Hi, I am using Drools Guvnor to maintain the rule sets. I need to publish the rules as stand-alone web services. Is it possible to do that? How can this be done... Thanks and regards, Sumeet Karawal Mailto: sumeet.kara...@tcs.com =-=-= Notice: The information contained in this e-mail message and/or attachments to it may contain confidential or privileged information. If you are not the intended recipient, any dissemination, use, review, distribution, printing or copying of the information contained in this e-mail message and/or attachments to it are strictly prohibited. If you have received this communication in error, please notify us by reply e-mail or telephone and immediately and permanently delete the message and any attachments. Thank you ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users ___ 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] Exposing rules as services
Is there any documentation available regarding that or any link that I could refer. It would be really helpful if I get an idea on how to proceed further. Thanks & Regards, Sumeet Karawal Mailto: sumeet.kara...@tcs.com From: Xinhua Zhu To: Rules Users List Date: 06/09/2011 05:51 AM Subject:Re: [rules-users] Exposing rules as services Sent by:rules-users-boun...@lists.jboss.org Hi, You can have a look at drools server. BR Xinhua On Wed, Jun 8, 2011 at 11:38 PM, Sumeet Karawal wrote: Hi, I am using Drools Guvnor to maintain the rule sets. I need to publish the rules as stand-alone web services. Is it possible to do that? How can this be done... Thanks and regards, Sumeet Karawal Mailto: sumeet.kara...@tcs.com =-=-= Notice: The information contained in this e-mail message and/or attachments to it may contain confidential or privileged information. If you are not the intended recipient, any dissemination, use, review, distribution, printing or copying of the information contained in this e-mail message and/or attachments to it are strictly prohibited. If you have received this communication in error, please notify us by reply e-mail or telephone and immediately and permanently delete the message and any attachments. Thank you ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users
[rules-users] Exposing rules as services
Hi, I am using Drools Guvnor to maintain the rule sets. I need to publish the rules as stand-alone web services. Is it possible to do that? How can this be done... Thanks and regards, Sumeet Karawal Mailto: sumeet.kara...@tcs.com =-=-= Notice: The information contained in this e-mail message and/or attachments to it may contain confidential or privileged information. If you are not the intended recipient, any dissemination, use, review, distribution, printing or copying of the information contained in this e-mail message and/or attachments to it are strictly prohibited. If you have received this communication in error, please notify us by reply e-mail or telephone and immediately and permanently delete the message and any attachments. Thank you ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users
Re: [rules-users] Facing Problem in BRL
Hi, I am now able to run the examples (by removing the commented statements in the drools.package file). Thanks a lot for the help. But how can we create more rules in a brl . Is it possible to create more than one rule in a brl as we do in the drl file or do we have to create different brl files for different rules. Also is there a way to use the brl directly as we use drl. Like using : builder.add (ResourceFactory.newClassPathResource("com/rules/discount.brl" ),ResourceType.BRL); Thanks & Regards, Sumeet Karawal Mailto: sumeet.kara...@tcs.com From: Michael Anstis To: Rules Users List Date: 05/18/2011 03:31 PM Subject:Re: [rules-users] Facing Problem in BRL Sent by:rules-users-boun...@lists.jboss.org I just checked and when I create a new BRL rule drools.packages has the comment on a single line. I must assume there was some manual change made to introduce the error. 2011/5/18 Wolfgang Laun There is some code in 5.1.1 org/drools/eclipse/rulebuilder/editors/RuleEditor.java that creates a file "drools.package" with if ( !file.exists() ) { String defaultHeader = "//This is a package configuration file"; defaultHeader += "\n//Add imports, globals etc here which will be used by all the rule assets in this folder."; InputStream is = new ByteArrayInputStream ( defaultHeader.getBytes() ); Note the missing newline at the end of defaultHeader. -W 2011/5/18 Michael Anstis //Add imports, globals etc here which will be used by all the rule assets in this folder. should be on one line, or add another comment marker at the start of the second line, e.g.:- //Add imports, globals etc here which will be used by all the rule assets in this folder. //Add imports, globals etc here which will be used by all the rule assets // in this folder. 2011/5/18 Abhay B. Chaware I was able to reproduce your error … J try adding a new line ( enter ) after the comment in the drools.package …. Or just remove the commented line “//Add imports, globals etc here which will be used by all the rule assets in this folder.” Your rule name is getting ‘commented out’ ……… -abhay --- From: rules-users-boun...@lists.jboss.org [mailto: rules-users-boun...@lists.jboss.org] On Behalf Of Michael Anstis Sent: Wednesday, May 18, 2011 2:53 PM To: Rules Users List Subject: Re: [rules-users] Facing Problem in BRL This looks rogue:- //Add imports, globals etc here which will be used by all the rule assets in this folder Can you post the content of your drools.packages file? On 18 May 2011 10:19, Sumeet Karawal wrote: This is the output that I get : //This is a package configuration file package com.rules; import com.model.PersonDetails; //Add imports, globals etc here which will be used by all the rule assets in this folder.rule "example" dialect "mvel" when $person : PersonDetails( age < "20" ) then $person.setDiscount( 10 ); end java.lang.RuntimeException: [8,1]: [ERR 102] Line 8:1 mismatched input 'WHEN' Regards, Sumeet Karawal Mailto: sumeet.kara...@tcs.com From: "Abhay B. Chaware" To: Rules Users List Date: 05/18/2011 02:47 PM Subject: Re: [rules-users] Facing Problem in BRL Sent by: rules-users-boun...@lists.jboss.org Can you write the outputDRL to System.out and check if the generated DRL syntax is correct ? System.o
Re: [rules-users] Facing Problem in BRL
Hi All, I removed the commented lines from the drools.package file. Its now working fine. Thanks a lot!!! I was using the brl for the first time, so didn't know that the rule name was getting commented out. I used the same code to convert it into drl and pass it to package builder. Isn't there a way that we can use the ResourceType.brl instead of ResourceType.drl . like : builder.add (ResourceFactory.newClassPathResource( "com/rules/example.brl"),ResourceType.BRL); Also in a drl we can write many rules, but when we use brl do we have to create different brl files for different rules. I mean can we have more than one rule in a brl file. Thanks & Regards, Sumeet Karawal Mailto: sumeet.kara...@tcs.com From: "Abhay B. Chaware" To: Rules Users List Date: 05/18/2011 03:03 PM Subject:Re: [rules-users] Facing Problem in BRL Sent by:rules-users-boun...@lists.jboss.org I was able to reproduce your error … J try adding a new line ( enter ) after the comment in the drools.package …. Or just remove the commented line “//Add imports, globals etc here which will be used by all the rule assets in this folder.” Your rule name is getting ‘commented out’ ……… -abhay --- From: rules-users-boun...@lists.jboss.org [ mailto:rules-users-boun...@lists.jboss.org] On Behalf Of Michael Anstis Sent: Wednesday, May 18, 2011 2:53 PM To: Rules Users List Subject: Re: [rules-users] Facing Problem in BRL This looks rogue:- //Add imports, globals etc here which will be used by all the rule assets in this folder Can you post the content of your drools.packages file? On 18 May 2011 10:19, Sumeet Karawal wrote: This is the output that I get : //This is a package configuration file package com.rules; import com.model.PersonDetails; //Add imports, globals etc here which will be used by all the rule assets in this folder.rule "example" dialect "mvel" when $person : PersonDetails( age < "20" ) then $person.setDiscount( 10 ); end java.lang.RuntimeException: [8,1]: [ERR 102] Line 8:1 mismatched input 'WHEN' Regards, Sumeet Karawal Mailto: sumeet.kara...@tcs.com From: "Abhay B. Chaware" To: Rules Users List Date: 05/18/2011 02:47 PM Subject:Re: [rules-users] Facing Problem in BRL Sent by:rules-users-boun...@lists.jboss.org Can you write the outputDRL to System.out and check if the generated DRL syntax is correct ? System.out.println(outputDRL); Before instantiating KnowledgeBuilder -Original Message- From: rules-users-boun...@lists.jboss.org [ mailto:rules-users-boun...@lists.jboss.org] On Behalf Of Sumeet Karawal Sent: Wednesday, May 18, 2011 2:42 PM To: Rules Users List Subject: Re: [rules-users] Facing Problem in BRL I tried to use this also but now I am getting different error: java.lang.RuntimeException: [8,1]: [ERR 102] Line 8:1 mismatched input 'WHEN' Also, what is the significance of the first line. I have copied it as the same. My code is : String curDir = System.getProperty("user.dir"); String fileName = curDir + "\\src\\com\\rules \\drools.package"; String rulePackageContent = FileUtils.readFileToString(new File (fileName)); fileName = curDir + "\\src\\com\\rules\\example.brl"; String brl = FileUtils.readFileToString(new File (fileName)); BRLPersistence read = BRXMLPersistence.getInstance(); BRLPersistence write = BRDRLPersistence.getInstance(); String outputDRL = rulePackageContent + write.marshal (read.unmarshal (brl)); KnowledgeBuilder builder = KnowledgeBuilderFactory. newKnowledgeBuilder(); builder.add(Res
Re: [rules-users] Facing Problem in BRL
This is my drools.package file: I have just created a package and imported the required class in this file. //This is a package configuration file package com.rules; import com.model.PersonDetails; //Add imports, globals etc here which will be used by all the rule assets in this folder. Regards, Sumeet Karawal Mailto: sumeet.kara...@tcs.com From: Michael Anstis To: Rules Users List Date: 05/18/2011 02:54 PM Subject:Re: [rules-users] Facing Problem in BRL Sent by:rules-users-boun...@lists.jboss.org This looks rogue:- //Add imports, globals etc here which will be used by all the rule assets in this folder Can you post the content of your drools.packages file? On 18 May 2011 10:19, Sumeet Karawal wrote: This is the output that I get : //This is a package configuration file package com.rules; import com.model.PersonDetails; //Add imports, globals etc here which will be used by all the rule assets in this folder.rule "example" dialect "mvel" when $person : PersonDetails( age < "20" ) then $person.setDiscount( 10 ); end java.lang.RuntimeException: [8,1]: [ERR 102] Line 8:1 mismatched input 'WHEN' Regards, Sumeet Karawal Mailto: sumeet.kara...@tcs.com From: "Abhay B. Chaware" To: Rules Users List Date: 05/18/2011 02:47 PM Subject: Re: [rules-users] Facing Problem in BRL Sent by: rules-users-boun...@lists.jboss.org Can you write the outputDRL to System.out and check if the generated DRL syntax is correct ? System.out.println(outputDRL); Before instantiating KnowledgeBuilder -Original Message- From: rules-users-boun...@lists.jboss.org [ mailto:rules-users-boun...@lists.jboss.org] On Behalf Of Sumeet Karawal Sent: Wednesday, May 18, 2011 2:42 PM To: Rules Users List Subject: Re: [rules-users] Facing Problem in BRL I tried to use this also but now I am getting different error: java.lang.RuntimeException: [8,1]: [ERR 102] Line 8:1 mismatched input 'WHEN' Also, what is the significance of the first line. I have copied it as the same. My code is : String curDir = System.getProperty("user.dir"); String fileName = curDir + "\\src\\com\\rules \\drools.package"; String rulePackageContent = FileUtils.readFileToString (new File (fileName)); fileName = curDir + "\\src\\com\\rules\\example.brl"; String brl = FileUtils.readFileToString(new File (fileName)); BRLPersistence read = BRXMLPersistence.getInstance(); BRLPersistence write = BRDRLPersistence.getInstance(); String outputDRL = rulePackageContent + write.marshal (read.unmarshal (brl)); KnowledgeBuilder builder = KnowledgeBuilderFactory. newKnowledgeBuilder(); builder.add(ResourceFactory.newReaderResource(new StringReader (outputDRL)), ResourceType.DRL); if (builder.hasErrors()) { throw new RuntimeException (builder.getErrors().toString ()); } KnowledgeBase knowledgeBase = KnowledgeBaseFactory.newKnowledgeBase(); knowledgeBase.addKnowledgePackages(builder.getKnowledgePackages ()); I don't know where I am getting this wrong. Regards, Sumeet Karawal Mailto: sumeet.kara...@tcs.com From: "Abhay B. Chaware" To: Rules Users List Date: 05/18/2011 01:09 PM Subject: Re: [rules-users] Facing Problem in BRL Sent by: rules-users-boun...@lists.jboss.org I haven't been able to get "ResourceType.BRL" to work. This is how I do it .. String curDir = Sys
Re: [rules-users] Facing Problem in BRL
This is the output that I get : //This is a package configuration file package com.rules; import com.model.PersonDetails; //Add imports, globals etc here which will be used by all the rule assets in this folder.rule "example" dialect "mvel" when $person : PersonDetails( age < "20" ) then $person.setDiscount( 10 ); end java.lang.RuntimeException: [8,1]: [ERR 102] Line 8:1 mismatched input 'WHEN' Regards, Sumeet Karawal Mailto: sumeet.kara...@tcs.com From: "Abhay B. Chaware" To: Rules Users List Date: 05/18/2011 02:47 PM Subject:Re: [rules-users] Facing Problem in BRL Sent by:rules-users-boun...@lists.jboss.org Can you write the outputDRL to System.out and check if the generated DRL syntax is correct ? System.out.println(outputDRL); Before instantiating KnowledgeBuilder -Original Message- From: rules-users-boun...@lists.jboss.org [ mailto:rules-users-boun...@lists.jboss.org] On Behalf Of Sumeet Karawal Sent: Wednesday, May 18, 2011 2:42 PM To: Rules Users List Subject: Re: [rules-users] Facing Problem in BRL I tried to use this also but now I am getting different error: java.lang.RuntimeException: [8,1]: [ERR 102] Line 8:1 mismatched input 'WHEN' Also, what is the significance of the first line. I have copied it as the same. My code is : String curDir = System.getProperty("user.dir"); String fileName = curDir + "\\src\\com\\rules \\drools.package"; String rulePackageContent = FileUtils.readFileToString(new File (fileName)); fileName = curDir + "\\src\\com\\rules\\example.brl"; String brl = FileUtils.readFileToString(new File(fileName)); BRLPersistence read = BRXMLPersistence.getInstance(); BRLPersistence write = BRDRLPersistence.getInstance(); String outputDRL = rulePackageContent + write.marshal (read.unmarshal (brl)); KnowledgeBuilder builder = KnowledgeBuilderFactory. newKnowledgeBuilder(); builder.add(ResourceFactory.newReaderResource(new StringReader (outputDRL)), ResourceType.DRL); if (builder.hasErrors()) { throw new RuntimeException (builder.getErrors().toString ()); } KnowledgeBase knowledgeBase = KnowledgeBaseFactory.newKnowledgeBase(); knowledgeBase.addKnowledgePackages(builder.getKnowledgePackages ()); I don't know where I am getting this wrong. Regards, Sumeet Karawal Mailto: sumeet.kara...@tcs.com From: "Abhay B. Chaware" To: Rules Users List Date: 05/18/2011 01:09 PM Subject:Re: [rules-users] Facing Problem in BRL Sent by:rules-users-boun...@lists.jboss.org I haven't been able to get "ResourceType.BRL" to work. This is how I do it .. String curDir = System.getProperty("user.dir"); String fileName = curDir + "\\src\\main\\rules\\drools.package"; String rulePackageContent = FileUtils.readFileToString(new File(fileName)); fileName = curDir + "\\src\\main\\rules\\eligibility.brl"; String brl = FileUtils.readFileToString(new File(fileName)); BRLPersistence read = BRXMLPersistence.getInstance(); BRLPersistence write = BRDRLPersistence.getInstance(); String outputDRL = rulePackageContent + write.marshal(read.unmarshal(brl)); KnowledgeBuilder kbuilder = KnowledgeBuilderFactory.newKnowledgeBuilder(); kbuilder.add(ResourceFactory.newReaderResource(new StringReader (outputDRL)), ResourceType.DRL); Try this. -abhay -Original Message- From: rules-users-boun...@lists.jboss.org [ mailto:rules-users-boun...@lists.jboss.org] On Behalf Of Sumeet Karawal Sent: Wednesday, May 18, 2011 11:47 AM To: Rules Users List Subject: Re:
Re: [rules-users] Facing Problem in BRL
I tried to use this also but now I am getting different error: java.lang.RuntimeException: [8,1]: [ERR 102] Line 8:1 mismatched input 'WHEN' Also, what is the significance of the first line. I have copied it as the same. My code is : String curDir = System.getProperty("user.dir"); String fileName = curDir + "\\src\\com\\rules\\drools.package"; String rulePackageContent = FileUtils.readFileToString(new File (fileName)); fileName = curDir + "\\src\\com\\rules\\example.brl"; String brl = FileUtils.readFileToString(new File(fileName)); BRLPersistence read = BRXMLPersistence.getInstance(); BRLPersistence write = BRDRLPersistence.getInstance(); String outputDRL = rulePackageContent + write.marshal(read.unmarshal (brl)); KnowledgeBuilder builder = KnowledgeBuilderFactory. newKnowledgeBuilder(); builder.add(ResourceFactory.newReaderResource(new StringReader (outputDRL)), ResourceType.DRL); if (builder.hasErrors()) { throw new RuntimeException (builder.getErrors().toString ()); } KnowledgeBase knowledgeBase = KnowledgeBaseFactory.newKnowledgeBase(); knowledgeBase.addKnowledgePackages(builder.getKnowledgePackages ()); I don't know where I am getting this wrong. Regards, Sumeet Karawal Mailto: sumeet.kara...@tcs.com From: "Abhay B. Chaware" To: Rules Users List Date: 05/18/2011 01:09 PM Subject:Re: [rules-users] Facing Problem in BRL Sent by:rules-users-boun...@lists.jboss.org I haven't been able to get "ResourceType.BRL" to work. This is how I do it .. String curDir = System.getProperty("user.dir"); String fileName = curDir + "\\src\\main\\rules\\drools.package"; String rulePackageContent = FileUtils.readFileToString(new File(fileName)); fileName = curDir + "\\src\\main\\rules\\eligibility.brl"; String brl = FileUtils.readFileToString(new File(fileName)); BRLPersistence read = BRXMLPersistence.getInstance(); BRLPersistence write = BRDRLPersistence.getInstance(); String outputDRL = rulePackageContent + write.marshal(read.unmarshal(brl)); KnowledgeBuilder kbuilder = KnowledgeBuilderFactory.newKnowledgeBuilder(); kbuilder.add(ResourceFactory.newReaderResource(new StringReader (outputDRL)), ResourceType.DRL); Try this. -abhay -Original Message- From: rules-users-boun...@lists.jboss.org [ mailto:rules-users-boun...@lists.jboss.org] On Behalf Of Sumeet Karawal Sent: Wednesday, May 18, 2011 11:47 AM To: Rules Users List Subject: Re: [rules-users] Facing Problem in BRL This is the brl that I have created: (Embedded image moved to file: pic18001.jpg) Regards, Sumeet Karawal Mailto: sumeet.kara...@tcs.com From: "Abhay B. Chaware" To: Rules Users List Date: 05/18/2011 11:42 AM Subject:Re: [rules-users] Facing Problem in BRL Sent by:rules-users-boun...@lists.jboss.org Could you post your rule content here ? -Original Message----- From: rules-users-boun...@lists.jboss.org [ mailto:rules-users-boun...@lists.jboss.org] On Behalf Of Sumeet Karawal Sent: Wednesday, May 18, 2011 11:38 AM To: rules-users@lists.jboss.org Subject: [rules-users] Facing Problem in BRL Hi, I am using Drools-Expert. I am having a class "Person" with data members as age and discount. I am trying to create a .brl. I have these statements in drools.package package com.rules; import com.model.PersonDetails; and in the example.brl I am providing the details of when and then conditions but on execution I am getting the following error : java.lang.RuntimeException: [4] Unable to expand: PersonDetails( age < "20" )[6] Unable to expand: PersonDetails fact0 = new PersonDetails ();[7] Unable to expand: fact0.setDiscount ( 10 );[8] Unable to exp
[rules-users] Facing Problem in BRL
Hi, I am using Drools-Expert. I am having a class "Person" with data members as age and discount. I am trying to create a .brl. I have these statements in drools.package package com.rules; import com.model.PersonDetails; and in the example.brl I am providing the details of when and then conditions but on execution I am getting the following error : java.lang.RuntimeException: [4] Unable to expand: PersonDetails( age < "20" )[6] Unable to expand: PersonDetails fact0 = new PersonDetails ();[7] Unable to expand:fact0.setDiscount( 10 );[8] Unable to expand: insert(fact0 ); It would be helpful is somebody guide me on how execute it. Also, I am creating the knowledgebase as: private static KnowledgeBase createKnowledgeBase() { KnowledgeBuilder builder = KnowledgeBuilderFactory.newKnowledgeBuilder(); builder.add (ResourceFactory.newClassPathResource( "com/rules/example.brl"),ResourceType.BRL); if (builder.hasErrors()) { throw new RuntimeException (builder.getErrors().toString ()); } KnowledgeBase knowledgeBase = KnowledgeBaseFactory.newKnowledgeBase(); knowledgeBase.addKnowledgePackages(builder.getKnowledgePackages ()); return knowledgeBase;} Thanks & Regards, Sumeet Karawal CEG - Open Source Technology Group Tata Consultancy Services Ph:- +912267782556 Cell:- +919833236440 Mailto: sumeet.kara...@tcs.com Website: http://www.tcs.com Experience certainty. IT Services Business Solutions Outsourcing =-=-= Notice: The information contained in this e-mail message and/or attachments to it may contain confidential or privileged information. If you are not the intended recipient, any dissemination, use, review, distribution, printing or copying of the information contained in this e-mail message and/or attachments to it are strictly prohibited. If you have received this communication in error, please notify us by reply e-mail or telephone and immediately and permanently delete the message and any attachments. Thank you ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users
Re: [rules-users] Drools with LDAP
Thanks Mike. It was really helpful. But how can we change the schema so that we use different reporting tools. Thanks & Regards, Sumeet Mailto: sumeet.kara...@tcs.com From: Michael Anstis To: Rules Users List Date: 05/16/2011 01:55 PM Subject:Re: [rules-users] Drools with LDAP Sent by:rules-users-boun...@lists.jboss.org H... the Guvnor Administration user-guide has a section "1.2.3.1. Using your containers security and LDAP" Furthermore, Guvnor uses JackRabbit JCR for storage so any reporting tool able to integrate with this should be usable. We don't however publish a "public" schema so you'd need to perform some exploratory work and bespoke reporting could break if we change our "private" schema. With kind regards, Mike On 16 May 2011 07:13, Sumeet Karawal wrote: Hi, Is it possible to integrate Drools - BRMS with LDAP. I want to use roles defined in LDAP as roles for BRMS for role based access of rules. Also can it be Integrated with any Reporting tool. Thanks & Regards, Sumeet Karawal Mailto: sumeet.kara...@tcs.com =-=-= Notice: The information contained in this e-mail message and/or attachments to it may contain confidential or privileged information. If you are not the intended recipient, any dissemination, use, review, distribution, printing or copying of the information contained in this e-mail message and/or attachments to it are strictly prohibited. If you have received this communication in error, please notify us by reply e-mail or telephone and immediately and permanently delete the message and any attachments. Thank you ___ 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 =-=-= Notice: The information contained in this e-mail message and/or attachments to it may contain confidential or privileged information. If you are not the intended recipient, any dissemination, use, review, distribution, printing or copying of the information contained in this e-mail message and/or attachments to it are strictly prohibited. If you have received this communication in error, please notify us by reply e-mail or telephone and immediately and permanently delete the message and any attachments. Thank you ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users
[rules-users] Drools with LDAP
Hi, Is it possible to integrate Drools - BRMS with LDAP. I want to use roles defined in LDAP as roles for BRMS for role based access of rules. Also can it be Integrated with any Reporting tool. Thanks & Regards, Sumeet Karawal Mailto: sumeet.kara...@tcs.com =-=-= Notice: The information contained in this e-mail message and/or attachments to it may contain confidential or privileged information. If you are not the intended recipient, any dissemination, use, review, distribution, printing or copying of the information contained in this e-mail message and/or attachments to it are strictly prohibited. If you have received this communication in error, please notify us by reply e-mail or telephone and immediately and permanently delete the message and any attachments. Thank you ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users
[rules-users] Customizing Drools UI
Hi, In case of Drools-BRMS, is the UI easily customizable according to requirements or are there some limitations on that front?Also what is the Horizontal scalability of Rule Engine in terms of load?Thanks & Regards,Sumeet KarawalMailto: sumeet.kara...@tcs.com=-=-=Notice: The information contained in this e-mailmessage and/or attachments to it may contain confidential or privileged information. If you are not the intended recipient, any dissemination, use, review, distribution, printing or copying of the information contained in this e-mail message and/or attachments to it are strictly prohibited. If you have received this communication in error, please notify us by reply e-mail or telephone and immediately and permanently delete the message and any attachments. Thank you ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users
Re: [rules-users] Fw: Regarding Drools - Expert and Fusion
Thanks Leonardo. Its very helpful. Regards, Sumeet From: Leonardo Gomes To: Rules Users List Date: 05/05/2011 08:27 PM Subject:Re: [rules-users] Fw: Regarding Drools - Expert and Fusion Sent by:rules-users-boun...@lists.jboss.org Old articles, but that should give you an idea regarding architecture: http://www.infoq.com/articles/Rule-Engines If you want to have a better and up-to-date view, you should probably have a look at Bali's book: http://www.amazon.com/Drools-JBoss-Rules-Developers-Guide/dp/1847195644/ref=pd_bxgy_b_img_b Cheers, Leo. On Thu, May 5, 2011 at 11:22 AM, Sumeet Karawal wrote: Thanks a lot Mike for the help. Regards, Sumeet Karawal Mailto: sumeet.kara...@tcs.com From: Michael Anstis To: Rules Users List Date: 05/04/2011 04:03 PM Subject: Re: [rules-users] Fw: Regarding Drools - Expert and Fusion Sent by: rules-users-boun...@lists.jboss.org I don't know of any such links. Fusion depends upon Expert so they must coexist if you are to use Fusion. Fusion is really the CEP aspect of Expert, I don't believe it possible to "install" Expert without Fusion's extensions. An event based system would be one where you need to make temporal decisions relating to your facts; e.g. there have been 3 alarms in the last 5 minutes etc. Such a system would still use rules; however they would have temporal constraints. With kind regards, Mike On 4 May 2011 11:20, Sumeet Karawal wrote: Hi , I had posted this earlier : " Could somebody please let me know about any link or document for Best Practices regarding JBoss Rules(Expert) and Fusion. Also any link or document regarding Technical Architecture of JBoss Rules (Expert) and JBoss Fusion Stack. " Also I have a query as how can Drools - Expert and Fusion coexist in an Application. I have just started learning about Drools Fusion. What can qualify to go as a event driven system as opposed to rules based system ? It would be very helpful if somebody could let me know about the few things. Thanks & Regards, Sumeet Karawal Mailto: sumeet.kara...@tcs.com From: Sumeet Karawal/MUM/TCS To: rules-users@lists.jboss.org Date: 05/03/2011 07:09 PM Subject: Regarding Drools - Expert and Fusion Hi, Could somebody please let me know about any link or document for Best Practices regarding JBoss Rules(Expert) and Fusion. Also any link or document regarding Technical Architecture of JBoss Rules (Expert) and JBoss Fusion Stack. Thanks & Regards, Sumeet Karawal Mailto: sumeet.kara...@tcs.com =-=-= Notice: The information contained in this e-mail message and/or attachments to it may contain confidential or privileged information. If you are not the intended recipient, any dissemination, use, review, distribution, printing or copying of the information contained in this e-mail message and/or attachments to it are strictly prohibited. If you have received this communication in error, please notify us by reply e-mail or telephone and immediately and permanently delete the message and any attachments. Thank you ___ 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 =-=-= Notice: The information contained in this e-mail message and/or attachments to it may contain confidential or privileged information. If you are not the intended recipient
Re: [rules-users] Fw: Regarding Drools - Expert and Fusion
Thanks a lot Mike for the help. Regards, Sumeet Karawal Mailto: sumeet.kara...@tcs.com From: Michael Anstis To: Rules Users List Date: 05/04/2011 04:03 PM Subject:Re: [rules-users] Fw: Regarding Drools - Expert and Fusion Sent by:rules-users-boun...@lists.jboss.org I don't know of any such links. Fusion depends upon Expert so they must coexist if you are to use Fusion. Fusion is really the CEP aspect of Expert, I don't believe it possible to "install" Expert without Fusion's extensions. An event based system would be one where you need to make temporal decisions relating to your facts; e.g. there have been 3 alarms in the last 5 minutes etc. Such a system would still use rules; however they would have temporal constraints. With kind regards, Mike On 4 May 2011 11:20, Sumeet Karawal wrote: Hi , I had posted this earlier : " Could somebody please let me know about any link or document for Best Practices regarding JBoss Rules(Expert) and Fusion. Also any link or document regarding Technical Architecture of JBoss Rules (Expert) and JBoss Fusion Stack. " Also I have a query as how can Drools - Expert and Fusion coexist in an Application. I have just started learning about Drools Fusion. What can qualify to go as a event driven system as opposed to rules based system ? It would be very helpful if somebody could let me know about the few things. Thanks & Regards, Sumeet Karawal Mailto: sumeet.kara...@tcs.com From: Sumeet Karawal/MUM/TCS To: rules-users@lists.jboss.org Date: 05/03/2011 07:09 PM Subject: Regarding Drools - Expert and Fusion Hi, Could somebody please let me know about any link or document for Best Practices regarding JBoss Rules(Expert) and Fusion. Also any link or document regarding Technical Architecture of JBoss Rules (Expert) and JBoss Fusion Stack. Thanks & Regards, Sumeet Karawal Mailto: sumeet.kara...@tcs.com =-=-= Notice: The information contained in this e-mail message and/or attachments to it may contain confidential or privileged information. If you are not the intended recipient, any dissemination, use, review, distribution, printing or copying of the information contained in this e-mail message and/or attachments to it are strictly prohibited. If you have received this communication in error, please notify us by reply e-mail or telephone and immediately and permanently delete the message and any attachments. Thank you ___ 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 =-=-= Notice: The information contained in this e-mail message and/or attachments to it may contain confidential or privileged information. If you are not the intended recipient, any dissemination, use, review, distribution, printing or copying of the information contained in this e-mail message and/or attachments to it are strictly prohibited. If you have received this communication in error, please notify us by reply e-mail or telephone and immediately and permanently delete the message and any attachments. Thank you ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users
[rules-users] Fw: Regarding Drools - Expert and Fusion
Hi , I had posted this earlier : " Could somebody please let me know about any link or document for Best Practices regarding JBoss Rules(Expert) and Fusion. Also any link or document regarding Technical Architecture of JBoss Rules (Expert) and JBoss Fusion Stack. " Also I have a query as how can Drools - Expert and Fusion coexist in an Application. I have just started learning about Drools Fusion. What can qualify to go as a event driven system as opposed to rules based system ? It would be very helpful if somebody could let me know about the few things. Thanks & Regards, Sumeet Karawal Mailto: sumeet.kara...@tcs.com From: Sumeet Karawal/MUM/TCS To: rules-users@lists.jboss.org Date: 05/03/2011 07:09 PM Subject:Regarding Drools - Expert and Fusion Hi, Could somebody please let me know about any link or document for Best Practices regarding JBoss Rules(Expert) and Fusion. Also any link or document regarding Technical Architecture of JBoss Rules (Expert) and JBoss Fusion Stack. Thanks & Regards, Sumeet Karawal Mailto: sumeet.kara...@tcs.com =-=-= Notice: The information contained in this e-mail message and/or attachments to it may contain confidential or privileged information. If you are not the intended recipient, any dissemination, use, review, distribution, printing or copying of the information contained in this e-mail message and/or attachments to it are strictly prohibited. If you have received this communication in error, please notify us by reply e-mail or telephone and immediately and permanently delete the message and any attachments. Thank you ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users
[rules-users] Regarding Drools - Expert and Fusion
Hi, Could somebody please let me know about any link or document for Best Practices regarding JBoss Rules(Expert) and Fusion. Also any link or document regarding Technical Architecture of JBoss Rules (Expert) and JBoss Fusion Stack. Thanks & Regards, Sumeet Karawal Mailto: sumeet.kara...@tcs.com =-=-= Notice: The information contained in this e-mail message and/or attachments to it may contain confidential or privileged information. If you are not the intended recipient, any dissemination, use, review, distribution, printing or copying of the information contained in this e-mail message and/or attachments to it are strictly prohibited. If you have received this communication in error, please notify us by reply e-mail or telephone and immediately and permanently delete the message and any attachments. Thank you ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users
Re: [rules-users] Drools Performance
Thanks Nicolas. The information is really helpful. Regards, Sumeet Karawal Mailto: sumeet.kara...@tcs.com From: Nicolas Héron To: Rules Users List Date: 04/27/2011 05:37 PM Subject:Re: [rules-users] Drools Performance Sent by:rules-users-boun...@lists.jboss.org Hi, I have done a loyalty system with drools 4 (now they are in version 5) for a retail company in France 3 years that calculates your discount given your points, history, etc.. You have to put a lot of data in memory cache (ehcache for example) as the database is the the weak point in concurrent mode. As for drools, it was running on a simple bi-core server with 4 GB of ram and it could handle 10 concurrent calculations without problems. The total calculation time all inclusive (network connection, database, etc) does never exceed 2 seconds with about 1 loyalty rules for 80 products. The biggerst shop they have has more than a 100 cash machines that can be all open on a saturday afternoon. With a modern server (4-core hyperthreaded=8 cores) and all the rest and even with more ram (= place for data caching) you can even do much better. Hope it helps Regards Nicolas Héron 2011/4/27 Michael Anstis If you use a stateless session per transaction you should generally be OK. How much lag you're likely to encounter is a much harder question to answer: how well does your database retrieval scale, would this present an issue before the rules engine? The rules engine is "just a POJO library" the overall scalability would IMO depend upon your application's architecture. On 27 April 2011 11:27, Sumeet Karawal wrote: Hi, I have an Application where I have to give the discount to user according to their profile points. i.e. when the user logs in, his profile points are fetched from the database, and respectively he is given the required discount. My concern is how many concurrent users will be supported by the rules engine, will there a performance lag if the concurrent number of users exceed a certain limit. Please help me on this as I have no idea regarding this. Thanks and Reagrds, Sumeet Karawal Mailto: sumeet.kara...@tcs.com =-=-= Notice: The information contained in this e-mail message and/or attachments to it may contain confidential or privileged information. If you are not the intended recipient, any dissemination, use, review, distribution, printing or copying of the information contained in this e-mail message and/or attachments to it are strictly prohibited. If you have received this communication in error, please notify us by reply e-mail or telephone and immediately and permanently delete the message and any attachments. Thank you ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users =-=-= Notice: The information contained in this e-mail message and/or attachments to it may contain confidential or privileged information. If you are not the intended recipient, any dissemination, use, review, distribution, printing or copying of the information contained in this e-mail message and/or attachments to it are strictly prohibited. If you have received this communication in error, please notify us by reply e-mail or telephone and immediately and permanently delete the message and any at
Re: [rules-users] Drools Performance
Thanks Mark for the reply. Regards, Sumeet Karawal Mailto: sumeet.kara...@tcs.com From: Mark Proctor To: rules-users@lists.jboss.org Date: 04/27/2011 05:21 PM Subject:Re: [rules-users] Drools Performance Sent by:rules-users-boun...@lists.jboss.org On 27/04/2011 11:52, Sumeet Karawal wrote: > > Thanks Michael for the help. But, is there any benchmark or a rough figure > like number of hits or number of rule fired per minute, for normal > performance. I can write one rule that runs much slower than something with 1000 rules. So we suggest people do their own real life proof of concepts and see if they run fast enough. We tend to avoid benchmarking only because it ends up a focus point between competitors and all of them cheat making the exercise pointless. MArk > Regards, > Sumeet Karawal > > Mailto: sumeet.kara...@tcs.com > > > > >From: Michael Anstis > >To: Rules Users List > >Date: 04/27/2011 04:13 PM > >Subject:Re: [rules-users] Drools Performance > >Sent by:rules-users-boun...@lists.jboss.org > > > > > > > If you use a stateless session per transaction you should generally be OK. > > How much lag you're likely to encounter is a much harder question to > answer: how well does your database retrieval scale, would this present an > issue before the rules engine? > > The rules engine is "just a POJO library" the overall scalability would IMO > depend upon your application's architecture. > > On 27 April 2011 11:27, Sumeet Karawal wrote: > >Hi, > >I have an Application where I have to give the discount to user according >to their profile points. > >i.e. when the user logs in, his profile points are fetched from the >database, and respectively he is given the required discount. > >My concern is how many concurrent users will be supported by the rules >engine, will there a performance lag if the concurrent number of users >exceed a certain limit. Please help me on this as I have no idea >regarding >this. > >Thanks and Reagrds, >Sumeet Karawal > >Mailto: sumeet.kara...@tcs.com > >=-=-= >Notice: The information contained in this e-mail >message and/or attachments to it may contain >confidential or privileged information. If you are >not the intended recipient, any dissemination, use, >review, distribution, printing or copying of the >information contained in this e-mail message >and/or attachments to it are strictly prohibited. If >you have received this communication in error, >please notify us by reply e-mail or telephone and >immediately and permanently delete the message >and any attachments. Thank you > > > >___ >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 > > > > =-=-= > Notice: The information contained in this e-mail > message and/or attachments to it may contain > confidential or privileged information. If you are > not the intended recipient, any dissemination, use, > review, distribution, printing or copying of the > information contained in this e-mail message > and/or attachments to it are strictly prohibited. If > you have received this communication in error, >
Re: [rules-users] Hot deployment in Drools
Thanks Michael. Also for other rule resources like .drl or .dsl and using Drools - Expert, can we change the rules on the fly. Regards, Sumeet Karawal Mailto: sumeet.kara...@tcs.com From: Michael Anstis To: Rules Users List Date: 04/27/2011 04:09 PM Subject:Re: [rules-users] Hot deployment in Drools Sent by:rules-users-boun...@lists.jboss.org 1) Please read about KnowledgeAgent, but you'd still need to upload the revised worksheet to Guvnor. 2) Please read about AgendaEventListener's re: which rules fired. Guvnor maintains audit history for "who" changed rules, but I'm not sure whether there's a (public) API to retrieve this other than through Guvnor's UI. On 27 April 2011 11:20, Sumeet Karawal wrote: Hi, I have some queries about Drools - Guvnor : 1) Is hot deployment possible in Guvnor, how can we do that? How can we change rules on fly? eg we are using Decision Table for rules and if we change some data in that sheet, how will the changes get reflected in the rule engine? 2) Does the rule engine maintain a log file (in expert as well as in Guvnor). How to do an Audit check eg. for getting which rules were fired, which user changed the rules and at what time? Thanks & Regards, Sumeet Karawal Mailto: sumeet.kara...@tcs.com =-=-= Notice: The information contained in this e-mail message and/or attachments to it may contain confidential or privileged information. If you are not the intended recipient, any dissemination, use, review, distribution, printing or copying of the information contained in this e-mail message and/or attachments to it are strictly prohibited. If you have received this communication in error, please notify us by reply e-mail or telephone and immediately and permanently delete the message and any attachments. Thank you ___ 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 =-=-= Notice: The information contained in this e-mail message and/or attachments to it may contain confidential or privileged information. If you are not the intended recipient, any dissemination, use, review, distribution, printing or copying of the information contained in this e-mail message and/or attachments to it are strictly prohibited. If you have received this communication in error, please notify us by reply e-mail or telephone and immediately and permanently delete the message and any attachments. Thank you ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users
Re: [rules-users] Drools Performance
Thanks Michael for the help. But, is there any benchmark or a rough figure like number of hits or number of rule fired per minute, for normal performance. Regards, Sumeet Karawal Mailto: sumeet.kara...@tcs.com From: Michael Anstis To: Rules Users List Date: 04/27/2011 04:13 PM Subject:Re: [rules-users] Drools Performance Sent by:rules-users-boun...@lists.jboss.org If you use a stateless session per transaction you should generally be OK. How much lag you're likely to encounter is a much harder question to answer: how well does your database retrieval scale, would this present an issue before the rules engine? The rules engine is "just a POJO library" the overall scalability would IMO depend upon your application's architecture. On 27 April 2011 11:27, Sumeet Karawal wrote: Hi, I have an Application where I have to give the discount to user according to their profile points. i.e. when the user logs in, his profile points are fetched from the database, and respectively he is given the required discount. My concern is how many concurrent users will be supported by the rules engine, will there a performance lag if the concurrent number of users exceed a certain limit. Please help me on this as I have no idea regarding this. Thanks and Reagrds, Sumeet Karawal Mailto: sumeet.kara...@tcs.com =-=-= Notice: The information contained in this e-mail message and/or attachments to it may contain confidential or privileged information. If you are not the intended recipient, any dissemination, use, review, distribution, printing or copying of the information contained in this e-mail message and/or attachments to it are strictly prohibited. If you have received this communication in error, please notify us by reply e-mail or telephone and immediately and permanently delete the message and any attachments. Thank you ___ 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 =-=-= Notice: The information contained in this e-mail message and/or attachments to it may contain confidential or privileged information. If you are not the intended recipient, any dissemination, use, review, distribution, printing or copying of the information contained in this e-mail message and/or attachments to it are strictly prohibited. If you have received this communication in error, please notify us by reply e-mail or telephone and immediately and permanently delete the message and any attachments. Thank you ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users
[rules-users] Drools Performance
Hi, I have an Application where I have to give the discount to user according to their profile points. i.e. when the user logs in, his profile points are fetched from the database, and respectively he is given the required discount. My concern is how many concurrent users will be supported by the rules engine, will there a performance lag if the concurrent number of users exceed a certain limit. Please help me on this as I have no idea regarding this. Thanks and Reagrds, Sumeet Karawal Mailto: sumeet.kara...@tcs.com =-=-= Notice: The information contained in this e-mail message and/or attachments to it may contain confidential or privileged information. If you are not the intended recipient, any dissemination, use, review, distribution, printing or copying of the information contained in this e-mail message and/or attachments to it are strictly prohibited. If you have received this communication in error, please notify us by reply e-mail or telephone and immediately and permanently delete the message and any attachments. Thank you ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users
[rules-users] Hot deployment in Drools
Hi, I have some queries about Drools - Guvnor : 1) Is hot deployment possible in Guvnor, how can we do that? How can we change rules on fly? eg we are using Decision Table for rules and if we change some data in that sheet, how will the changes get reflected in the rule engine? 2) Does the rule engine maintain a log file (in expert as well as in Guvnor). How to do an Audit check eg. for getting which rules were fired, which user changed the rules and at what time? Thanks & Regards, Sumeet Karawal Mailto: sumeet.kara...@tcs.com =-=-= Notice: The information contained in this e-mail message and/or attachments to it may contain confidential or privileged information. If you are not the intended recipient, any dissemination, use, review, distribution, printing or copying of the information contained in this e-mail message and/or attachments to it are strictly prohibited. If you have received this communication in error, please notify us by reply e-mail or telephone and immediately and permanently delete the message and any attachments. Thank you ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users
Re: [rules-users] Fw: Some Querries on Drools
Thanks a lot Randhish!!! Stateful sessions will have to be disposed. But what if the sessions are taking too long, same with the case of stateless sessions, then what to do in that case. Also in the multi- threaded environment, if I have 10 - 100 Ks of threads, will the rule engines performance be still better. Thanks & Regards, Sumeet Karawal Mailto: sumeet.kara...@tcs.com From: Randhish Raghavan To: Rules Users List Date: 04/19/2011 08:51 PM Subject:Re: [rules-users] Fw: Some Querries on Drools Sent by:rules-users-boun...@lists.jboss.org Hi, I am quite new to drools but I will try to answer your questions. I don't think Drools will cause your application to crash if you ensure 1. You develop rules that will not result in infinite loops. 2. Dispose sessions if you are using Stateful sessions. Basically, you would want to create the Knowledge base once i.e. during application startup. You will create a new Session (not an expensive operation) for every request. In this scenario it will be better to use stateless sessions as you do not have to worry about disposing them. However, if you want to use statefull sessions, you might want to write a set of wrapper classes that provide api's to manage the statefull session and execute rules. Developers will only be allowed to access api's that execute rules and will not have access to api's that create and dispose a session. To you next question on making changes to rules, You have to create a KnowledgeAgent that checks if the rule resource has been modified at configured intervals. The rule resource (drl,pkg etc) can exist on the file system or you want to try to configure rules in guvnor. Guvnor is a GUI tool that allows you to manage rules. Regards, Randhish -Original Message- From: rules-users-boun...@lists.jboss.org [ mailto:rules-users-boun...@lists.jboss.org] On Behalf Of Sumeet Karawal Sent: Tuesday, April 19, 2011 2:53 PM To: rules-users@lists.jboss.org Subject: [rules-users] Fw: Some Querries on Drools Hi Everybody, I had posted this earlier. It would be very greatful if anybody could help me on these queries, any suggestions or any document that I can refer to. Thanks and Regards, Sumeet Karawal Mailto: sumeet.kara...@tcs.com From: Sumeet Karawal/MUM/TCS To: rules-users@lists.jboss.org Date: 04/18/2011 06:58 PM Subject:Some Querries on Drools Hello All, I have some queries regarding use of drools as rule engine for my Application. It would be very helpful if I get some guidance regarding these: 1) I have an application in which a user logs in, and according to his profile he is provided with some benefits, and rule engine check for the eligibility criteria. But if hundreds of thousands of user will log in at same time, then what will be the performance accordingly. Like, these concurrent users hitting the server, and so many threads will be generated and many number of rules will be fired in the session. Will this hamper the performance of Rule Engine. 2) Suppose I have an application using drools. I create EAR / WAR file of that application and deploy it on some other system. Would it be still possible for me to change the rules on the fly. Or some dependencies might have to be managed. 3) How can we manage sessions in drools? Suppose we are having different stateful sessions in our application, but time consumption when we fireAllRules() exceeds the expected time. So is there a mechanism to kill, restart the session in drools. Could I get some help/document regarding session Management on drools. Thanks & Regards, Sumeet Karawal Mailto: sumeet.kara...@tcs.com =-=-= Notice: The information contained in this e-mail message and/or attachments to it may contain confidential or privileged information. If you are not the intended recipient, an
Re: [rules-users] How to use for loop in drools!!!!
Thanks Esteban!!. I got you point. But how to make the rule to run according to a condition, in a loop. Also, how can we trigger the firing of one rule from another rule. Like when the Condition part of a rule satisfies then, in the Action part a particular rule is triggered and after that the control resumes to the previous rule, just as we do in nested if else statement. Thanks & Regards, Sumeet Karawal Mailto: sumeet.kara...@tcs.com From: Esteban Aliverti To: Rules Users List Date: 04/19/2011 05:41 PM Subject:Re: [rules-users] How to use for loop in drools Sent by:rules-users-boun...@lists.jboss.org Drools is an inference engine and it let you express your knowledge using rules. A rule has 2 parts: CONDITION par and ACTION part. The CONDITION part is expressed in a drools' proprietary syntax, but in the ACTION part you can use plain java code. What you have described looks like an action that needs to be executed when certain constraints are meet. So, in your case, you can just write those lines in you action part. They should work fine. I recommend you to read the documentation: http://downloads.jboss.com/drools/docs/5.1.1.34858.FINAL/drools-expert/html_single/index.html Best Regards, Esteban Aliverti - Developer @ http://www.plugtree.com - Blog @ http://ilesteban.wordpress.com On Tue, Apr 19, 2011 at 3:13 AM, Sumeet Karawal wrote: for(i = 0; i<10; i++) { c.setCustomerCount(c.getCustomerCount() + 1); } ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users =-=-= Notice: The information contained in this e-mail message and/or attachments to it may contain confidential or privileged information. If you are not the intended recipient, any dissemination, use, review, distribution, printing or copying of the information contained in this e-mail message and/or attachments to it are strictly prohibited. If you have received this communication in error, please notify us by reply e-mail or telephone and immediately and permanently delete the message and any attachments. Thank you ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users
[rules-users] Fw: Some Querries on Drools
Hi Everybody, I had posted this earlier. It would be very greatful if anybody could help me on these queries, any suggestions or any document that I can refer to. Thanks and Regards, Sumeet Karawal Mailto: sumeet.kara...@tcs.com From: Sumeet Karawal/MUM/TCS To: rules-users@lists.jboss.org Date: 04/18/2011 06:58 PM Subject:Some Querries on Drools Hello All, I have some queries regarding use of drools as rule engine for my Application. It would be very helpful if I get some guidance regarding these: 1) I have an application in which a user logs in, and according to his profile he is provided with some benefits, and rule engine check for the eligibility criteria. But if hundreds of thousands of user will log in at same time, then what will be the performance accordingly. Like, these concurrent users hitting the server, and so many threads will be generated and many number of rules will be fired in the session. Will this hamper the performance of Rule Engine. 2) Suppose I have an application using drools. I create EAR / WAR file of that application and deploy it on some other system. Would it be still possible for me to change the rules on the fly. Or some dependencies might have to be managed. 3) How can we manage sessions in drools? Suppose we are having different stateful sessions in our application, but time consumption when we fireAllRules() exceeds the expected time. So is there a mechanism to kill, restart the session in drools. Could I get some help/document regarding session Management on drools. Thanks & Regards, Sumeet Karawal Mailto: sumeet.kara...@tcs.com =-=-= Notice: The information contained in this e-mail message and/or attachments to it may contain confidential or privileged information. If you are not the intended recipient, any dissemination, use, review, distribution, printing or copying of the information contained in this e-mail message and/or attachments to it are strictly prohibited. If you have received this communication in error, please notify us by reply e-mail or telephone and immediately and permanently delete the message and any attachments. Thank you ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users
[rules-users] How to use for loop in drools!!!!
Hello Everybody, I am not getting, on how to do for loop functionality in drools. Like for instance, my functionality has : for(i = 0; i<10; i++) { c.setCustomerCount(c.getCustomerCount() + 1); } How to translate this code into rule language (.drl). It would be helpful if anybody could guide me on this. Thanks and Regards, Sumeet Karawal Mailto: sumeet.kara...@tcs.com =-=-= Notice: The information contained in this e-mail message and/or attachments to it may contain confidential or privileged information. If you are not the intended recipient, any dissemination, use, review, distribution, printing or copying of the information contained in this e-mail message and/or attachments to it are strictly prohibited. If you have received this communication in error, please notify us by reply e-mail or telephone and immediately and permanently delete the message and any attachments. Thank you ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users
[rules-users] Some Querries on Drools
Hello All, I have some queries regarding use of drools as rule engine for my Application. It would be very helpful if I get some guidance regarding these: 1) I have an application in which a user logs in, and according to his profile he is provided with some benefits, and rule engine check for the eligibility criteria. But if hundreds of thousands of user will log in at same time, then what will be the performance accordingly. Like, these concurrent users hitting the server, and so many threads will be generated and many number of rules will be fired in the session. Will this hamper the performance of Rule Engine. 2) Suppose I have an application using drools. I create EAR / WAR file of that application and deploy it on some other system. Would it be still possible for me to change the rules on the fly. Or some dependencies might have to be managed. 3) How can we manage sessions in drools? Suppose we are having different stateful sessions in our application, but time consumption when we fireAllRules() exceeds the expected time. So is there a mechanism to kill, restart the session in drools. Could I get some help/document regarding session Management on drools. Thanks & Regards, Sumeet Karawal CEG - Open Source Technology Group Tata Consultancy Services Ph:- +912267782556 Cell:- +919833236440 Mailto: sumeet.kara...@tcs.com Website: http://www.tcs.com Experience certainty. IT Services Business Solutions Outsourcing rules-users@lists.jboss.org =-=-= Notice: The information contained in this e-mail message and/or attachments to it may contain confidential or privileged information. If you are not the intended recipient, any dissemination, use, review, distribution, printing or copying of the information contained in this e-mail message and/or attachments to it are strictly prohibited. If you have received this communication in error, please notify us by reply e-mail or telephone and immediately and permanently delete the message and any attachments. Thank you ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users
[rules-users] Problem using Guvnor rules in eclipse
Hi All, Could you please help me on this. I am trying to create rules in Guvnor and then using those in eclipse. These are the steps that I am doing 1) I have created a POJO in eclipse 2) Exported as .jar and uploading it in Guvnor under a package. 3) I have created rules also in Guvnor and the test scenario there is also working fine. 4) I build the package and the binaries get generated. But I am not getting how to use those rule in my Java Application running on Eclipse. I have gone through the user guide and forums also but not getting the concrete solution for this. >From somewhere I got the following code : KnowledgeAgent kagent = KnowledgeAgentFactory.newKnowledgeAgent ( "MyAgent" ); kagent.applyChangeSet( ResourceFactory.newUrlResource( url ) ); KnowledgeBase kbase = kagent.getKnowledgeBase(); But how to work according to it. Which url I have to give here, also I am not able to locate the changeset.xml. Also what should I write in the .properties file and how to refer to that. Please it would be very helpful if anyone could provide help to me on this as I am stuck from last 4 days on this. Is there any example that I can refer to? Thanks and Regards, Sumeet Mailto: sumeet.kara...@tcs.com rules-users@lists.jboss.org =-=-= Notice: The information contained in this e-mail message and/or attachments to it may contain confidential or privileged information. If you are not the intended recipient, any dissemination, use, review, distribution, printing or copying of the information contained in this e-mail message and/or attachments to it are strictly prohibited. If you have received this communication in error, please notify us by reply e-mail or telephone and immediately and permanently delete the message and any attachments. Thank you ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users
Re: [rules-users] Rules with C++
Thanks a lot. I will try this... Regards, Sumeet Karawal CEG - Open Source Technology Group Tata Consultancy Services Ph:- +912267782556 Cell:- +919833236440 Mailto: sumeet.kara...@tcs.com Website: http://www.tcs.com Experience certainty. IT Services Business Solutions Outsourcing From: Michael Anstis To: Rules Users List Date: 04/13/2011 02:50 PM Subject:Re: [rules-users] Rules with C++ Sent by:rules-users-boun...@lists.jboss.org Using native C++ objects as Facts in Drools is not going to be easy. You would be better off looking to use Drools as a service consumed by your C++ code. Have at the REST interface recently provided and "3.3.8. Commands and the CommandExecutor" of Experts documentation might be of use. With kind regards, Mike On 13 April 2011 10:05, Sumeet Karawal wrote: Hi All, I have my application written in C++. How can I use Drools to make rules that work on C++ facts. Also How to use BRMS in this case? It would be very helpful if somebody could guide me on this. Thanks and Regards, Sumeet Karawal Mailto: sumeet.kara...@tcs.com =-=-= Notice: The information contained in this e-mail message and/or attachments to it may contain confidential or privileged information. If you are not the intended recipient, any dissemination, use, review, distribution, printing or copying of the information contained in this e-mail message and/or attachments to it are strictly prohibited. If you have received this communication in error, please notify us by reply e-mail or telephone and immediately and permanently delete the message and any attachments. Thank you ___ 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 =-=-= Notice: The information contained in this e-mail message and/or attachments to it may contain confidential or privileged information. If you are not the intended recipient, any dissemination, use, review, distribution, printing or copying of the information contained in this e-mail message and/or attachments to it are strictly prohibited. If you have received this communication in error, please notify us by reply e-mail or telephone and immediately and permanently delete the message and any attachments. Thank you ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users
[rules-users] Rules with C++
Hi All, I have my application written in C++. How can I use Drools to make rules that work on C++ facts. Also How to use BRMS in this case? It would be very helpful if somebody could guide me on this. Thanks and Regards, Sumeet Karawal Mailto: sumeet.kara...@tcs.com =-=-= Notice: The information contained in this e-mail message and/or attachments to it may contain confidential or privileged information. If you are not the intended recipient, any dissemination, use, review, distribution, printing or copying of the information contained in this e-mail message and/or attachments to it are strictly prohibited. If you have received this communication in error, please notify us by reply e-mail or telephone and immediately and permanently delete the message and any attachments. Thank you ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users