1
0
mirror of https://gitee.com/mirrors/Spring-Cloud-Alibaba.git synced 2021-06-26 13:25:11 +08:00

[issue #982 & issue #978]enhance nacos config - code review

This commit is contained in:
zkzlx
2020-01-07 12:52:08 +08:00
parent 85ddda03ff
commit c348421970
6 changed files with 19 additions and 12 deletions

View File

@@ -19,6 +19,8 @@ package com.alibaba.cloud.nacos.client;
import java.util.Date;
import java.util.Map;
import com.alibaba.cloud.nacos.NacosConfigProperties;
import org.springframework.core.env.MapPropertySource;
/**
@@ -49,7 +51,7 @@ public class NacosPropertySource extends MapPropertySource {
NacosPropertySource(String group, String dataId, Map<String, Object> source,
Date timestamp, boolean isRefreshable) {
super(String.format("%s#%s", dataId, group), source);
super(String.join(NacosConfigProperties.COMMAS, dataId, group), source);
this.group = group;
this.dataId = dataId;
this.timestamp = timestamp;