Snow-kal opened a new pull request, #3171: URL: https://github.com/apache/dubbo-go/pull/3171
Add generic.include.class config item support, read the env config with default value of true. Remove 'class' key from the Generalize serialization result when the config is false. Remove 'class' key before the Realize deserialization processing when the config is false. Add GenericIncludeClassKey constant in common/constant/key.go for the config item. Limitation: It only reads the environment configuration and is not controlled on a per-call basis via URL/attachment parameters. Therefore, it cannot automatically follow the switch carried by Java in each invocation. To align with the Java URL attachment, it is necessary to pass this parameter along the invocation chain and use it in the generalizer. ---------------------------------------------------------------------------------------------- 常量已在 key.go 添加。 map.go 会读取环境配置 generic.include.class(默认 true),若为 false,则在 Generalize 结果里去掉 class,并在 Realize 前也移除 class。 限制: 只读环境配置,未按 URL/附件逐调用控制,无法自动跟随 Java 每次调用携带的开关。如果需要与 Java URL 附件对齐,还需在调用链上传递该参数并在 generalizer 使用它。 ### Description Related to #3167 ### Checklist - [ √] I confirm the target branch is `develop` - [ √] Code has passed local testing - [ √] I have added tests that prove my fix is effective or that my feature works -- 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]
