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

refactor(nacos): Modify nacos service caching mechanism

This commit is contained in:
chuntaojun
2019-09-04 15:12:41 +08:00
parent 63e160560c
commit d1b64df9d2
21 changed files with 213 additions and 55 deletions

View File

@@ -22,6 +22,7 @@ import static org.springframework.boot.test.context.SpringBootTest.WebEnvironmen
import java.lang.reflect.Method;
import java.util.Map;
import com.alibaba.cloud.nacos.NacosConfigManager;
import org.junit.Test;
import org.junit.runner.RunWith;
import org.powermock.api.mockito.PowerMockito;
@@ -83,6 +84,9 @@ public class NacosConfigEndpointTests {
@Autowired
private NacosConfigProperties properties;
@Autowired
private NacosConfigManager nacosConfigManager;
@Autowired
private NacosRefreshHistory refreshHistory;
@@ -99,7 +103,7 @@ public class NacosConfigEndpointTests {
Builder builder = new Builder();
NacosConfigHealthIndicator healthIndicator = new NacosConfigHealthIndicator(
properties.configServiceInstance());
nacosConfigManager.getConfigService());
healthIndicator.doHealthCheck(builder);
Builder builder1 = new Builder();