[jboss-jira] [JBoss JIRA] (JBRULES-3616) ConcurrentModificationException in AbstractRuleBase.removePackage
Lukas Stampf (JIRA)
jira-events at lists.jboss.org
Wed Sep 5 07:32:33 EDT 2012
[ https://issues.jboss.org/browse/JBRULES-3616?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Lukas Stampf updated JBRULES-3616:
----------------------------------
Description:
At AbstractRuleBase.removePackage:
//and now the rule flows
{code}
final Map flows = pkg.getRuleFlows();
for (final Iterator iter = flows.keySet().iterator(); iter.hasNext();) {
removeProcess( (String) iter.next() );
}
{code}
At AbstractRuleBase.removeProcess
{code}
this.pkgs.get(process.getPackageName()).removeRuleFlow(id);
{code}
removeProcess removes an object from the Map referenced by the flows variable in removePackage. Since the iterator is based on this variable it leads to a ConcurrentModificationError at iter.next().
was:
At AbstractRuleBase.removePackage:
//and now the rule flows
final Map flows = pkg.getRuleFlows();
for (final Iterator iter = flows.keySet().iterator(); iter.hasNext();) {
removeProcess( (String) iter.next() );
}
At AbstractRuleBase.removeProcess
this.pkgs.get(process.getPackageName()).removeRuleFlow(id);
removeProcess removes an object from the Map referenced by the flows variable in removePackage. Since the iterator is based on this variable it leads to a ConcurrentModificationError at iter.next().
> ConcurrentModificationException in AbstractRuleBase.removePackage
> -----------------------------------------------------------------
>
> Key: JBRULES-3616
> URL: https://issues.jboss.org/browse/JBRULES-3616
> Project: Drools
> Issue Type: Bug
> Security Level: Public(Everyone can see)
> Components: drools-core
> Affects Versions: 5.4.0.Final, 5.5.0.Beta1
> Reporter: Lukas Stampf
> Assignee: Mark Proctor
>
> At AbstractRuleBase.removePackage:
> //and now the rule flows
> {code}
> final Map flows = pkg.getRuleFlows();
> for (final Iterator iter = flows.keySet().iterator(); iter.hasNext();) {
> removeProcess( (String) iter.next() );
> }
> {code}
> At AbstractRuleBase.removeProcess
> {code}
> this.pkgs.get(process.getPackageName()).removeRuleFlow(id);
> {code}
> removeProcess removes an object from the Map referenced by the flows variable in removePackage. Since the iterator is based on this variable it leads to a ConcurrentModificationError at iter.next().
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira
More information about the jboss-jira
mailing list