Toshiya Kobayashi created DROOLS-5107:
-----------------------------------------
Summary: A rule always fires with executable model for a constraint which has
extra parentheses
Key: DROOLS-5107
URL:
https://issues.redhat.com/browse/DROOLS-5107
Project: Drools
Issue Type: Bug
Components: executable model
Affects Versions: 7.33.0.Final
Reporter: Toshiya Kobayashi
Assignee: Luca Molteni
When you have a constraint with extra parentheses,
{noformat}
$p : Person((age > 30))
{noformat}
executable-model generates pattern without constraint expr method so it always fires.
{code:java}
public static org.drools.model.Rule rule_R() {
final org.drools.model.Variable<org.drools.modelcompiler.domain.Person>
var_$p = D.declarationOf(org.drools.modelcompiler.domain.Person.class,
DomainClassesMetadataFBDA1ED637C8B60C741C0BDB502EB8F0.org_drools_modelcompiler_domain_Person_Metadata_INSTANCE,
"$p");
org.drools.model.Rule rule = D.rule("R").build(D.pattern(var_$p),
D.execute(() -> {
{
}
}));
return rule;
}
{code}
--
This message was sent by Atlassian Jira
(v7.13.8#713008)