Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ClientFactory ¶
type ClientFactory interface { // NewProducer returns a new Producer instance configured with the specified `config` NewProducer(config kafka.ConfigMap) (Producer, error) // NewConsumer returns a new Consumer instance configured with the specified `config` NewConsumer(config kafka.ConfigMap) (Consumer, error) }
ClientFactory provides methods for creating new Producer and Consumer instances
func NewClientFactory ¶
func NewClientFactory() ClientFactory
NewClientFactory returns a new ClientFactory instance
type Consumer ¶
type Consumer interface { Subscribe(topic string, rebalanceCb kafka.RebalanceCb) error ReadMessage(timeout time.Duration) (*kafka.Message, error) Commit() ([]kafka.TopicPartition, error) CommitOffsets(offsets []kafka.TopicPartition) ([]kafka.TopicPartition, error) Close() error }
Consumer allows clients to read messages from Kafka NB: this interface exists for mocking purposes
type ErrorEvent ¶
ErrorEvent is a type alias for confluent-kafka-go's message delivery error notification returned on the `deliveryChan` provided to the Producer's Produce() method
type Event ¶
Event is a type alias for confluent-kafka-go's delivery event type returned on the `deliveryChan` provided to the Producer's Produce() method
type MessageDeliveredEvent ¶
MessageDeliveredEvent is a type alias for confluent-kafka-go's message delivered notification returned on the `deliveryChan` provided to the Producer's Produce() method