Skip to content

Commit

Permalink
JGRP-1450 don't forget who is suspected
Browse files Browse the repository at this point in the history
  • Loading branch information
dimbleby authored and belaban committed Apr 23, 2012
1 parent ffa98d8 commit d77c440
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions src/org/jgroups/protocols/pbcast/ParticipantGmsImpl.java
Original file line number Original file line Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ public void init() throws Exception {
public void join(Address mbr, boolean useFlushIfPresent) { public void join(Address mbr, boolean useFlushIfPresent) {
wrongMethod("join"); wrongMethod("join");
} }

public void joinWithStateTransfer(Address mbr,boolean useFlushIfPresent) { public void joinWithStateTransfer(Address mbr,boolean useFlushIfPresent) {
wrongMethod("join"); wrongMethod("join");
} }
Expand Down Expand Up @@ -85,7 +85,7 @@ public void handleJoinResponse(JoinRsp join_rsp) {
} }
} }


public void handleLeaveResponse() { public void handleLeaveResponse() {
leave_promise.setResult(true); // unblocks thread waiting in leave() leave_promise.setResult(true); // unblocks thread waiting in leave()
} }


Expand All @@ -110,7 +110,7 @@ public void handleMembershipChange(Collection<Request> requests) {
if(req.type == Request.SUSPECT) if(req.type == Request.SUSPECT)
suspectedMembers.add(req.mbr); suspectedMembers.add(req.mbr);
} }

if(suspectedMembers.isEmpty()) if(suspectedMembers.isEmpty())
return; return;


Expand All @@ -126,12 +126,12 @@ public void handleMembershipChange(Collection<Request> requests) {
if(log.isDebugEnabled()) if(log.isDebugEnabled())
log.debug("members are " + gms.members + ", coord=" + gms.local_addr + ": I'm the new coord !"); log.debug("members are " + gms.members + ", coord=" + gms.local_addr + ": I'm the new coord !");


suspected_mbrs.clear();
gms.becomeCoordinator(); gms.becomeCoordinator();
for(Address mbr: suspectedMembers) { for(Address mbr: suspected_mbrs) {
gms.getViewHandler().add(new Request(Request.SUSPECT, mbr, true)); gms.getViewHandler().add(new Request(Request.SUSPECT, mbr, true));
gms.ack_collector.suspect(mbr); gms.ack_collector.suspect(mbr);
} }
suspected_mbrs.clear();
} }
} }


Expand Down

0 comments on commit d77c440

Please sign in to comment.