From 7acfa5e0d7a5796ac26216671e9734fb333635b9 Mon Sep 17 00:00:00 2001 From: Jing Ge Date: Fri, 18 Mar 2022 08:31:18 +0100 Subject: [PATCH] [hotfix][doc] fix typo in java doc. --- .../flink/api/common/operators/MailboxExecutor.java | 10 +++++----- .../runtime/tasks/mailbox/MailboxDefaultAction.java | 4 ++-- .../streaming/runtime/tasks/mailbox/TaskMailbox.java | 4 ++-- 3 files changed, 9 insertions(+), 9 deletions(-) diff --git a/flink-core/src/main/java/org/apache/flink/api/common/operators/MailboxExecutor.java b/flink-core/src/main/java/org/apache/flink/api/common/operators/MailboxExecutor.java index 14dfca0c17196..0b44beb9b628a 100644 --- a/flink-core/src/main/java/org/apache/flink/api/common/operators/MailboxExecutor.java +++ b/flink-core/src/main/java/org/apache/flink/api/common/operators/MailboxExecutor.java @@ -30,9 +30,9 @@ import java.util.concurrent.RejectedExecutionException; /** - * {@link java.util.concurrent.Executor} like interface for an build around a mailbox-based - * execution model. {@code MailboxExecutor} can also execute downstream messages of a mailbox by - * yielding control from the task thread. + * {@link java.util.concurrent.Executor} like interface for a build around a mailbox-based execution + * model. {@code MailboxExecutor} can also execute downstream messages of a mailbox by yielding + * control from the task thread. * *

All submission functions can be called from any thread and will enqueue the action for further * processing in a FIFO fashion. @@ -218,7 +218,7 @@ void execute( } /** - * This methods starts running the command at the head of the mailbox and is intended to be used + * This method starts running the command at the head of the mailbox and is intended to be used * by the mailbox thread to yield from a currently ongoing action to another command. The method * blocks until another command to run is available in the mailbox and must only be called from * the mailbox thread. Must only be called from the mailbox thread to not violate the @@ -232,7 +232,7 @@ void execute( void yield() throws InterruptedException, FlinkRuntimeException; /** - * This methods attempts to run the command at the head of the mailbox. This is intended to be + * This method attempts to run the command at the head of the mailbox. This is intended to be * used by the mailbox thread to yield from a currently ongoing action to another command. The * method returns true if a command was found and executed or false if the mailbox was empty. * Must only be called from the mailbox thread to not violate the single-threaded execution diff --git a/flink-streaming-java/src/main/java/org/apache/flink/streaming/runtime/tasks/mailbox/MailboxDefaultAction.java b/flink-streaming-java/src/main/java/org/apache/flink/streaming/runtime/tasks/mailbox/MailboxDefaultAction.java index df3e27a46e606..9449594094f46 100644 --- a/flink-streaming-java/src/main/java/org/apache/flink/streaming/runtime/tasks/mailbox/MailboxDefaultAction.java +++ b/flink-streaming-java/src/main/java/org/apache/flink/streaming/runtime/tasks/mailbox/MailboxDefaultAction.java @@ -42,8 +42,8 @@ interface Suspension { } /** - * This context is a feedback interface for the default action to interact with the mailbox - * execution. In particular it offers ways to signal that the execution of the default action + * This controller is a feedback interface for the default action to interact with the mailbox + * execution. In particular, it offers ways to signal that the execution of the default action * should be finished or temporarily suspended. */ @Internal diff --git a/flink-streaming-java/src/main/java/org/apache/flink/streaming/runtime/tasks/mailbox/TaskMailbox.java b/flink-streaming-java/src/main/java/org/apache/flink/streaming/runtime/tasks/mailbox/TaskMailbox.java index d2c5f35ace940..6915d4b6d1a00 100644 --- a/flink-streaming-java/src/main/java/org/apache/flink/streaming/runtime/tasks/mailbox/TaskMailbox.java +++ b/flink-streaming-java/src/main/java/org/apache/flink/streaming/runtime/tasks/mailbox/TaskMailbox.java @@ -56,7 +56,7 @@ * *

A batch is created with {@link #createBatch()} and consumed with {@link #tryTakeFromBatch()}. * Note that there is no blocking {@code takeFromBatch} as batches can only be created and consumed - * from the * mailbox thread. + * from the mailbox thread. * *

Also note that a batch can only be created in the {@link MailboxProcessor#runMailboxLoop()}. A * batch must not be extended in any of the consuming methods as we may run into task input @@ -125,7 +125,7 @@ public interface TaskMailbox { /** * Creates a batch of mails that can be taken with {@link #tryTakeFromBatch()}. The batch does * not affect {@link #tryTake(int)} and {@link #take(int)}; that is, they return the same mails - * even if no batch would have been created. + * even if no batch had been created. * *

The default batch is empty. Thus, this method must be invoked once before {@link * #tryTakeFromBatch()}.