Documentation ¶
Index ¶
- type APP
- type Consumer
- func (consumer *Consumer) Cleanup(sess sarama.ConsumerGroupSession) error
- func (consumer *Consumer) ConsumeClaim(session sarama.ConsumerGroupSession, claim sarama.ConsumerGroupClaim) error
- func (consumer *Consumer) ProcessMessage(topic, msg string)
- func (consumer *Consumer) SetBuffer(buf chan []string)
- func (consumer *Consumer) Setup(sess sarama.ConsumerGroupSession) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Consumer ¶
type Consumer struct { Ready chan bool // contains filtered or unexported fields }
Consumer represents a Sarama consumer group consumer
func NewConsumer ¶
func (*Consumer) Cleanup ¶
func (consumer *Consumer) Cleanup(sess sarama.ConsumerGroupSession) error
Cleanup is run at the end of a session, once all ConsumeClaim goroutines have exited
func (*Consumer) ConsumeClaim ¶
func (consumer *Consumer) ConsumeClaim(session sarama.ConsumerGroupSession, claim sarama.ConsumerGroupClaim) error
ConsumeClaim must start a consumer loop of ConsumerGroupClaim's Messages().
func (*Consumer) ProcessMessage ¶
message protocol: [topic type][retry count][reqID][req]
Click to show internal directories.
Click to hide internal directories.