Commit 9b1e8af5 authored by 钱坤's avatar 钱坤

改为机构版的配置

parent 7fc5ead1
......@@ -30,7 +30,7 @@
<dependency>
<groupId>com.tanpu</groupId>
<artifactId>common</artifactId>
<version>0.0.1-SNAPSHOT</version>
<version>0.0.1-feo-SNAPSHOT</version>
<exclusions>
<exclusion>
<artifactId>commons-pool2</artifactId>
......@@ -270,7 +270,7 @@
</dependencyManagement>
<build>
<finalName>fund</finalName>
<finalName>feo-fund</finalName>
<plugins>
<plugin>
<groupId>org.springframework.boot</groupId>
......
......@@ -14,7 +14,7 @@ import springfox.documentation.swagger2.annotations.EnableSwagger2;
import static com.google.common.collect.Lists.newArrayList;
import static com.google.common.collect.Sets.newHashSet;
@Profile("dev")
@Profile({"dev","test"})
@Configuration
@EnableSwagger2
public class Swagger2Config {
......
......@@ -6,6 +6,7 @@ import com.ctrip.framework.apollo.spring.annotation.ApolloConfig;
import com.ctrip.framework.apollo.spring.annotation.ApolloConfigChangeListener;
import com.ctrip.framework.apollo.spring.boot.ApolloAutoConfiguration;
import com.ctrip.framework.apollo.spring.config.PropertySourcesConstants;
import com.tanpu.common.enums.Constant;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.BeansException;
import org.springframework.boot.autoconfigure.AutoConfigureAfter;
......@@ -36,7 +37,7 @@ public class ApolloRefresherConfiguration implements ApplicationContextAware {
}
// 刷新参数(刷新"common"和"application"空间中,"logging.level."或"aniu."开头的配置 )
@ApolloConfigChangeListener(value = { "common", "application" }, interestedKeyPrefixes = { "logging.level.",
@ApolloConfigChangeListener(value = {Constant.APOLLO_COMMON_APP_ID, "application" }, interestedKeyPrefixes = { "logging.level.",
"tanpu." })
public void onChangeLogLevel(ConfigChangeEvent changeEvent) {
log.info("Refreshing logging levels and tanpu.");
......
......@@ -4,7 +4,7 @@ apollo.bootstrap.enabled=true
##关闭placeholder在运行时自动更新功能
##apollo.autoUpdateInjectedSpringProperties=false
#appid
app.id=tanpu-fund
app.id=feo-fund
#配置中心地址
apollo.meta=http://apollo.caixiaoquan.com:8080
#配置中心缓存路径
......@@ -12,5 +12,5 @@ apollo.cacheDir=./apollocache/
#监听namespaces
#common公共空间
#application业务系统自身空间
apollo.bootstrap.namespaces=application,common
apollo.bootstrap.namespaces=application,feo-common
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment