state_xfer_mutex.notify();
state_xfer_mutex.notifyAll();
    public void down(Event evt) {        Object coord, state;        Vector event_list=null;        StateTransferInfo info;        switch(evt.getType()) {            case Event.TMP_VIEW:            case Event.VIEW_CHANGE:                Vector new_members=((View)evt.getArg()).getMembers();                synchronized(members) {                    members.removeAllElements();                    if(new_members != null && new_members.size() > 0)                        for(int k=0; k < new_members.size(); k++)                            members.addElement(new_members.elementAt(k));                }                break;            case Event.GET_STATE:       // generated by JChannel.getState()                info=(StateTransferInfo)evt.getArg();                coord=determineCoordinator();                if(coord == null || coord.equals(local_addr)) {                    if(log.isWarnEnabled()) log.warn("GET_STATE: coordinator is null");                    event_list=new Vector(1);                    event_list.addElement(new Event(Event.GET_STATE_OK, null));                    passUp(new Event(Event.STOP_QUEUEING, event_list));                    return;             // don't pass down any further !                }                sendMakeCopyMessage();  // multicast MAKE_COPY to all members (including me)                if(info.type == StateTransferInfo.GET_FROM_MANY)                    state=getStateFromMany(info.targets);                else                    state=getStateFromSingle(info.target);                /* Pass up the state to the application layer (insert into JChannel's event queue */                event_list=new Vector(1);                event_list.addElement(new Event(Event.GET_STATE_OK, state));                /* Now stop queueing */                passUp(new Event(Event.STOP_QUEUEING, event_list));                return;                 // don't pass down any further !            case Event.GET_APPLSTATE_OK:                synchronized(state_xfer_mutex) {                    cached_state=(byte[])evt.getArg();                    state_xfer_mutex.notify();                }                return;                 // don't pass down any further !        }        passDown(evt);              // pass on to the layer below us    }