Class RpcEndpoint.MainThreadExecutor

    • Method Detail

      • schedule

        public ScheduledFuture<?> schedule​(Runnable command,
                                           long delay,
                                           TimeUnit unit)
        The mainScheduledExecutor manages the task and sends it to the gateway after the given delay.
        Specified by:
        schedule in interface org.apache.flink.util.concurrent.ScheduledExecutor
        Parameters:
        command - the task to execute in the future
        delay - the time from now to delay the execution
        unit - the time unit of the delay parameter
        Returns:
        a ScheduledFuture representing the completion of the scheduled task
      • schedule

        public <V> ScheduledFuture<V> schedule​(Callable<V> callable,
                                               long delay,
                                               TimeUnit unit)
        The mainScheduledExecutor manages the given callable and sends it to the gateway after the given delay.
        Specified by:
        schedule in interface org.apache.flink.util.concurrent.ScheduledExecutor
        Type Parameters:
        V - result type of the callable
        Parameters:
        callable - the callable to execute
        delay - the time from now to delay the execution
        unit - the time unit of the delay parameter
        Returns:
        a ScheduledFuture which holds the future value of the given callable
      • scheduleAtFixedRate

        public ScheduledFuture<?> scheduleAtFixedRate​(Runnable command,
                                                      long initialDelay,
                                                      long period,
                                                      TimeUnit unit)
        Specified by:
        scheduleAtFixedRate in interface org.apache.flink.util.concurrent.ScheduledExecutor
      • scheduleWithFixedDelay

        public ScheduledFuture<?> scheduleWithFixedDelay​(Runnable command,
                                                         long initialDelay,
                                                         long delay,
                                                         TimeUnit unit)
        Specified by:
        scheduleWithFixedDelay in interface org.apache.flink.util.concurrent.ScheduledExecutor