Class FiniteTestSource<T>

  • All Implemented Interfaces:
    Serializable, org.apache.flink.api.common.functions.Function, org.apache.flink.api.common.state.CheckpointListener, org.apache.flink.streaming.api.functions.source.SourceFunction<T>

    @Deprecated
    public class FiniteTestSource<T>
    extends Object
    implements org.apache.flink.streaming.api.functions.source.SourceFunction<T>, org.apache.flink.api.common.state.CheckpointListener
    Deprecated.
    This class is based on the SourceFunction API, which is due to be removed. Use the new Source API instead.
    A stream source that: 1) emits a list of elements without allowing checkpoints, 2) then waits for two more checkpoints to complete, 3) then re-emits the same elements before 4) waiting for another two checkpoints and 5) exiting.

    This class was written to test the Bulk Writers used by the StreamingFileSink.

    See Also:
    Serialized Form
    • Method Detail

      • run

        public void run​(org.apache.flink.streaming.api.functions.source.SourceFunction.SourceContext<T> ctx)
                 throws Exception
        Deprecated.
        Specified by:
        run in interface org.apache.flink.streaming.api.functions.source.SourceFunction<T>
        Throws:
        Exception
      • cancel

        public void cancel()
        Deprecated.
        Specified by:
        cancel in interface org.apache.flink.streaming.api.functions.source.SourceFunction<T>
      • notifyCheckpointComplete

        public void notifyCheckpointComplete​(long checkpointId)
                                      throws Exception
        Deprecated.
        Specified by:
        notifyCheckpointComplete in interface org.apache.flink.api.common.state.CheckpointListener
        Throws:
        Exception
      • notifyCheckpointAborted

        public void notifyCheckpointAborted​(long checkpointId)
        Deprecated.
        Specified by:
        notifyCheckpointAborted in interface org.apache.flink.api.common.state.CheckpointListener