[jboss-jira] [JBoss JIRA] (DROOLS-4386) Wrong matched rules set were fired when one of the condition having empty cell in drools 6.5.0 using Jdk 1.8

Mario Fusco (Jira) issues at jboss.org
Fri Jan 3 11:04:43 EST 2020


     [ https://issues.redhat.com/browse/DROOLS-4386?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Mario Fusco updated DROOLS-4386:
--------------------------------
    Sprint: 2020 Week 01-03 (from Dec 30)


> Wrong matched rules set were fired when one of the condition having empty cell in drools 6.5.0 using Jdk 1.8
> ------------------------------------------------------------------------------------------------------------
>
>                 Key: DROOLS-4386
>                 URL: https://issues.redhat.com/browse/DROOLS-4386
>             Project: Drools
>          Issue Type: Bug
>          Components: decision tables
>    Affects Versions: 6.5.0.Final
>         Environment: Windows, Java 1.8 and drools 6.5.0.Final 
>            Reporter: Rahul Ramachar
>            Assignee: Mario Fusco
>            Priority: Major
>         Attachments: Discount.xls
>
>
> In JDK 1.7 we were using Drools 5.3.0.Final version and we are migrating to jdk 1.8 so drools 5.3.0.Final was not supported in which we were using Package Builder.
> We migrated JDK 1.8 with drools  6.5.0.Final which uses Kie API to implement rules
> Below is the decision table I am using:
> Customer Rule:
>                       Condition             Condition          Action
>                   ---------------------------------------------------
> Rule NO.          Type                     Years              Discount
>                   ---------------------------------------------------
> 1                    "Individual"                   5                    15
> 2                    "Individual"                   3                    10
> 3                    "Individual"                                         20
> if I insert customer object  as "Type" = Individual and "Years" = 5
> after fireAllRules
> It fires two rules i.e Rule no. 1 and 3 and gives the 3rd Rule number as result instead of Rule number 1, inturn gives Discount as 20 instead of 15 which is wrong result.
> if I insert customer object  as "Type" = Individual and "Years" = 3
> after fireAllRules
> It fires two rules i.e Rule no. 2 and 3 and gives the 3rd rule number as result instead of Rule number 2, inturn gives Discount as 20 instead of 10 which is wrong result.
> Exact rule match is not happening and providing wrong results.
> Could you please give the solution for this it is breaking so many rules in the application. 



--
This message was sent by Atlassian Jira
(v7.13.8#713008)


More information about the jboss-jira mailing list