@Override protected final void closeNoLock(String reason){
  if (isClosed.compareAndSet(false,true)) {
    assert rwl.isWriteLockedByCurrentThread() || failEngineLock.isHeldByCurrentThread() : "Either the write lock must be held or the engine must be currently be failing itself";
    try {
      this.versionMap.clear();
      try {
        IOUtils.close(searcherManager);
      }
 catch (      Throwable t) {
        logger.warn("Failed to close SearcherManager",t);
      }
      try {
        IOUtils.close(translog);
      }
 catch (      Throwable t) {
        logger.warn("Failed to close translog",t);
      }
      logger.trace("rollback indexWriter");
      try {
        indexWriter.rollback();
      }
 catch (      AlreadyClosedException e) {
      }
      logger.trace("rollback indexWriter done");
    }
 catch (    Throwable e) {
      logger.warn("failed to rollback writer on close",e);
    }
 finally {
      store.decRef();
      logger.debug("engine closed [{}]",reason);
    }
  }
}

@ Override protected final void closeNoLock ( String reason ) { if ( isClosed . compareAndSet ( false , true ) ) { assert rwl . isWriteLockedByCurrentThread ( ) || failEngineLock . isHeldByCurrentThread ( ) : "Either the write lock must be held or the engine must be currently be failing itself" ; try { this . versionMap . clear ( ) ; try { IOUtils . close ( searcherManager ) ; } catch ( Throwable t ) { logger . warn ( "Failed to close SearcherManager" , t ) ; } try { IOUtils . close ( translog ) ; } catch ( Throwable t ) { logger . warn ( "Failed to close translog" , t ) ; } logger . trace ( "rollback indexWriter" ) ; try { indexWriter . rollback ( ) ; } catch ( AlreadyClosedException e ) { } logger . trace ( "rollback indexWriter done" ) ; } catch ( Throwable e ) { logger . warn ( "failed to rollback writer on close" , e ) ; } finally { store . decRef ( ) ; logger . debug ( "engine closed [{}]" , reason ) ; } } }
closes the engine without acquiring the write lock . this should only be called while the write lock is hold or in a disaster condition ie . if the engine is failed .
