david6969xin commented on a change in pull request #2688:
URL:
https://github.com/apache/servicecomb-java-chassis/pull/2688#discussion_r790389995
##########
File path:
foundations/foundation-config/src/main/java/org/apache/servicecomb/config/YAMLUtil.java
##########
@@ -96,14 +96,18 @@ private YAMLUtil() {
for (Map.Entry<String, Object> entry : propertieMap.entrySet()) {
if (entry.getValue() instanceof Map) {
- result.putAll(retrieveItems(prefix + entry.getKey(), (Map<String,
Object>) entry.getValue()));
+ result.putAll(retrieveItems(prefix + entry.getKey(), (Map<String,
Object>) entry.getValue()));
} else {
- String key = prefix + entry.getKey();
- if (key.startsWith(CONFIG_CSE_PREFIX)) {
- String servicecombKey = CONFIG_SERVICECOMB_PREFIX +
key.substring(key.indexOf(".") + 1);
- result.put(servicecombKey, entry.getValue());
+ if (entry.getKey() instanceof String){
+ String key = prefix + entry.getKey();
+ if (key.startsWith(CONFIG_CSE_PREFIX)) {
+ String servicecombKey = CONFIG_SERVICECOMB_PREFIX +
key.substring(key.indexOf(".") + 1);
+ result.put(servicecombKey, entry.getValue());
+ }
+ result.put(key, entry.getValue());
+ }else {
+ throw new IllegalArgumentException("value config error");
Review comment:
done
--
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]