Documentation ¶
Index ¶
Constants ¶
View Source
const SecurityProtocolTls = "TLS"
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Admin ¶
type Admin interface { // CreateTopics create multiple topics at once with custom configurations. // Returns error if any error occurred CreateTopics(configurations []TopicConfiguration) error // DeleteTopics delete multiple topics at once. // Returns error if any error occurred DeleteTopics(topics []string) error // DeleteGroups delete multiple groups at once. // Returns error if any error occurred DeleteGroups(groupIds []string) error }
type AsyncProducer ¶
type AsyncProducer interface { // Send a message to the brokers Send(m *Message) // Successes is the success output channel back to the user Successes() <-chan *Message // Errors is the error output channel back to the user Errors() <-chan *ProducerError // Close the producer Close() error }
AsyncProducer publishes messages to the brokers
type ConsumerHandler ¶
type ConsumerHandler interface { HandlerFunc(*ConsumerMessage) Close() }
type ConsumerMessage ¶
type ConsumerMessage struct { Topic string Key []byte Value []byte Headers []MessageHeader Partition int32 Offset int64 Timestamp time.Time }
func (ConsumerMessage) String ¶
func (m ConsumerMessage) String() string
type Message ¶
type MessageHeader ¶
func (MessageHeader) String ¶
func (m MessageHeader) String() string
type ProducerError ¶
ProducerError is the type of error generated when the producer fails to deliver a message. It contains the original Message as well as the actual error value.
func (ProducerError) Error ¶
func (pe ProducerError) Error() string
func (ProducerError) Unwrap ¶
func (pe ProducerError) Unwrap() error
Click to show internal directories.
Click to hide internal directories.