Race condition when creating stateful working memory
----------------------------------------------------
Key: JBESB-1907
URL:
https://jira.jboss.org/jira/browse/JBESB-1907
Project: JBoss ESB
Issue Type: Bug
Security Level: Public (Everyone can see)
Components: Content Based Routing
Affects Versions: 4.4
Reporter: Jiri Pechanec
Priority: Critical
Fix For: 4.4 CP1
If more than one thread is used the following code is buggy
private StatefulSession getStatefulSession( final RuleBase ruleBase )
{
final StatefulSession[] statefulSessions =
ruleBase.getStatefulSessions();
boolean existingSession = statefulSessions != null &&
statefulSessions.length > 0;
return existingSession ? statefulSessions[0] :
ruleBase.newStatefulSession();
}
It can lead into initiation and use of two working memories for the first messages
coming.
--
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