[jboss-jira] [JBoss JIRA] (DROOLS-5214) Executable model compilation fails with constraints containing static method calls
Mario Fusco (Jira)
issues at jboss.org
Fri Apr 3 10:21:55 EDT 2020
[ https://issues.redhat.com/browse/DROOLS-5214?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Mario Fusco resolved DROOLS-5214.
---------------------------------
Resolution: Done
Fixed by https://github.com/kiegroup/drools/commit/37642f78b662288d28707e56b16322058544813a
> Executable model compilation fails with constraints containing static method calls
> ----------------------------------------------------------------------------------
>
> Key: DROOLS-5214
> URL: https://issues.redhat.com/browse/DROOLS-5214
> Project: Drools
> Issue Type: Bug
> Components: core engine
> Affects Versions: 7.35.0.Final
> Reporter: Matteo Casalino
> Assignee: Mario Fusco
> Priority: Major
> Attachments: static-methods-in-contraint.zip
>
>
> Executable model rule compilation fails on patterns containing Java static method calls as constraints
> Example of DRL that fails to compile:
> {noformat}
> rule "Array asList"
> when Pojo(java.util.Arrays.asList(1,5,2,3).containsAll(integerList))
> then
> end
> {noformat}
> or
> {noformat}
> rule "collections disjoint"
> when $p : Pojo($boundList : integerList) Pojo(id > $p.id, !java.util.Collections.disjoint( integerList , $boundList ))
> then
> end
> {noformat}
> or
> {noformat}
> rule "containsAll"
> when Pojo(integerList.containsAll(java.util.Arrays.asList(1,3)), integerList.size() == 2)
> then
> end
> {noformat}
> All above examples work fine when compiling without executable model.
--
This message was sent by Atlassian Jira
(v7.13.8#713008)
More information about the jboss-jira
mailing list