Class RemoteStreamImpl<M extends BufferReader,P extends BufferWriter>

java.lang.Object
io.camunda.zeebe.transport.stream.impl.RemoteStreamImpl<M,P>
All Implemented Interfaces:
RemoteStream<M,P>

public class RemoteStreamImpl<M extends BufferReader,P extends BufferWriter> extends Object implements RemoteStream<M,P>
  • Constructor Details

    • RemoteStreamImpl

      public RemoteStreamImpl(M metadata, io.camunda.zeebe.transport.stream.impl.RemoteStreamPusher<P> streamer)
  • Method Details

    • metadata

      public M metadata()
      Description copied from interface: RemoteStream
      Returns the stream's metadata
      Specified by:
      metadata in interface RemoteStream<M extends BufferReader,P extends BufferWriter>
    • push

      public void push(P payload, RemoteStream.ErrorHandler<P> errorHandler)
      Description copied from interface: RemoteStream
      Pushes the given payload to the stream. Implementations of this are likely asynchronous; it's recommended that callers ensure that the given payload is immutable, and that the error handler does not close over any shared state.
      Specified by:
      push in interface RemoteStream<M extends BufferReader,P extends BufferWriter>
      Parameters:
      payload - the data to push to the remote gateway
      errorHandler - logic to execute if the data could not be pushed to the underlying stream