public TopologyMemberImpl updateBackup(final TopologyMemberImpl memberInput){
  final String nodeId=memberInput.getNodeId();
  if (logger.isTraceEnabled()) {
    logger.trace(this + "::updateBackup::" + nodeId+ ", memberInput="+ memberInput);
  }
synchronized (this) {
    TopologyMemberImpl currentMember=getMember(nodeId);
    if (currentMember == null) {
      if (logger.isTraceEnabled()) {
        logger.trace("There's no live to be updated on backup update, node=" + nodeId + " memberInput="+ memberInput,new Exception("trace"));
      }
      currentMember=memberInput;
      topology.put(nodeId,currentMember);
    }
    TopologyMemberImpl newMember=new TopologyMemberImpl(nodeId,currentMember.getBackupGroupName(),currentMember.getScaleDownGroupName(),currentMember.getLive(),memberInput.getBackup());
    newMember.setUniqueEventID(System.currentTimeMillis());
    topology.remove(nodeId);
    topology.put(nodeId,newMember);
    sendMemberUp(nodeId,newMember);
    return newMember;
  }
}

public TopologyMemberImpl updateBackup ( final TopologyMemberImpl memberInput ) { final String nodeId = memberInput . getNodeId ( ) ; if ( logger . isTraceEnabled ( ) ) { logger . trace ( this + "::updateBackup::" + nodeId + ", memberInput=" + memberInput ) ; } synchronized ( this ) { TopologyMemberImpl currentMember = getMember ( nodeId ) ; if ( currentMember == null ) { if ( logger . isTraceEnabled ( ) ) { logger . trace ( "There's no live to be updated on backup update, node=" + nodeId + " memberInput=" + memberInput , new Exception ( "trace" ) ) ; } currentMember = memberInput ; topology . put ( nodeId , currentMember ) ; } TopologyMemberImpl newMember = new TopologyMemberImpl ( nodeId , currentMember . getBackupGroupName ( ) , currentMember . getScaleDownGroupName ( ) , currentMember . getLive ( ) , memberInput . getBackup ( ) ) ; newMember . setUniqueEventID ( System . currentTimeMillis ( ) ) ; topology . remove ( nodeId ) ; topology . put ( nodeId , newMember ) ; sendMemberUp ( nodeId , newMember ) ; return newMember ; } }
this is called by the server when the node is activated from backup state . it will always succeed
