Publish member events when state change first seen, see #3075

* Remove InstantMemberEvent
This commit is contained in:
Patrik Nordwall 2013-03-05 21:05:11 +01:00
parent 5c7747e7fa
commit 5b844ec1e6
32 changed files with 145 additions and 517 deletions

View file

@ -63,12 +63,10 @@ class ClusterSpec extends AkkaSpec(ClusterSpec.config) with ImplicitSender {
"initially become singleton cluster when joining itself and reach convergence" in {
clusterView.members.size must be(0) // auto-join = off
cluster.join(selfAddress)
Thread.sleep(5000)
leaderActions() // Joining -> Up
awaitCond(clusterView.isSingletonCluster)
clusterView.self.address must be(selfAddress)
clusterView.members.map(_.address) must be(Set(selfAddress))
clusterView.status must be(MemberStatus.Joining)
leaderActions()
awaitCond(clusterView.status == MemberStatus.Up)
}
@ -76,7 +74,6 @@ class ClusterSpec extends AkkaSpec(ClusterSpec.config) with ImplicitSender {
try {
cluster.subscribe(testActor, classOf[ClusterEvent.ClusterDomainEvent])
// first, is in response to the subscription
expectMsgClass(classOf[ClusterEvent.InstantClusterState])
expectMsgClass(classOf[ClusterEvent.CurrentClusterState])
cluster.publishCurrentClusterState()