You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pulsar.apache.org by GitBox <gi...@apache.org> on 2020/12/01 18:22:42 UTC

[GitHub] [pulsar] flowchartsman commented on issue #8769: [Go functions]: Panic on discard message

flowchartsman commented on issue #8769:
URL: https://github.com/apache/pulsar/issues/8769#issuecomment-736733486


   The issue appears to be a mismatch between `inputMessage.Topic()` and the consumers in `gi.consumers`:
   
   If `ackInputMessage` is instrumented like so
   ```go
   // ackInputMessage doesn't produce any result, or the user doesn't want the result.
   func (gi *goInstance) ackInputMessage(inputMessage pulsar.Message) {
   	log.Infof("**********\ntopic is: %s\nconsumers:\n%#v", inputMessage.Topic(), gi.consumers)
   	gi.consumers[inputMessage.Topic()].Ack(inputMessage)
   }
   ```
   In the logs we see:
   
   ```
   2020/12/01 18:17:31.048 log.go:46: [info] **********
   topic is: persistent://public/default/test
   consumers:
   map[string]pulsar.Consumer{"public/default/test":(*pulsar.consumer)(0xc00040cd80)}
   
   ```
   I am unsure whether the failure here is with pulsar-admin or with my use of an abbreviated topic, but in any case a panic is not helpful.


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org