boolean (boolean attempt) { if (attempt && myStateLock.isLocked()) return false; try (LockToken ignored = attempt ? attemptLock() : acquireLock()) { return isIdle() && !hasPendingWork() && !isNodeActionsPending(); } catch (InterruptedException e) { LOG.info(e); return false; } }