Ejemplo n.º 1
0
 protected boolean _preConnect(String cluster_name) throws Exception {
   if (state == State.CONNECTED) {
     if (log.isTraceEnabled()) log.trace("already connected to " + this.cluster_name);
     return false;
   }
   checkClosed();
   setAddress();
   State old_state = state;
   state = State.CONNECTING;
   try {
     startStack(cluster_name);
   } catch (Exception ex) {
     state = old_state;
     throw ex;
   }
   return true;
 }