Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Producer ¶
type Producer struct {
// contains filtered or unexported fields
}
Producer Struct
func NewProducer ¶
func NewProducer(logger *zap.Logger, config *sarama.Config, brokers []string, statsReporter metrics.StatsReporter, healthServer *health.Server) (*Producer, error)
NewProducer returns a new Producer instance with specified configuration.
func (*Producer) ObserveMetrics ¶
ObserveMetrics is an async process for observing Kafka metrics.
func (*Producer) ProduceKafkaMessage ¶
func (p *Producer) ProduceKafkaMessage(ctx context.Context, channelReference eventingChannel.ChannelReference, message binding.Message, httpHeader http.Header, transformers ...binding.Transformer) error
ProduceKafkaMessage creates and sends a Sarama ProducerMessage to the specified Topic and waits for the delivery confirmation.
func (*Producer) SecretChanged ¶ added in v0.21.0
SecretChanged is called by the secretObserver handler function in main() so that settings specific to the producer may be extracted and the producer restarted if necessary.
Click to show internal directories.
Click to hide internal directories.