code: private void reopenSession(){
          if(! closing && getStatus().isConnected()){
              closing = true;
              if(getStatus().isAlive()){
                  setStatus(ConnectionStatus.NOT_CONNECTED);
              }
              closing = false;
          }
      }
docs: When connect has exception and the session still not out of time.
  Reopen the session to server.
  
  It doesn't clean the sessionId, sessionPassword, authdata and serverId. the ConnectionThread can
  reopen the session use them.
  
  When send ping failed or ClientSocket detects fail, reopen the session again.
  Send packet failed donot reopen the session.