Interface BarrageMessageWriter.Factory

All Known Implementing Classes:
BarrageMessageWriterImpl.ArrowFactory, BarrageMessageWriterImpl.Factory
Enclosing interface:
BarrageMessageWriter

public static interface BarrageMessageWriter.Factory
  • Method Details

    • newMessageWriter

      BarrageMessageWriter newMessageWriter(@NotNull @NotNull BarrageMessage message, @NotNull @NotNull ChunkWriter<Chunk<Values>>[] chunkWriters, @NotNull BarrageMessageWriter.WriteMetricsConsumer metricsConsumer)
      Create a BarrageMessageWriter that now owns the BarrageMessage.
      Parameters:
      message - the message that contains the update that we would like to propagate
      metricsConsumer - a method that can be used to record write metrics
    • getSchemaView

      default BarrageMessageWriter.MessageView getSchemaView(@NotNull @NotNull ToIntFunction<com.google.flatbuffers.FlatBufferBuilder> schemaPayloadWriter)
      Create a BarrageMessageWriter.MessageView of the Schema to send as the initial message to a new subscriber.
      Parameters:
      schemaPayloadWriter - a function that writes schema data to a FlatBufferBuilder and returns the schema offset
      Returns:
      a MessageView that can be sent to a subscriber
    • getSchemaView

      BarrageMessageWriter.MessageView getSchemaView(@NotNull @NotNull ToIntFunction<com.google.flatbuffers.FlatBufferBuilder> schemaPayloadWriter, @Nullable org.apache.arrow.flight.impl.Flight.FlightDescriptor flightDescriptor)
      Create a BarrageMessageWriter.MessageView of the Schema to send as the initial message, with a flight descriptor for the table.
      Parameters:
      schemaPayloadWriter - a function that writes schema data to a FlatBufferBuilder and returns the schema offset
      flightDescriptor - the flight descriptor for the table, null if it need not be set
      Returns:
      a MessageView that can be sent to a subscriber