[rules-users] KnowledgeAgent ChangeSet failing to reload resources

Fink, Eric [USA] fink_eric at bah.com
Thu Nov 4 10:41:47 EDT 2010


Greetings.  I am using Drools 5.1.1's KnowledgeAgent ChangeSet functionality and have come across an issue.

here is the use case:

Fire up the application with a valid DRL file. Works as designed.
Update the DRL file. ChangeSet senses updated file, KnowledgeBase is updated with updated rules, yadda, yadda. Works as designed.
Update the DRL file and introduce errors in the LHS of the rule. For example, I changed Sensor to Sccensor in the example below and $masterId is not defined. The following is reported as expected:

KnowledgeAgent rebuilding KnowledgeBase using ChangeSet
[2010:11:308 09:11:515:info] KnowledgeAgent performing an incremental build of the ChangeSet
[2010:11:308 09:11:843:debug] KnowledgeAgent has KnowledgeBuilder errors  object=Unable to resolve ObjectType 'Sccensor' : [Rule name='18) sensorCount derived variable']
Rule Compilation error : [Rule name='18) sensorCount derived variable']
        bass/enrichment/Rule_18__sensorCount_derived_variable_0.java (7:590) : $masterID cannot be resolved
        bass/enrichment/Rule_18__sensorCount_derived_variable_0.java (8:624) : $masterID cannot be resolved
        bass/enrichment/Rule_18__sensorCount_derived_variable_0.java (9:769) : $masterID cannot be resolved

Update the DRL file to the previously working version. The ChangeSet never senses that the file has been updated. It just runs along checking every x seconds.

Has anyone experienced this? Is there a listener that should be firing somewhere? 

Thanks is advance.

- Eric



More information about the rules-users mailing list