Discussion related to
http://jira.jboss.com/jira/browse/JBAS-4229.
The way a clustered service is aware that a 'split brain' situation has occurred
and is now healed is by receiving a MergeView from JGroups. Problem here is that
HASingletonSupport does not receive view change notifications from JGroups -- it receives
service topology change notifications from DistributedReplicantManager. (The topology of a
service can change for reasons other than view changes; e.g. undeploy of the service on a
node.) The topology change notification does not include any information as to whether
the change was due to a merge.
In 4.x this can be somewhat shakily resolved by having the topology change callback do
some extra work to try to figure out from HAPartition whether a MergeView has occurred.
That is, register with the HAPartition for membership change events and track whether they
are due to merges.
I say shakily resolved because the topology change notifications and the view change
notifications come on separate threads with no guaranteed ordering. If numerous events
are received in short order, the potential to have mis-correlation between topology
changes and view changes certainly exists.
In 5.x a cleaner solution is possible, since in a major version I can change the
DRM.replicantListener interface. I can add a boolean flag to the callback so the DRM can
directly notify the singleton that the change was due to a merge.
View the original post :
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4030370#...
Reply to the post :
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&a...