Class CurrentTaskFuture.QueueRunner

  • All Implemented Interfaces:
    java.lang.Runnable
    Enclosing class:
    CurrentTaskFuture

    private static class CurrentTaskFuture.QueueRunner
    extends java.lang.Object
    implements java.lang.Runnable
    • Method Detail

      • run

        public void run()
        Specified by:
        run in interface java.lang.Runnable
      • isWouldBlockRightNow

        private boolean isWouldBlockRightNow​(java.util.HashSet<ActiveDescriptor<?>> cycleChecker,
                                             ActiveDescriptor<?> checkMe)
        This method does a preliminary check of whether or not the descriptor (or any children) would cause the thread to block. If this method returns true then we do not try this service, which can save on going down the getService stack and on the throwing and creation of WouldBlockException
        Parameters:
        cycleChecker - To ensure we are not caught in a cycle
        checkMe - The descriptor to check
        Returns:
        false if as far as we know this descriptor would NOT block, true if we think if we tried this descriptor right now that it would block
      • oneJob

        private void oneJob​(ServiceHandle<?> fService,
                            boolean block)