(topic string, partition int32, msg *Message)
| 294 | } |
| 295 | |
| 296 | func (r *ProduceRequest) AddMessage(topic string, partition int32, msg *Message) { |
| 297 | r.ensureRecords(topic, partition) |
| 298 | set := r.records[topic][partition].MsgSet |
| 299 | |
| 300 | if set == nil { |
| 301 | set = new(MessageSet) |
| 302 | r.records[topic][partition] = newLegacyRecords(set) |
| 303 | } |
| 304 | |
| 305 | set.addMessage(msg) |
| 306 | } |
| 307 | |
| 308 | func (r *ProduceRequest) AddSet(topic string, partition int32, set *MessageSet) { |
| 309 | r.ensureRecords(topic, partition) |