zgs225 commented on issue #10170:
URL: https://github.com/apache/dubbo/issues/10170#issuecomment-1162519390

   当我使用如下配置注册 provider 以使其同时支持 tri 和 dubbo 协议时,如果注册中心是 nacos ,那么只有最后一个生效。如果换成 
zookeeper ,那么两个协议都支持。
   ``` xml
   <!-- 连接到哪个本地注册中心 -->
        <dubbo:registry id="dubbogo"  address="nacos://127.0.0.1:8848" />
        <!-- 用dubbo协议在20880端口暴露服务 -->
        <dubbo:protocol name="tri" host="127.0.0.1" port="20010" />
        <dubbo:protocol name="dubbo" host="127.0.0.1" port="20011" />
        <!-- 声明需要暴露的服务接口 -->
        <dubbo:service id="aaa" registry="dubbogo" timeout="3000" 
interface="org.apache.dubbo.sample.UserProvider" ref="demoService" 
protocol="dubbo,tri"/>
   ```


-- 
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]

Reply via email to