Documentation ¶
Index ¶
- func CloseKafkaConsumer(consumer sarama.Consumer) error
- func ConsumeFromPartition(consumer sarama.Consumer, topic string, partition int32, initialOffset int64) (sarama.PartitionConsumer, error)
- func CreateNewConsumer(brokerlist []string) (sarama.Consumer, error)
- func GetPartitions(c sarama.Consumer, topic string, partitions string) ([]int32, error)
- func ReceiveMessages(consumerInstance sarama.Consumer, topic string, initialOffset int64, ...)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CloseKafkaConsumer ¶
Closes the Kafka Consumer.
func ConsumeFromPartition ¶
func ConsumeFromPartition(consumer sarama.Consumer, topic string, partition int32, initialOffset int64) (sarama.PartitionConsumer, error)
Attaches an initialized Kafka Consumer with a Kafka topic, in conjunction with a given topic partition. The topic will be read from the point specified by the initial offset.
func CreateNewConsumer ¶
Creates new Kafka generic consumer attached to a set of brokers.
func GetPartitions ¶
Retrieves the list of partitions available for a given Kafka topic. - c sarama.Consumer: the initialized Kafka consumer - topic string: the kafka topic to use - paritions string : the comma separated list of partitions ids to use. 'all' to use all the available.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.