(msg *ProducerMessage)
| 70 | } |
| 71 | |
| 72 | func (b *appendInterceptor) OnSend(msg *ProducerMessage) { |
| 73 | if b.i < 0 { |
| 74 | panic("hey, the interceptor has failed") |
| 75 | } |
| 76 | v, _ := msg.Value.Encode() |
| 77 | msg.Value = StringEncoder(string(v) + strconv.Itoa(b.i)) |
| 78 | b.i++ |
| 79 | } |
| 80 | |
| 81 | func (b *appendInterceptor) OnConsume(msg *ConsumerMessage) { |
| 82 | if b.i < 0 { |
nothing calls this directly
no test coverage detected