MCPcopy
hub / github.com/segmentio/kafka-go / Validate

Method Validate

writer.go:336–341  ·  view source on GitHub ↗

Validate method validates WriterConfig properties.

()

Source from the content-addressed store, hash-verified

334
335// Validate method validates WriterConfig properties.
336func (config *WriterConfig) Validate() error {
337 if len(config.Brokers) == 0 {
338 return errors.New("cannot create a kafka writer with an empty list of brokers")
339 }
340 return nil
341}
342
343// WriterStats is a data structure returned by a call to Writer.Stats that
344// exposes details about the behavior of the writer.

Callers 1

NewWriterFunction · 0.45

Calls

no outgoing calls

Tested by

no test coverage detected