cckellogg commented on a change in pull request #162: Avoid double cnx close
notification on graceful server side close
URL: https://github.com/apache/pulsar-client-go/pull/162#discussion_r363045025
##########
File path: pulsar/internal/connection.go
##########
@@ -550,16 +550,19 @@ func (c *connection) handleCloseConsumer(closeConsumer
*pb.CommandCloseConsumer)
consumerID := closeConsumer.GetConsumerId()
if consumer, ok := c.consumerHandler(consumerID); ok {
consumer.ConnectionClosed()
+ delete(c.listeners, consumerID)
Review comment:
Should we use this function DeleteConsumeHandler to delete the handler? We
get the handler using the consumerHandlersLock so to be consistent should we
delete with it too? Also does it matter if we delete before or after calling
the ConnectionClosed()?
----------------------------------------------------------------
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:
[email protected]
With regards,
Apache Git Services