MCPcopy
hub / github.com/IBM/sarama / SetTopicMetadata

Method SetTopicMetadata

mocks/consumer.go:196–201  ·  view source on GitHub ↗

Expectation API SetTopicMetadata sets the clusters topic/partition metadata, which will be returned by Topics() and Partitions().

(metadata map[string][]int32)

Source from the content-addressed store, hash-verified

194// SetTopicMetadata sets the clusters topic/partition metadata,
195// which will be returned by Topics() and Partitions().
196func (c *Consumer) SetTopicMetadata(metadata map[string][]int32) {
197 c.l.Lock()
198 defer c.l.Unlock()
199
200 c.metadata = metadata
201}
202
203// ExpectConsumePartition will register a topic/partition, so you can set expectations on it.
204// The registered PartitionConsumer will be returned, so you can set expectations

Callers 1

Implementers 2

consumerconsumer.go
Consumermocks/consumer.go

Calls

no outgoing calls

Tested by 1