Bug 851272 - KnowledgeAgent: Doesn't remove insertLogical() Facts correctly with incremental build
Summary: KnowledgeAgent: Doesn't remove insertLogical() Facts correctly with increment...
Keywords:
Status: VERIFIED
Alias: None
Product: JBoss Enterprise BRMS Platform 5
Classification: JBoss
Component: BRE (Expert, Fusion)
Version: BRMS 5.3.1
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
: ---
Assignee: Mario Fusco
QA Contact:
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2012-08-23 16:01 UTC by Mario Fusco
Modified: 2023-05-31 22:25 UTC (History)
0 users

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed:
Type: Bug
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Issue Tracker JBRULES-3543 0 Major Resolved KnowledgeAgent: Doesn't remove insertLogical() Facts correctly with incremental build 2013-10-21 11:38:31 UTC

Description Mario Fusco 2012-08-23 16:01:54 UTC
When the KnowledgeAgent is used with the property "newInstance = false" (incremental build), then facts inserted with insertLogical() don't always get removed correctly when there is a rule update. As i understand it, all facts which are inserted via insertLogical() should be retracted when the old rule is removed. With some rules of mine this is done correctly, but with other only a part is getting removed.

I created a little test project based upon the drools example project where the problem always happens. After setting up the KnowledgeAgent, KnowledgeBase and StatefulKnowledgeSession, 3 facts are inserted into the session, which fires 9 consequences. Each consequence creates an object and inserts it via insertLogical. When i switch the two statements of the LHS from

when
        Message(status == Message.HELLO)
        Message()

TO:

when
        Message()
        Message(status == Message.HELLO)

When the rule is removed only 3 of the 9 objects get retracted.

The code and a log for the eclipse audit view from this this case are attached

Comment 1 Radovan Synek 2012-09-20 09:03:13 UTC
Verified on 5.3.1.BRMS-ER1


Note You need to log in before you can comment on or make changes to this bug.