Class BlockOutputWriter

  • All Implemented Interfaces:
    OutputWriter

    public final class BlockOutputWriter
    extends java.lang.Object
    implements OutputWriter
    Represents the output data transfer from a task.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void close()
      Notifies that all writes for a block is end.
      java.util.Optional<java.lang.Long> getWrittenBytes()  
      void write​(java.lang.Object element)
      Writes output element depending on the communication pattern of the edge.
      void writeLatencymark​(LatencyMark latencymark)
      Writes latencymark to all edges.
      void writeWatermark​(Watermark watermark)
      Writes watermarks to all edges.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Method Detail

      • write

        public void write​(java.lang.Object element)
        Description copied from interface: OutputWriter
        Writes output element depending on the communication pattern of the edge.
        Specified by:
        write in interface OutputWriter
        Parameters:
        element - the element to write.
      • writeWatermark

        public void writeWatermark​(Watermark watermark)
        Description copied from interface: OutputWriter
        Writes watermarks to all edges.
        Specified by:
        writeWatermark in interface OutputWriter
        Parameters:
        watermark - watermark
      • writeLatencymark

        public void writeLatencymark​(LatencyMark latencymark)
        Description copied from interface: OutputWriter
        Writes latencymark to all edges. It does not consider buffered time in windows. transfer to the next task immediately.
        Specified by:
        writeLatencymark in interface OutputWriter
        Parameters:
        latencymark - latencymark
      • close

        public void close()
        Notifies that all writes for a block is end. Further write about a committed block will throw an exception.
        Specified by:
        close in interface OutputWriter
      • getWrittenBytes

        public java.util.Optional<java.lang.Long> getWrittenBytes()
        Specified by:
        getWrittenBytes in interface OutputWriter
        Returns:
        the total written bytes.