protected AbstractKafkaClient(KafkaSinkOptions options) { Contract.Requires <ArgumentNullException>(options != null); this.options = options; this.producerConfiguration = new ProducerConfiguration(options.Topic); }
/// <summary> /// Initializes a new instance of the <see cref="KafkaSink"/> class. /// </summary> /// <param name="kafkaClient"> /// The kafka Client. /// </param> /// <param name="options"> /// The configuration options. /// </param> public KafkaSink(AbstractKafkaClient kafkaClient, KafkaSinkOptions options) : base(options.BatchPostingLimit, options.Period) { Contract.Requires <ArgumentNullException>(options != null); Contract.Requires <ArgumentNullException>(kafkaClient != null); this.kafkaClient = kafkaClient; this.jsonFormatter = new JsonFormatter(renderMessage: options.RenderSerilogMessage); }
internal KafkaClient(KafkaSinkOptions options) : base(options) { Contract.Requires <ArgumentNullException>(options != null); }