Interface StageRunner.StageMessageDispatcher<E>
-
- All Superinterfaces:
AutoCloseable
- Enclosing interface:
- StageRunner
public static interface StageRunner.StageMessageDispatcher<E> extends AutoCloseable
A dispatcher for inter-stage communication. It allows for returning a result to aSorter
viasendResult(MutableObjectIterator)
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description org.apache.flink.runtime.operators.sort.CircularElement<E>
poll(StageRunner.SortStage stage)
Retrieves and removes the head of the given stage queue, or returnsnull
if the queue is empty.void
send(StageRunner.SortStage stage, org.apache.flink.runtime.operators.sort.CircularElement<E> element)
Sends a message to the given stage.void
sendResult(MutableObjectIterator<E> result)
Sends a result to the correspondingSorter
.org.apache.flink.runtime.operators.sort.CircularElement<E>
take(StageRunner.SortStage stage)
Retrieves and removes the head of the given queue, waiting if necessary until an element becomes available.-
Methods inherited from interface java.lang.AutoCloseable
close
-
-
-
-
Method Detail
-
send
void send(StageRunner.SortStage stage, org.apache.flink.runtime.operators.sort.CircularElement<E> element)
Sends a message to the given stage.
-
take
org.apache.flink.runtime.operators.sort.CircularElement<E> take(StageRunner.SortStage stage) throws InterruptedException
Retrieves and removes the head of the given queue, waiting if necessary until an element becomes available.- Returns:
- the head of the queue
- Throws:
InterruptedException
-
poll
org.apache.flink.runtime.operators.sort.CircularElement<E> poll(StageRunner.SortStage stage)
Retrieves and removes the head of the given stage queue, or returnsnull
if the queue is empty.- Returns:
- the head of the queue, or
null
if the queue is empty
-
sendResult
void sendResult(MutableObjectIterator<E> result)
Sends a result to the correspondingSorter
.
-
-