Accumulate should be implemented with left-input incremental so they don't start from
scratch on every left-input retraction/assertion
--------------------------------------------------------------------------------------------------------------------------------------
Key: JBRULES-2238
URL:
https://jira.jboss.org/jira/browse/JBRULES-2238
Project: Drools
Issue Type: Feature Request
Security Level: Public (Everyone can see)
Components: drools-core (expert)
Affects Versions: 5.0.1.FINAL
Reporter: Geoffrey De Smet
Assignee: Mark Proctor
The current accumulate implementation has a severe performance loss in the drools-solver
context.
Edson said that this issue could be the culprit.
However, for this to be implemented the true modify feature should first be implemented.
See the discussion "Why is this DRL twice as slow?" on the dev user list.
From IRC:
<ge0ffrey> more and more of my experiments show the poisones nature of accumulate
for drools-solver. Probably because they are backwards chained (as I understand it?). Of
course accummulate is great for many use cases, just not drools-solver.
<ge0ffrey> The problem is, I have no way to workaround them. I need the sum of my
logically inserted objects.
<etirelli> ge0ffrey: no, accumulate are implemented as forward chain as usual
<etirelli> the problem is that a left-input retraction on an accumulate node will
throw away any result and a leftinput assert will recalculate everything from scratch
<ge0ffrey> What do you mean by "must fully recalculate"?
<etirelli> mean from scratch
<ge0ffrey> Why does it do that?
<etirelli> remember that modify = retract+assert
<ge0ffrey> And right-input retractions won't recalculate everything from
scratch?
<etirelli> no... right input are incremental
<ge0ffrey> would making leftinput assert incremental too be possible?
<etirelli> ge0ffrey: the only way to do left-input incremental is with a feature
called "true modify"
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
https://jira.jboss.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira