yyweii commented on PR #1922: URL: https://github.com/apache/incubator-brpc/pull/1922#issuecomment-1256961800
> Hi guys, > > FYI. 我这里基于[nacos-cli ](https://github.com/nacos-group/nacos-sdk-cpp)实现了另外一个版本的 nacos naming service: [thorneliu@2cf39b6](https://github.com/thorneliu/incubator-brpc/commit/2cf39b6d0b91318575901eba9adf00b545600f84) > > 基于这个patch, client可以: > > ``` > std::string nacosurl("nacos://serverAddress/namespace/groupName/serviceName/clusterId"); > channel.Init(nacosurl.c_str(), FLAGS_load_balancer.c_str(), &options) > ``` > > 这个naming service是通过nacos cpp sdk订阅nacos服务的服务实例变化来更新servernodes的; 不好的地方在于这个实现引入了第三方库的依赖 > > @yyweii @serverglen 我本来也是用的sdk,但是只用来注册服务、获取和监听配置。后来我发现sdk代码bug太多了,最终还是基于http接口重新写了一个库。brpc里面的naming service一直是直接调用http接口的。 以后的sdk代码很有可能会改成grpc协议。nacos官网还没有grpc协议的文档。据介绍使用了grpc的双向流,目前brpc没有支持。 -- 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. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
