[
https://issues.jboss.org/browse/JBAS-9481?page=com.atlassian.jira.plugin....
]
Dennis Reed updated JBAS-9481:
------------------------------
Steps to Reproduce:
Deploy attached test.jar (contains an HASingleton that logs start and stop) on both nodes
of a 2-node cluster.
Start one instance of the cluster.
On the second node, use the attached byteman script.
Start the second node.
While the second node is paused ("[Pausing]" printed in the log), stop the first
node (triggering a view change, and starting the HASingleton).
(Note: it will pause once for each HASingleton, since narrowing it further would require
much more complication in the byteman script.
If you don't see the HASingleton starting when you stop the first node, it was the
wrong pause).
When the pause ends...
Expected result: the HASingleton is still running (it's on the only member of the
cluster)
Actual result: the HASingleton is stopped, causing it to not be running anywhere in the
cluster.
was:
Deploy attached test.jar (contains an HASingleton that logs start and stop) on both nodes
of a 2-node cluster.
Start one instance of the cluster.
On the second node, use the attached byteman script.
Start the second node.
While the second node is paused ("[Pausing]" printed in the log), stop the first
node (triggering a view change, and starting the HASingleton).
When the pause ends...
Expected result: the HASingleton is still running (it's on the only member of the
cluster)
Actual result: the HASingleton is stopped, causing it to not be running anywhere in the
cluster.
race condition can break HASingleton functionality
--------------------------------------------------
Key: JBAS-9481
URL:
https://issues.jboss.org/browse/JBAS-9481
Project: Application Server 3 4 5 and 6
Issue Type: Bug
Security Level: Public(Everyone can see)
Components: Clustering
Affects Versions: JBossAS-5.1.0.GA
Reporter: Dennis Reed
Assignee: Paul Ferraro
Attachments: JBAS-9481.btm, test.jar
HASingletonImpl#registerDRMListener has a race condition with partitionTopologyChanged,
which can cause views to be processed
out of order, and HASingletons to be started when they should be stopped, or stopped when
they should be started.
The problem is that the thread calling registerDRMListener (which calls
partitionTopologyChanged) is not synchronized against other threads that call
partitionTopologyChanged.
This was introduced by the fix for
https://issues.jboss.org/browse/JBAS-2647.
To fix the issue, partitionTopology must process the view saved in viewReference in the
correct order, and registerDRMListener's
call to partitionTopology must be synchronized against other threads calling it (without
causing a regression of JBAS-2647).
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators:
https://issues.jboss.org/secure/ContactAdministrators!default.jspa
For more information on JIRA, see:
http://www.atlassian.com/software/jira