Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewSecureDialer ¶
Types ¶
type HandlerFunc ¶
type HandlerFunc func(e *Message)
type Message ¶
type Message struct {
// contains filtered or unexported fields
}
func NewMessage ¶
func NewMessage(km kafka.Message) *Message
type Option ¶
type Option func(p *Provider)
func WithBatchSize ¶
func WithBatchTimeout ¶
func WithDialer ¶
func WithDialer(dialer *kafka.Dialer) Option
WithDialer configures the pubsub.Service to use the provided dialer
func WithLog ¶
func WithLog(log logrus.FieldLogger) Option
type Provider ¶
type Provider struct {
// contains filtered or unexported fields
}
Provider implements pubsub.Provider
func NewProvider ¶
func NewProvider(brokers []string, serviceName string, awsRegion string, opts ...Option) (*Provider, error)
NewProvider creates a new kafka.Provider
type Subscription ¶
type Subscription struct {
// contains filtered or unexported fields
}
func NewSubscription ¶
func NewSubscription(topic string, reader *kafka.Reader, log logrus.FieldLogger) *Subscription
NewSubscription creates a new Subscription for the specified topic
func (*Subscription) Add ¶
func (s *Subscription) Add(handler HandlerFunc)
Add a handler for this topic
func (*Subscription) Stop ¶
func (s *Subscription) Stop()
Stop this subscriber from listening for more messages
Click to show internal directories.
Click to hide internal directories.