Documentation ¶
Index ¶
- func BuildDLQTopicForTopic(topic string) string
- func ConsumeFromTopic(ctx context.Context, cancel context.CancelFunc, groupID string, topic string, ...)
- func MarshalKafkaDataToStruct(data []byte, structToMarshal interface{}) error
- func NewReader(cfg kafka.ReaderConfig, log logger.Logger) *kafka.Reader
- func NewWriter(writer kafka.Writer, log logger.Logger) *kafka.Writer
- func PublishToDLQ(ctx context.Context, writer *kafka.Writer, dlqTopic string, ...) error
- func UnmarshalToKafkaMessage(data []byte) (models.KafkaMessage, error)
- func WriteToTopicInBackground(ctx context.Context, writer *kafka.Writer, topic string, key string, ...) error
- type ConsumerReaderConfig
- type ConsumerWriterConfig
- type Reader
- type WriterConfig
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func BuildDLQTopicForTopic ¶ added in v0.6.16
func ConsumeFromTopic ¶ added in v0.5.79
func ConsumeFromTopic( ctx context.Context, cancel context.CancelFunc, groupID string, topic string, workersNum int, workerFunc func(ctx context.Context, cancel context.CancelFunc, r *kafka.Reader, w *kafka.Writer, wg *sync.WaitGroup, workerID int), readerConfig ConsumerReaderConfig, writerConfig ConsumerWriterConfig, logger logger.Logger, )
func MarshalKafkaDataToStruct ¶ added in v0.5.62
func PublishToDLQ ¶ added in v0.6.8
func UnmarshalToKafkaMessage ¶ added in v0.5.62
func UnmarshalToKafkaMessage(data []byte) (models.KafkaMessage, error)
Types ¶
type ConsumerReaderConfig ¶ added in v0.5.79
type ConsumerWriterConfig ¶ added in v0.5.79
type WriterConfig ¶
Click to show internal directories.
Click to hide internal directories.