public class CollectResultIterator<T> extends Object implements CloseableIterator<T>
The behavior of the iterator is slightly different under different checkpointing mode.
NOTE: After using this iterator, the close method MUST be called in order to release job related resources.
CloseableIterator.IteratorAdapter<E>
EMPTY_INSTANCE
Constructor and Description |
---|
CollectResultIterator(AbstractCollectResultBuffer<T> buffer,
CompletableFuture<OperatorID> operatorIdFuture,
String accumulatorName,
int retryMillis) |
CollectResultIterator(CompletableFuture<OperatorID> operatorIdFuture,
TypeSerializer<T> serializer,
String accumulatorName,
CheckpointConfig checkpointConfig) |
Modifier and Type | Method and Description |
---|---|
void |
close() |
boolean |
hasNext() |
T |
next() |
void |
setJobClient(JobClient jobClient) |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
adapterForIterator, adapterForIterator, empty, flatten, fromList, ofElement, ofElements
forEachRemaining, remove
public CollectResultIterator(CompletableFuture<OperatorID> operatorIdFuture, TypeSerializer<T> serializer, String accumulatorName, CheckpointConfig checkpointConfig)
@VisibleForTesting public CollectResultIterator(AbstractCollectResultBuffer<T> buffer, CompletableFuture<OperatorID> operatorIdFuture, String accumulatorName, int retryMillis)
public void close() throws Exception
close
in interface AutoCloseable
Exception
public void setJobClient(JobClient jobClient)
Copyright © 2014–2024 The Apache Software Foundation. All rights reserved.