We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
The currently implementation of org.apache.dubbo.common.URL#getEncodedServiceKey() is not elegant.
org.apache.dubbo.common.URL#getEncodedServiceKey()
public String getEncodedServiceKey() { String serviceKey = this.getServiceKey(); serviceKey = serviceKey.replaceFirst("/", "*"); return serviceKey; }
The purpose of replacing "/" with "*" is that Zookeeper does not support "/" as a valid character of key.
Proposal:
Add new parameter to getServiceKey(), for example: getServiceKey(String delimiter), and pass "/" or "*" in different scenario.
getServiceKey()
getServiceKey(String delimiter)
The text was updated successfully, but these errors were encountered:
目前的实施org.apache.dubbo.common.URL#getEncodedServiceKey() 并不优雅。 public String getEncodedServiceKey(){ String serviceKey = this 。getServiceKey(); serviceKey = serviceKey 。replaceFirst(“ / ”,“ * ”); return serviceKey; } 用“*”替换“/”的目的是Zookeeper不支持“/”作为密钥的有效字符。 提案: 添加新参数getServiceKey(),例如:getServiceKey(String delimiter),并在不同的场景中传递“/”或“*”。
目前的实施org.apache.dubbo.common.URL#getEncodedServiceKey() 并不优雅。
public String getEncodedServiceKey(){ String serviceKey = this 。getServiceKey(); serviceKey = serviceKey 。replaceFirst(“ / ”,“ * ”); return serviceKey; }
用“*”替换“/”的目的是Zookeeper不支持“/”作为密钥的有效字符。
提案:
添加新参数getServiceKey(),例如:getServiceKey(String delimiter),并在不同的场景中传递“/”或“*”。
Do the different scenarios referred to here refer to different registration centers? I didn't understand what you mean.
Sorry, something went wrong.
No branches or pull requests
The currently implementation of
org.apache.dubbo.common.URL#getEncodedServiceKey()
is not elegant.The purpose of replacing "/" with "*" is that Zookeeper does not support "/" as a valid character of key.
Proposal:
Add new parameter to
getServiceKey()
, for example:getServiceKey(String delimiter)
, and pass "/" or "*" in different scenario.The text was updated successfully, but these errors were encountered: