nanjiek commented on code in PR #3207:
URL: https://github.com/apache/dubbo-go/pull/3207#discussion_r2803402751
##########
internal/config.go:
##########
@@ -124,7 +131,7 @@ func translateRegistryAddress(registriesConfig
*global.RegistryConfig) string {
u, err := url.Parse(addr)
if err != nil {
logger.Errorf("The registry url is invalid, error:
%#v", err)
- panic(err)
+ return addr
Review Comment:
下游原本就是有阻拦机制的。最新的commit将 translateRegistryAddress 改为返回 (string, error)
并在解析失败时直接向上返回错误,toURLs 也同步处理该错误;对应测试用例更新为校验错误分支和正常分支的返回值。
--
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]