Class BigtableMutateRowsSink<T>

java.lang.Object
io.github.flink.gcp.connector.bigtable.sink.BigtableMutateRowsSink<T>
Type Parameters:
T - type of the records written by the sink
All Implemented Interfaces:
CrossVersionSink<T>, Serializable, org.apache.flink.api.connector.sink2.Sink<T>

@Internal public class BigtableMutateRowsSink<T> extends Object implements CrossVersionSink<T>
At-least-once sink applying one row mutation per record through the MutateRows bulk batcher of google-cloud-bigtable.
See Also:
  • Constructor Details

  • Method Details

    • getConfig

      public BigtableSinkConfig<T> getConfig()
      Returns the sink configuration.
    • createWriter

      public org.apache.flink.api.connector.sink2.SinkWriter<T> createWriter(org.apache.flink.api.connector.sink2.WriterInitContext context) throws IOException
      Specified by:
      createWriter in interface org.apache.flink.api.connector.sink2.Sink<T>
      Throws:
      IOException
    • createWriter

      @VisibleForTesting public org.apache.flink.api.connector.sink2.SinkWriter<T> createWriter(MutationBatcherFactory factory, TableAdmin tableAdmin, org.apache.flink.api.common.operators.MailboxExecutor mailboxExecutor, org.apache.flink.metrics.groups.SinkWriterMetricGroup metricGroup)
      Creates the writer against an injected batcher factory and table admin. Deliberately does not open the failure handler — that belongs to the production path above, so writer tests injecting fakes need no WriterInitContext.