XiaoFeiASK commented on PR #3501:
URL: https://github.com/apache/dubbo-go/pull/3501#issuecomment-5048861865
新增修改
- filter/generic/util.go
问题: generic=protobuf 被直接映射为 ProtobufJsonGeneralizer,导致 legacy Triple $invoke
中的 Hessian/String 参数被误按 protobuf JSON 处理,下游方法未被调用。
修复: 拆分 protobuf 与 protobuf-json 映射,protobuf-json 使用
ProtobufJsonGeneralizer,protobuf 恢复为 MapGeneralizer。
影响: 保留历史 Triple generic invoker 的 Map/Hessian 语义,避免兼容性回归。
- filter/generic/util_test.go
问题: 测试错误验证 protobuf 与 protobuf-json 使用同一个 generalizer。
修复: 将 generic=protobuf 的期望结果改为 MapGeneralizer。
影响: 测试与 legacy protobuf 兼容行为保持一致。
- filter/generic/filter_test.go
问题: protobuf-legacy 测试使用 protobuf message,未覆盖 legacy Map/Hessian 语义。
修复: 改为普通 POJO 参数,并断言泛化结果为 map[string]any。
影响: 覆盖 consumer 侧 generic=protobuf 继续走 Map/Hessian 泛化逻辑。
- filter/generic/service_filter_test.go
问题: 缺少 $invoke + generic=protobuf + Hessian string 参数的兼容回归测试。
修复: 新增 legacy generic $invoke 测试,参数为 []hessian.Object{"world"},目标方法为
Hello(string),断言返回 hello, world。
影响: 防止 legacy generic $invoke 的 Map/Hessian 兼容行为再次回归。
--
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]