[rules-users] Possible bug

Pavel Tavoda pavel.tavoda at gmail.com
Mon Jun 28 11:16:58 EDT 2010


Maybe yes, advice is generic but I looked at source code and from what
I see iteration is going through some internal cache which is maybe
concurrently modified not through items of my Hash.
   for ( ObjectTypeNode node : ruleBase.getRete().getObjectTypeNodes(
this.entryPoint ).values() ) {

Anyway modifying fact will be wrong idea ;-).

Pavel

On Mon, Jun 28, 2010 at 3:36 PM, PAYET, Manuel
<manuel.payet at capgemini.com> wrote:
> My last message presumes that you inserted a Map fact, was I wrong?
>
> -----Message d'origine-----
> De : rules-users-bounces at lists.jboss.org [mailto:rules-users-bounces at lists.jboss.org] De la part de Pavel Tavoda
> Envoyé : lundi 28 juin 2010 15:29
> À : Rules Users List
> Objet : [rules-users] Possible bug
>
> Hello,
> we are using official 5.0 release and sometimes (very rarely) we get following error:
> java.util.ConcurrentModificationException
>        at java.util.HashMap$HashIterator.nextEntry(HashMap.java:793)
>        at java.util.HashMap$ValueIterator.next(HashMap.java:822)
>        at org.drools.reteoo.ClassObjectTypeConf.getMatchingObjectTypes(ClassObjectTypeConf.java:171)
>        at org.drools.reteoo.ClassObjectTypeConf.getObjectTypeNodes(ClassObjectTypeConf.java:163)
>        at org.drools.reteoo.EntryPointNode.assertObject(EntryPointNode.java:143)
>        at org.drools.common.AbstractWorkingMemory.insert(AbstractWorkingMemory.java:1046)
>        at org.drools.common.AbstractWorkingMemory.insert(AbstractWorkingMemory.java:1001)
>        at org.drools.common.AbstractWorkingMemory.insert(AbstractWorkingMemory.java:788)
>        at org.drools.process.command.InsertObjectCommand.execute(InsertObjectCommand.java:22)
>        at org.drools.process.command.InsertObjectCommand.execute(InsertObjectCommand.java:7)
>        at org.drools.runtime.impl.BatchExecutionImpl.execute(BatchExecutionImpl.java:23)
>        at org.drools.runtime.impl.BatchExecutionImpl.execute(BatchExecutionImpl.java:9)
>        at org.drools.impl.StatelessKnowledgeSessionImpl.execute(StatelessKnowledgeSessionImpl.java:225)
>        at org.fornax.cartridges.sculptor.framework.drools.DroolsAdvice.applyCompanyPolicy(DroolsAdvice.java:150)
>
> We are using AspectJ advice for starting rule evaluation for every service call. Hope we are doing everything right in code. Full source code of advice can be found at:
> http://fisheye3.atlassian.com/browse/fornax/trunk/cartridges/sculptor/fornax-cartridges-sculptor-framework/src/main/java/org/fornax/cartridges/sculptor/framework/drools/DroolsAdvice.java?r=6407
>
> Regards
>
> Pavel
> _______________________________________________
> rules-users mailing list
> rules-users at lists.jboss.org
> https://lists.jboss.org/mailman/listinfo/rules-users
>
>
>
>
>
>
> This message contains information that may be privileged or confidential and is the property of the Capgemini Group. It is
> intended only for the person to whom it is addressed. If you are not the intended recipient, you are not authorized to
> read, print, retain, copy, disseminate, distribute, or use this message or any part thereof. If you receive this message
> in error, please notify the sender immediately and delete all copies of this message.
>
>
> _______________________________________________
> rules-users mailing list
> rules-users at lists.jboss.org
> https://lists.jboss.org/mailman/listinfo/rules-users
>




More information about the rules-users mailing list