[JBoss JIRA] (DROOLS-5023) executable model doesn't fire when Or with trimmed duplicate constraints
by Luca Molteni (Jira)
[ https://issues.redhat.com/browse/DROOLS-5023?page=com.atlassian.jira.plug... ]
Luca Molteni updated DROOLS-5023:
---------------------------------
Story Points: 5
> executable model doesn't fire when Or with trimmed duplicate constraints
> ------------------------------------------------------------------------
>
> Key: DROOLS-5023
> URL: https://issues.redhat.com/browse/DROOLS-5023
> Project: Drools
> Issue Type: Bug
> Components: executable model
> Affects Versions: 7.32.0.Final
> Reporter: Toshiya Kobayashi
> Assignee: Luca Molteni
> Priority: Major
>
> With a rule like this, (see that white spaces around "==" in the second rule are trimmed)
> {noformat}
> rule R1 when
> Person( $name: name == "Mark", $age: age ) or
> Person( $name: name == "Mario", $age : age )
> then
> list.add( $name + " is " + $age);
> end
> rule R2 when
> $p: Person( name=="Mark", $age: age ) or
> $p: Person( name=="Mario", $age : age )
> then
> list.add( $p + " has " + $age + " years");
> end
> {noformat}
> when you insert a fact,
> {code:java}
> ksession.insert( new Person( "Mark", 37 ) );
> {code}
> only one rule fires.
--
This message was sent by Atlassian Jira
(v7.13.8#713008)
6 years, 5 months
[JBoss JIRA] (DROOLS-5025) Wrong BitMask created by a complex setter argument in modify block
by Luca Molteni (Jira)
[ https://issues.redhat.com/browse/DROOLS-5025?page=com.atlassian.jira.plug... ]
Luca Molteni updated DROOLS-5025:
---------------------------------
Sprint: 2020 Week 07-09 (from Feb 10)
> Wrong BitMask created by a complex setter argument in modify block
> ------------------------------------------------------------------
>
> Key: DROOLS-5025
> URL: https://issues.redhat.com/browse/DROOLS-5025
> Project: Drools
> Issue Type: Bug
> Components: executable model
> Affects Versions: 7.32.0.Final
> Reporter: Toshiya Kobayashi
> Assignee: Luca Molteni
> Priority: Major
>
> With a complex setter argument in modify block like this:
> {noformat}
> import org.drools.modelcompiler.domain.Person;
> rule R
> when
> $p: Person(address.street == "street1")
> then
> modify($p) { setLikes( String.valueOf(($p.getAddress().getStreet() + $p.getAddress().getCity()))) };
> end
> {noformat}
> executable model creates BitMask for "likes" and "address" thus causes a wrong property reactivity behavior.
--
This message was sent by Atlassian Jira
(v7.13.8#713008)
6 years, 5 months
[JBoss JIRA] (DROOLS-5028) Support incremental update for function with executable model
by Luca Molteni (Jira)
[ https://issues.redhat.com/browse/DROOLS-5028?page=com.atlassian.jira.plug... ]
Luca Molteni updated DROOLS-5028:
---------------------------------
Sprint: 2020 Week 07-09 (from Feb 10)
> Support incremental update for function with executable model
> -------------------------------------------------------------
>
> Key: DROOLS-5028
> URL: https://issues.redhat.com/browse/DROOLS-5028
> Project: Drools
> Issue Type: Task
> Components: executable model
> Affects Versions: 7.32.0.Final
> Reporter: Toshiya Kobayashi
> Assignee: Luca Molteni
> Priority: Major
>
> When you do incremental compilation with executable model, if a function is updated, you will get this error.
> {noformat}
> [ERROR] testKJarUpgradeWithChangedFunction[PATTERN_DSL](org.drools.modelcompiler.IncrementalCompilationTest) Time elapsed: 2.682 s <<< ERROR!
> java.lang.IllegalArgumentException: Unsupported change type: function!
> at org.drools.modelcompiler.builder.CanonicalKieBaseUpdater.run(CanonicalKieBaseUpdater.java:148)
> at org.drools.core.impl.KnowledgeBaseImpl.enqueueModification(KnowledgeBaseImpl.java:745)
> at org.drools.compiler.kie.builder.impl.KieContainerImpl.update(KieContainerImpl.java:266)
> at org.drools.compiler.kie.builder.impl.KieContainerImpl.update(KieContainerImpl.java:236)
> at org.drools.compiler.kie.builder.impl.KieContainerImpl.updateToVersion(KieContainerImpl.java:194)
> at org.drools.modelcompiler.IncrementalCompilationTest.testKJarUpgradeWithChangedFunction(IncrementalCompilationTest.java:359)
> ...
> {noformat}
> This is an explicit limitation at the moment but I filed this JIRA to support a function update.
--
This message was sent by Atlassian Jira
(v7.13.8#713008)
6 years, 5 months
[JBoss JIRA] (DROOLS-4891) Further Optimize Lambdas in Executable Model
by Luca Molteni (Jira)
[ https://issues.redhat.com/browse/DROOLS-4891?page=com.atlassian.jira.plug... ]
Luca Molteni updated DROOLS-4891:
---------------------------------
Sprint: 2020 Week 07-09 (from Feb 10)
> Further Optimize Lambdas in Executable Model
> --------------------------------------------
>
> Key: DROOLS-4891
> URL: https://issues.redhat.com/browse/DROOLS-4891
> Project: Drools
> Issue Type: Enhancement
> Reporter: Luca Molteni
> Assignee: Luca Molteni
> Priority: Major
> Labels: good-first-issue
>
> Lambda shouldn't be externalized depending on the variable name but on the actual lambda.
> So
> person.name == a
> person.name == b
> Is effectively the same lambda and should externalized once.
> Hint: we could rename the parameters to p1, p2, p3, promote the types to fully qualified names and get this result.
--
This message was sent by Atlassian Jira
(v7.13.8#713008)
6 years, 5 months