[JBoss JIRA] (DROOLS-5688) Cleanup/refactoring public API
by Gabriele Cardosi (Jira)
[ https://issues.redhat.com/browse/DROOLS-5688?page=com.atlassian.jira.plug... ]
Gabriele Cardosi updated DROOLS-5688:
-------------------------------------
Description:
Refactor "public" API (i.e. API to be used by final user) moving them in the "API" module.
Main classes involved:
PMMLRuntimeFactory (drools)
PmmlPredictionModel (kogito - remove direct access to KiePMMLModel; create an "end-user" DTO representation of KiePMMLModel)
PMMLResource (used in both kogito and kie-maven-plugin)
was:
Refactor "public" API (i.e. API to be used by final user) moving them in the "API" module.
Main classes involved:
PMMLRuntimeFactory (drools)
PmmlPredictionModel (kogito - remove direct access to KiePMMLModel; create an "end-user" DTO representation of KiePMMLModel)
> Cleanup/refactoring public API
> ------------------------------
>
> Key: DROOLS-5688
> URL: https://issues.redhat.com/browse/DROOLS-5688
> Project: Drools
> Issue Type: Enhancement
> Reporter: Gabriele Cardosi
> Assignee: Gabriele Cardosi
> Priority: Major
> Labels: TrustyAI
>
> Refactor "public" API (i.e. API to be used by final user) moving them in the "API" module.
>
> Main classes involved:
> PMMLRuntimeFactory (drools)
> PmmlPredictionModel (kogito - remove direct access to KiePMMLModel; create an "end-user" DTO representation of KiePMMLModel)
> PMMLResource (used in both kogito and kie-maven-plugin)
>
>
--
This message was sent by Atlassian Jira
(v7.13.8#713008)
5 years, 7 months
[JBoss JIRA] (DROOLS-5697) Make exec model's groupBy() composable
by Lukáš Petrovický (Jira)
[ https://issues.redhat.com/browse/DROOLS-5697?page=com.atlassian.jira.plug... ]
Lukáš Petrovický edited comment on DROOLS-5697 at 10/6/20 5:00 AM:
-------------------------------------------------------------------
I added an example of how I think the exec model could look for this:
[https://github.com/triceo/drools/commit/fc26d88dff65727dc529d24228fc02970...]
was (Author: lpetrovicky):
I added an example of how I think the exec model could look for this:
https://github.com/triceo/drools/commit/6a9f15fd6df2930fca025bf205c9854a0...
> Make exec model's groupBy() composable
> --------------------------------------
>
> Key: DROOLS-5697
> URL: https://issues.redhat.com/browse/DROOLS-5697
> Project: Drools
> Issue Type: Enhancement
> Components: executable model
> Affects Versions: 7.44.0.Final
> Reporter: Lukáš Petrovický
> Assignee: Mario Fusco
> Priority: Major
>
> In some of the OptaPlanner examples, we have Constraint Streams like this:
> {code:java}
> .groupBy(ProcessAssignment::getService, count())
> .groupBy(Service::getTag, max((service, count) -> count))
> {code}
> This will:
> - Take all ProcessAssigment instances.
> - Count all such instances which run on the same Service.
> - Out of all the pairs of (service, count) find the maximum count where the services share the same Tag.
> This is an example of groupBy composition. Currently, we implement it with the old, inefficient groupBy. That implementation looks something like this:
> {noformat}
> when
> $tuples: List<Tuple<Service, Integer>> from accumulate(
> $p: ProcessAssignment(),
> ...
> groupBy(ProcessAssignment::getService, count())
> )
> $tuples2: List<Tuple<String, Integer>> from accumulate(
> $tuple: Tuple<Service, Integer> from $tuples,
> ...
> groupBy(Service::getTag, max($tuple._2))
> )
> $result: Tuple<String, Integer> from $tuples2
> then
> System.out.println($result);
> end
> {noformat}
> We'd like the new groupBy construct to be capable of composition instead.
--
This message was sent by Atlassian Jira
(v7.13.8#713008)
5 years, 7 months
[JBoss JIRA] (DROOLS-5697) Make exec model's groupBy() composable
by Lukáš Petrovický (Jira)
[ https://issues.redhat.com/browse/DROOLS-5697?page=com.atlassian.jira.plug... ]
Lukáš Petrovický commented on DROOLS-5697:
------------------------------------------
I added an example of how I think the exec model could look for this:
https://github.com/triceo/drools/commit/6a9f15fd6df2930fca025bf205c9854a0...
> Make exec model's groupBy() composable
> --------------------------------------
>
> Key: DROOLS-5697
> URL: https://issues.redhat.com/browse/DROOLS-5697
> Project: Drools
> Issue Type: Enhancement
> Components: executable model
> Affects Versions: 7.44.0.Final
> Reporter: Lukáš Petrovický
> Assignee: Mario Fusco
> Priority: Major
>
> In some of the OptaPlanner examples, we have Constraint Streams like this:
> {code:java}
> .groupBy(ProcessAssignment::getService, count())
> .groupBy(Service::getTag, max((service, count) -> count))
> {code}
> This will:
> - Take all ProcessAssigment instances.
> - Count all such instances which run on the same Service.
> - Out of all the pairs of (service, count) find the maximum count where the services share the same Tag.
> This is an example of groupBy composition. Currently, we implement it with the old, inefficient groupBy. That implementation looks something like this:
> {noformat}
> when
> $tuples: List<Tuple<Service, Integer>> from accumulate(
> $p: ProcessAssignment(),
> ...
> groupBy(ProcessAssignment::getService, count())
> )
> $tuples2: List<Tuple<String, Integer>> from accumulate(
> $tuple: Tuple<Service, Integer> from $tuples,
> ...
> groupBy(Service::getTag, max($tuple._2))
> )
> $result: Tuple<String, Integer> from $tuples2
> then
> System.out.println($result);
> end
> {noformat}
> We'd like the new groupBy construct to be capable of composition instead.
--
This message was sent by Atlassian Jira
(v7.13.8#713008)
5 years, 7 months
[JBoss JIRA] (DROOLS-5697) Make exec model's groupBy() composable
by Mario Fusco (Jira)
[ https://issues.redhat.com/browse/DROOLS-5697?page=com.atlassian.jira.plug... ]
Mario Fusco updated DROOLS-5697:
--------------------------------
Sprint: 2020 Week 43-45 (from Okt 19)
> Make exec model's groupBy() composable
> --------------------------------------
>
> Key: DROOLS-5697
> URL: https://issues.redhat.com/browse/DROOLS-5697
> Project: Drools
> Issue Type: Enhancement
> Components: executable model
> Affects Versions: 7.44.0.Final
> Reporter: Lukáš Petrovický
> Assignee: Mario Fusco
> Priority: Major
>
> In some of the OptaPlanner examples, we have Constraint Streams like this:
> {code:java}
> .groupBy(ProcessAssignment::getService, count())
> .groupBy(Service::getTag, max((service, count) -> count))
> {code}
> This will:
> - Take all ProcessAssigment instances.
> - Count all such instances which run on the same Service.
> - Out of all the pairs of (service, count) find the maximum count where the services share the same Tag.
> This is an example of groupBy composition. Currently, we implement it with the old, inefficient groupBy. That implementation looks something like this:
> {noformat}
> when
> $tuples: List<Tuple<Service, Integer>> from accumulate(
> $p: ProcessAssignment(),
> ...
> groupBy(ProcessAssignment::getService, count())
> )
> $tuples2: List<Tuple<String, Integer>> from accumulate(
> $tuple: Tuple<Service, Integer> from $tuples,
> ...
> groupBy(Service::getTag, max($tuple._2))
> )
> $result: Tuple<String, Integer> from $tuples2
> then
> System.out.println($result);
> end
> {noformat}
> We'd like the new groupBy construct to be capable of composition instead.
--
This message was sent by Atlassian Jira
(v7.13.8#713008)
5 years, 7 months
[JBoss JIRA] (DROOLS-5697) Make exec model's groupBy() composable
by Lukáš Petrovický (Jira)
[ https://issues.redhat.com/browse/DROOLS-5697?page=com.atlassian.jira.plug... ]
Lukáš Petrovický updated DROOLS-5697:
-------------------------------------
Description:
In some of the OptaPlanner examples, we have Constraint Streams like this:
{code:java}
.groupBy(ProcessAssignment::getService, count())
.groupBy(Service::getTag, max((service, count) -> count))
{code}
This will:
- Take all ProcessAssigment instances.
- Count all such instances which run on the same Service.
- Out of all the pairs of (service, count) find the maximum count where the services share the same Tag.
This is an example of groupBy composition. Currently, we implement it with the old, inefficient groupBy. That implementation looks something like this:
{noformat}
when
$tuples: List<Tuple<Service, Integer>> from accumulate(
$p: ProcessAssignment(),
...
groupBy(ProcessAssignment::getService, count())
)
$tuples2: List<Tuple<String, Integer>> from accumulate(
$tuple: Tuple<Service, Integer> from $tuples,
...
groupBy(Service::getTag, max($tuple._2))
)
$result: Tuple<String, Integer> from $tuples2
then
System.out.println($result);
end
{noformat}
We'd like the new groupBy construct to be capable of composition instead.
was:
In some of the OptaPlanner examples, we have Constraint Streams like this:
{code:java}
.groupBy(ProcessAssignment::getService, count())
.groupBy(max((service, count) -> count))
{code}
This will:
- Take all ProcessAssigment instances.
- Count all such instances which run on the same Service.
- Out of all the pairs of (service, count) find the one with the most count.
This is an example of groupBy composition. Currently, we implement it with the old, inefficient groupBy. That implementation looks something like this:
{noformat}
when
$tuples: List<Tuple<Service, Integer>> from accumulate(
$p: ProcessAssignment(),
...
groupBy(ProcessAssignment::getService, count())
)
accumulate(
$tuple: Tuple<Service, Integer> from $tuples,
...
$result: max($tuple._2)
)
then
System.out.println($result);
end
{noformat}
We'd like the new groupBy construct to be capable of composition instead.
> Make exec model's groupBy() composable
> --------------------------------------
>
> Key: DROOLS-5697
> URL: https://issues.redhat.com/browse/DROOLS-5697
> Project: Drools
> Issue Type: Enhancement
> Components: executable model
> Affects Versions: 7.44.0.Final
> Reporter: Lukáš Petrovický
> Assignee: Mario Fusco
> Priority: Major
>
> In some of the OptaPlanner examples, we have Constraint Streams like this:
> {code:java}
> .groupBy(ProcessAssignment::getService, count())
> .groupBy(Service::getTag, max((service, count) -> count))
> {code}
> This will:
> - Take all ProcessAssigment instances.
> - Count all such instances which run on the same Service.
> - Out of all the pairs of (service, count) find the maximum count where the services share the same Tag.
> This is an example of groupBy composition. Currently, we implement it with the old, inefficient groupBy. That implementation looks something like this:
> {noformat}
> when
> $tuples: List<Tuple<Service, Integer>> from accumulate(
> $p: ProcessAssignment(),
> ...
> groupBy(ProcessAssignment::getService, count())
> )
> $tuples2: List<Tuple<String, Integer>> from accumulate(
> $tuple: Tuple<Service, Integer> from $tuples,
> ...
> groupBy(Service::getTag, max($tuple._2))
> )
> $result: Tuple<String, Integer> from $tuples2
> then
> System.out.println($result);
> end
> {noformat}
> We'd like the new groupBy construct to be capable of composition instead.
--
This message was sent by Atlassian Jira
(v7.13.8#713008)
5 years, 7 months
[JBoss JIRA] (DROOLS-5697) Make exec model's groupBy() composable
by Mario Fusco (Jira)
[ https://issues.redhat.com/browse/DROOLS-5697?page=com.atlassian.jira.plug... ]
Mario Fusco reassigned DROOLS-5697:
-----------------------------------
Assignee: Mario Fusco (was: Luca Molteni)
> Make exec model's groupBy() composable
> --------------------------------------
>
> Key: DROOLS-5697
> URL: https://issues.redhat.com/browse/DROOLS-5697
> Project: Drools
> Issue Type: Enhancement
> Components: executable model
> Affects Versions: 7.44.0.Final
> Reporter: Lukáš Petrovický
> Assignee: Mario Fusco
> Priority: Major
>
> In some of the OptaPlanner examples, we have Constraint Streams like this:
> {code:java}
> .groupBy(ProcessAssignment::getService, count())
> .groupBy(max((service, count) -> count))
> {code}
>
> This will:
> - Take all ProcessAssigment instances.
> - Count all such instances which run on the same Service.
> - Out of all the pairs of (service, count) find the one with the most count.
> This is an example of groupBy composition. Currently, we implement it with the old, inefficient groupBy. That implementation looks something like this:
> {noformat}
> when
> $tuples: List<Tuple<Service, Integer>> from accumulate(
> $p: ProcessAssignment(),
> ...
> groupBy(ProcessAssignment::getService, count())
> )
> accumulate(
> $tuple: Tuple<Service, Integer> from $tuples,
> ...
> $result: max($tuple._2)
> )
> then
> System.out.println($result);
> end
> {noformat}
> We'd like the new groupBy construct to be capable of composition instead.
--
This message was sent by Atlassian Jira
(v7.13.8#713008)
5 years, 7 months