Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type BatchHandler ¶
type BatchHandler[T any] struct { // contains filtered or unexported fields }
func NewBatchHandler ¶
func NewBatchHandler[T any]( l logger.Logger, bizFn func(msgs []*sarama.ConsumerMessage, events []T) error, ) *BatchHandler[T]
func (*BatchHandler[T]) Cleanup ¶
func (h *BatchHandler[T]) Cleanup(sarama.ConsumerGroupSession) error
Cleanup implements sarama.ConsumerGroupHandler.
func (*BatchHandler[T]) ConsumeClaim ¶
func (h *BatchHandler[T]) ConsumeClaim( session sarama.ConsumerGroupSession, claim sarama.ConsumerGroupClaim, ) error
ConsumeClaim implements sarama.ConsumerGroupHandler.
func (*BatchHandler[T]) Setup ¶
func (h *BatchHandler[T]) Setup(sarama.ConsumerGroupSession) error
Setup implements sarama.ConsumerGroupHandler.
type Handler ¶
type Handler[T any] struct { // contains filtered or unexported fields }
func NewHandler ¶
func NewHandler[T any]( l logger.Logger, opts prometheus.SummaryOpts, bizFn func(msg *sarama.ConsumerMessage, event T) error, ) *Handler[T]
func (*Handler[T]) Cleanup ¶
func (h *Handler[T]) Cleanup(sarama.ConsumerGroupSession) error
Cleanup implements sarama.ConsumerGroupHandler.
func (*Handler[T]) ConsumeClaim ¶
func (h *Handler[T]) ConsumeClaim( session sarama.ConsumerGroupSession, claim sarama.ConsumerGroupClaim, ) error
ConsumeClaim implements sarama.ConsumerGroupHandler.
Click to show internal directories.
Click to hide internal directories.