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

polish #761 update pkg name & maven coordinate for Greenwich

This commit is contained in:
fangjian0423
2019-07-23 11:03:04 +08:00
parent 3998ea23f7
commit 883c66f251
599 changed files with 4993 additions and 4526 deletions

View File

@@ -14,17 +14,18 @@
* limitations under the License.
*/
package org.springframework.cloud.alibaba.nacos;
package com.alibaba.cloud.nacos;
import org.springframework.beans.factory.BeanFactoryUtils;
import org.springframework.boot.autoconfigure.condition.ConditionalOnProperty;
import org.springframework.cloud.alibaba.nacos.refresh.NacosContextRefresher;
import org.springframework.cloud.alibaba.nacos.refresh.NacosRefreshHistory;
import org.springframework.cloud.alibaba.nacos.refresh.NacosRefreshProperties;
import org.springframework.context.ApplicationContext;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import com.alibaba.cloud.nacos.refresh.NacosContextRefresher;
import com.alibaba.cloud.nacos.refresh.NacosRefreshHistory;
import com.alibaba.cloud.nacos.refresh.NacosRefreshProperties;
/**
* @author juven.xuxb
*/

View File

@@ -14,14 +14,15 @@
* limitations under the License.
*/
package org.springframework.cloud.alibaba.nacos;
package com.alibaba.cloud.nacos;
import org.springframework.boot.autoconfigure.condition.ConditionalOnMissingBean;
import org.springframework.boot.autoconfigure.condition.ConditionalOnProperty;
import org.springframework.cloud.alibaba.nacos.client.NacosPropertySourceLocator;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import com.alibaba.cloud.nacos.client.NacosPropertySourceLocator;
/**
* @author xiaojing
*/

View File

@@ -14,18 +14,7 @@
* limitations under the License.
*/
package org.springframework.cloud.alibaba.nacos;
import com.alibaba.nacos.api.NacosFactory;
import com.alibaba.nacos.api.config.ConfigService;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.boot.context.properties.ConfigurationProperties;
import java.util.List;
import java.util.Objects;
import java.util.Properties;
package com.alibaba.cloud.nacos;
import static com.alibaba.nacos.api.PropertyKeyConst.ACCESS_KEY;
import static com.alibaba.nacos.api.PropertyKeyConst.CLUSTER_NAME;
@@ -37,6 +26,17 @@ import static com.alibaba.nacos.api.PropertyKeyConst.NAMESPACE;
import static com.alibaba.nacos.api.PropertyKeyConst.SECRET_KEY;
import static com.alibaba.nacos.api.PropertyKeyConst.SERVER_ADDR;
import java.util.List;
import java.util.Objects;
import java.util.Properties;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.boot.context.properties.ConfigurationProperties;
import com.alibaba.nacos.api.NacosFactory;
import com.alibaba.nacos.api.config.ConfigService;
/**
* nacos properties
*

View File

@@ -14,14 +14,14 @@
* limitations under the License.
*/
package org.springframework.cloud.alibaba.nacos;
import org.springframework.cloud.alibaba.nacos.client.NacosPropertySource;
package com.alibaba.cloud.nacos;
import java.util.ArrayList;
import java.util.List;
import java.util.concurrent.ConcurrentHashMap;
import com.alibaba.cloud.nacos.client.NacosPropertySource;
/**
* @author xiaojing
* @author pbting

View File

@@ -14,13 +14,13 @@
* limitations under the License.
*/
package org.springframework.cloud.alibaba.nacos.client;
import org.springframework.core.env.MapPropertySource;
package com.alibaba.cloud.nacos.client;
import java.util.Date;
import java.util.Map;
import org.springframework.core.env.MapPropertySource;
/**
* @author xiaojing
* @author pbting

View File

@@ -14,17 +14,7 @@
* limitations under the License.
*/
package org.springframework.cloud.alibaba.nacos.client;
import com.alibaba.nacos.api.config.ConfigService;
import com.alibaba.nacos.api.exception.NacosException;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.config.YamlPropertiesFactoryBean;
import org.springframework.cloud.alibaba.nacos.NacosPropertySourceRepository;
import org.springframework.core.io.ByteArrayResource;
import org.springframework.util.StringUtils;
package com.alibaba.cloud.nacos.client;
import java.io.StringReader;
import java.util.Date;
@@ -33,6 +23,16 @@ import java.util.HashMap;
import java.util.Map;
import java.util.Properties;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.config.YamlPropertiesFactoryBean;
import org.springframework.core.io.ByteArrayResource;
import org.springframework.util.StringUtils;
import com.alibaba.cloud.nacos.NacosPropertySourceRepository;
import com.alibaba.nacos.api.config.ConfigService;
import com.alibaba.nacos.api.exception.NacosException;
/**
* @author xiaojing
* @author pbting

View File

@@ -14,15 +14,13 @@
* limitations under the License.
*/
package org.springframework.cloud.alibaba.nacos.client;
package com.alibaba.cloud.nacos.client;
import com.alibaba.nacos.api.config.ConfigService;
import java.util.Arrays;
import java.util.List;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.cloud.alibaba.nacos.NacosConfigProperties;
import org.springframework.cloud.alibaba.nacos.NacosPropertySourceRepository;
import org.springframework.cloud.alibaba.nacos.refresh.NacosContextRefresher;
import org.springframework.cloud.bootstrap.config.PropertySourceLocator;
import org.springframework.core.annotation.Order;
import org.springframework.core.env.CompositePropertySource;
@@ -30,8 +28,10 @@ import org.springframework.core.env.Environment;
import org.springframework.core.env.PropertySource;
import org.springframework.util.StringUtils;
import java.util.Arrays;
import java.util.List;
import com.alibaba.cloud.nacos.NacosConfigProperties;
import com.alibaba.cloud.nacos.NacosPropertySourceRepository;
import com.alibaba.cloud.nacos.refresh.NacosContextRefresher;
import com.alibaba.nacos.api.config.ConfigService;
/**
* @author xiaojing

View File

@@ -14,7 +14,7 @@
* limitations under the License.
*/
package org.springframework.cloud.alibaba.nacos.diagnostics.analyzer;
package com.alibaba.cloud.nacos.diagnostics.analyzer;
import org.springframework.boot.diagnostics.AbstractFailureAnalyzer;
import org.springframework.boot.diagnostics.FailureAnalysis;

View File

@@ -14,11 +14,11 @@
* limitations under the License.
*/
package org.springframework.cloud.alibaba.nacos.diagnostics.analyzer;
package com.alibaba.cloud.nacos.diagnostics.analyzer;
/**
* A {@code NacosConnectionFailureException} is thrown when the application fails to connect
* to Nacos Server.
* A {@code NacosConnectionFailureException} is thrown when the application fails to
* connect to Nacos Server.
*
* @author juven.xuxb
*/
@@ -35,7 +35,7 @@ public class NacosConnectionFailureException extends RuntimeException {
}
public NacosConnectionFailureException(String domain, String port, String message,
Throwable cause) {
Throwable cause) {
super(message, cause);
this.domain = domain;
this.port = port;

View File

@@ -14,14 +14,7 @@
* limitations under the License.
*/
package org.springframework.cloud.alibaba.nacos.endpoint;
import org.springframework.boot.actuate.endpoint.annotation.Endpoint;
import org.springframework.boot.actuate.endpoint.annotation.ReadOperation;
import org.springframework.cloud.alibaba.nacos.NacosConfigProperties;
import org.springframework.cloud.alibaba.nacos.NacosPropertySourceRepository;
import org.springframework.cloud.alibaba.nacos.client.NacosPropertySource;
import org.springframework.cloud.alibaba.nacos.refresh.NacosRefreshHistory;
package com.alibaba.cloud.nacos.endpoint;
import java.text.DateFormat;
import java.text.SimpleDateFormat;
@@ -30,6 +23,14 @@ import java.util.HashMap;
import java.util.List;
import java.util.Map;
import org.springframework.boot.actuate.endpoint.annotation.Endpoint;
import org.springframework.boot.actuate.endpoint.annotation.ReadOperation;
import com.alibaba.cloud.nacos.NacosConfigProperties;
import com.alibaba.cloud.nacos.NacosPropertySourceRepository;
import com.alibaba.cloud.nacos.client.NacosPropertySource;
import com.alibaba.cloud.nacos.refresh.NacosRefreshHistory;
/**
* Endpoint for Nacos, contains config data and refresh history
* @author xiaojing

View File

@@ -14,7 +14,7 @@
* limitations under the License.
*/
package org.springframework.cloud.alibaba.nacos.endpoint;
package com.alibaba.cloud.nacos.endpoint;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.boot.actuate.autoconfigure.endpoint.condition.ConditionalOnEnabledEndpoint;
@@ -23,10 +23,11 @@ import org.springframework.boot.autoconfigure.condition.ConditionalOnClass;
import org.springframework.boot.autoconfigure.condition.ConditionalOnMissingBean;
import org.springframework.boot.autoconfigure.condition.ConditionalOnProperty;
import org.springframework.boot.autoconfigure.condition.ConditionalOnWebApplication;
import org.springframework.cloud.alibaba.nacos.NacosConfigProperties;
import org.springframework.cloud.alibaba.nacos.refresh.NacosRefreshHistory;
import org.springframework.context.annotation.Bean;
import com.alibaba.cloud.nacos.NacosConfigProperties;
import com.alibaba.cloud.nacos.refresh.NacosRefreshHistory;
/**
* @author xiaojing
*/

View File

@@ -14,19 +14,20 @@
* limitations under the License.
*/
package org.springframework.cloud.alibaba.nacos.endpoint;
import com.alibaba.nacos.api.config.ConfigService;
import org.springframework.boot.actuate.health.AbstractHealthIndicator;
import org.springframework.boot.actuate.health.Health;
import org.springframework.cloud.alibaba.nacos.NacosConfigProperties;
import org.springframework.cloud.alibaba.nacos.NacosPropertySourceRepository;
import org.springframework.cloud.alibaba.nacos.client.NacosPropertySource;
import org.springframework.util.StringUtils;
package com.alibaba.cloud.nacos.endpoint;
import java.util.ArrayList;
import java.util.List;
import org.springframework.boot.actuate.health.AbstractHealthIndicator;
import org.springframework.boot.actuate.health.Health;
import org.springframework.util.StringUtils;
import com.alibaba.cloud.nacos.NacosConfigProperties;
import com.alibaba.cloud.nacos.NacosPropertySourceRepository;
import com.alibaba.cloud.nacos.client.NacosPropertySource;
import com.alibaba.nacos.api.config.ConfigService;
/**
* @author xiaojing
*/

View File

@@ -14,22 +14,7 @@
* limitations under the License.
*/
package org.springframework.cloud.alibaba.nacos.refresh;
import com.alibaba.nacos.api.config.ConfigService;
import com.alibaba.nacos.api.config.listener.Listener;
import com.alibaba.nacos.api.exception.NacosException;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.boot.context.event.ApplicationReadyEvent;
import org.springframework.cloud.alibaba.nacos.NacosPropertySourceRepository;
import org.springframework.cloud.alibaba.nacos.client.NacosPropertySource;
import org.springframework.cloud.endpoint.event.RefreshEvent;
import org.springframework.context.ApplicationContext;
import org.springframework.context.ApplicationContextAware;
import org.springframework.context.ApplicationListener;
import org.springframework.util.StringUtils;
package com.alibaba.cloud.nacos.refresh;
import java.io.UnsupportedEncodingException;
import java.math.BigInteger;
@@ -41,6 +26,21 @@ import java.util.concurrent.Executor;
import java.util.concurrent.atomic.AtomicBoolean;
import java.util.concurrent.atomic.AtomicLong;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.boot.context.event.ApplicationReadyEvent;
import org.springframework.cloud.endpoint.event.RefreshEvent;
import org.springframework.context.ApplicationContext;
import org.springframework.context.ApplicationContextAware;
import org.springframework.context.ApplicationListener;
import org.springframework.util.StringUtils;
import com.alibaba.cloud.nacos.NacosPropertySourceRepository;
import com.alibaba.cloud.nacos.client.NacosPropertySource;
import com.alibaba.nacos.api.config.ConfigService;
import com.alibaba.nacos.api.config.listener.Listener;
import com.alibaba.nacos.api.exception.NacosException;
/**
* On application start up, NacosContextRefresher add nacos listeners to all application
* level dataIds, when there is a change in the data, listeners will refresh

View File

@@ -14,7 +14,7 @@
* limitations under the License.
*/
package org.springframework.cloud.alibaba.nacos.refresh;
package com.alibaba.cloud.nacos.refresh;
import java.text.DateFormat;
import java.text.SimpleDateFormat;

View File

@@ -14,7 +14,7 @@
* limitations under the License.
*/
package org.springframework.cloud.alibaba.nacos.refresh;
package com.alibaba.cloud.nacos.refresh;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.stereotype.Component;

View File

@@ -1,7 +1,7 @@
org.springframework.cloud.bootstrap.BootstrapConfiguration=\
org.springframework.cloud.alibaba.nacos.NacosConfigBootstrapConfiguration
com.alibaba.cloud.nacos.NacosConfigBootstrapConfiguration
org.springframework.boot.autoconfigure.EnableAutoConfiguration=\
org.springframework.cloud.alibaba.nacos.NacosConfigAutoConfiguration,\
org.springframework.cloud.alibaba.nacos.endpoint.NacosConfigEndpointAutoConfiguration
com.alibaba.cloud.nacos.NacosConfigAutoConfiguration,\
com.alibaba.cloud.nacos.endpoint.NacosConfigEndpointAutoConfiguration
org.springframework.boot.diagnostics.FailureAnalyzer=\
org.springframework.cloud.alibaba.nacos.diagnostics.analyzer.NacosConnectionFailureAnalyzer
com.alibaba.cloud.nacos.diagnostics.analyzer.NacosConnectionFailureAnalyzer