static void init(DM dm,HashMap map){
  HashSet crashedGrantors=new HashSet();
  if (!dm.isAdam()) {
    Set others=dm.getOtherDistributionManagerIds();
    if (!others.isEmpty()) {
      ElderInitProcessor processor=new ElderInitProcessor(dm,others,map,crashedGrantors);
      ElderInitMessage.send(others,dm,processor);
      try {
        processor.waitForRepliesUninterruptibly();
      }
 catch (      ReplyException e) {
        e.handleAsUnexpected();
      }
    }
  }
  GrantorRequestProcessor.readyForElderRecovery(dm.getSystem(),null,null);
  DLockService.recoverLocalElder(dm,map,crashedGrantors);
{
    Iterator it=crashedGrantors.iterator();
    while (it.hasNext()) {
      map.put(it.next(),new GrantorInfo(null,0,0,true));
    }
  }
}

static void init ( DM dm , HashMap map ) { HashSet crashedGrantors = new HashSet ( ) ; if ( ! dm . isAdam ( ) ) { Set others = dm . getOtherDistributionManagerIds ( ) ; if ( ! others . isEmpty ( ) ) { ElderInitProcessor processor = new ElderInitProcessor ( dm , others , map , crashedGrantors ) ; ElderInitMessage . send ( others , dm , processor ) ; try { processor . waitForRepliesUninterruptibly ( ) ; } catch ( ReplyException e ) { e . handleAsUnexpected ( ) ; } } } GrantorRequestProcessor . readyForElderRecovery ( dm . getSystem ( ) , null , null ) ; DLockService . recoverLocalElder ( dm , map , crashedGrantors ) ; { Iterator it = crashedGrantors . iterator ( ) ; while ( it . hasNext ( ) ) { map . put ( it . next ( ) , new GrantorInfo ( null , 0 , 0 , true ) ) ; } } }
initializes elderstate map by recovering all existing grantors and crashed grantors in the current ds .
