jonyhy96 commented on a change in pull request #535:
URL: https://github.com/apache/pulsar-client-go/pull/535#discussion_r655970263
##########
File path: pulsar/consumer_partition.go
##########
@@ -1113,6 +1114,17 @@ func (pc *partitionConsumer)
discardCorruptedMessage(msgID *pb.MessageIdData,
})
}
+func (pc *partitionConsumer) _setConn(conn internal.Connection) {
+ pc.conn.Store(conn)
+}
+
+func (pc *partitionConsumer) _getConn() internal.Connection {
Review comment:
> I wanted to make it clear that these methods should not be used by
other components in the pulsar package
Agree with this, but this is not a guarantee. Maybe we can add some comment
on this function.
##########
File path: pulsar/consumer_partition.go
##########
@@ -1113,6 +1114,17 @@ func (pc *partitionConsumer)
discardCorruptedMessage(msgID *pb.MessageIdData,
})
}
+func (pc *partitionConsumer) _setConn(conn internal.Connection) {
+ pc.conn.Store(conn)
+}
+
+func (pc *partitionConsumer) _getConn() internal.Connection {
Review comment:
> I wanted to make it clear that these methods should not be used by
other components in the pulsar package
Agree with this, but this is not a guarantee. Maybe we can add some comment
on this function.
--
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]