diff --git a/infra/common/src/main/java/org/apache/shardingsphere/infra/props/PropertiesConverter.java b/infra/common/src/main/java/org/apache/shardingsphere/infra/props/PropertiesConverter.java index 6bb7904b04e3f..fcc4b282434f2 100644 --- a/infra/common/src/main/java/org/apache/shardingsphere/infra/props/PropertiesConverter.java +++ b/infra/common/src/main/java/org/apache/shardingsphere/infra/props/PropertiesConverter.java @@ -38,7 +38,7 @@ public final class PropertiesConverter { * @return converted string content */ public static String convert(final Properties props) { - return null == props || props.isEmpty() ? "" - : JsonUtils.toJsonString(props.keySet().stream().map(Object::toString).sorted().collect(Collectors.toMap(each -> each, props::get, (key1, key2) -> key1, LinkedHashMap::new))); + return null == props || props.isEmpty() ? "" : JsonUtils.toJsonString(props.keySet().stream().map(Object::toString).sorted() + .collect(Collectors.toMap(each -> each, props::get, (oldValue, currentValue) -> oldValue, LinkedHashMap::new))); } }