You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@dubbo.apache.org by GitBox <gi...@apache.org> on 2020/06/02 11:06:27 UTC
[GitHub] [dubbo-go] AlexStocks commented on a change in pull request #578: Rft : Optimize lock for zookeeper registry
AlexStocks commented on a change in pull request #578:
URL: https://github.com/apache/dubbo-go/pull/578#discussion_r433794835
##########
File path: remoting/zookeeper/client.go
##########
@@ -487,7 +493,9 @@ func (z *ZookeeperClient) RegisterTempSeq(basePath string, data []byte) (string,
)
err = errNilZkClientConn
+ z.RLock()
Review comment:
big old, maybe u can define a func as follows
```Go
func (z *zookeeperClient) getConn() net.Conn {
z.RLock()
defer z.RUnlock()
return z.Conn
}
----------------------------------------------------------------
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
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org