Dubbo3调用配置了提供者path属性的服务提供者出现找不到提供者的报错

5fjcxozz  于 2022-12-31  发布在  其他
关注(0)|答案(3)|浏览(203)
  • I have searched the issues of this repository and believe that this is not a duplicate.

Environment

  • Dubbo version: 3.1.0 -> 2.7.5.x
  • Operating System version: linux,windows
  • Java version: 1.8

Steps to reproduce this issue

  1. 配置了path属性的服务提供者启动 dubbo老版本
  2. 消费者启动订阅服务失败 dubbo3.1.0这个版本

Pls. provide [GitHub address] to reproduce this issue.

Expected Behavior

感觉是dubbo3的服务消费者没有兼容path这个配置与dubbo低版本表现得行为不一样,导致序列化检查时候失败了

Actual Behavior

If there is an exception, please attach the exception trace:

i2loujxw

i2loujxw1#

path 这个属性是给 rest 协议使用的,对于 dubbo 协议如果以前是兼容的话得看下差异点在哪

tyg4sfes

tyg4sfes2#

path 这个属性是给 rest 协议使用的,对于 dubbo 协议如果以前是兼容的话得看下差异点在哪

#6138 这个问题修复了之后 dubbo协议 提供者拿到的低版本消费者和高版本消费者的第二个字段path是不一样的 ,高版本只会取interface 低版本如果存在path则会取path 稍等先等我确认下安全校验的代码的版本

ss2ws0br

ss2ws0br3#

path 这个属性是给 rest 协议使用的,对于 dubbo 协议如果以前是兼容的话得看下差异点在哪

dubbo2缓存的key是path和版本号组成的
dubbo3缓存的key是接口和版本号组成的

如果dubbo3配置了path dubbo2调用dubbo3的时候 dubbo3内部就会找不到这个提供者导致调用失败 估计兼容比较麻烦 可以看下CodeSupport这个类型的checkSerialzation方法

相关问题