diff --git a/.gitignore b/.gitignore
index 946122611..94ae218b1 100644
--- a/.gitignore
+++ b/.gitignore
@@ -1,6 +1,6 @@
target/
!.mvn/wrapper/maven-wrapper.jar
-logs/
+dc3-logs/
### STS ###
.apt_generated
diff --git a/dc3-dbs/src/main/java/com/pnoker/DbServiceApplication.java b/dc3-dbs/src/main/java/com/pnoker/Dc3DbsApplication.java
similarity index 78%
rename from dc3-dbs/src/main/java/com/pnoker/DbServiceApplication.java
rename to dc3-dbs/src/main/java/com/pnoker/Dc3DbsApplication.java
index 64be0b3c0..d6f092058 100644
--- a/dc3-dbs/src/main/java/com/pnoker/DbServiceApplication.java
+++ b/dc3-dbs/src/main/java/com/pnoker/Dc3DbsApplication.java
@@ -10,9 +10,9 @@ import org.springframework.cloud.netflix.eureka.EnableEurekaClient;
*/
@EnableEurekaClient
@SpringBootApplication
-public class DbServiceApplication {
+public class Dc3DbsApplication {
public static void main(String[] args) {
- SpringApplication.run(DbServiceApplication.class, args);
+ SpringApplication.run(Dc3DbsApplication.class, args);
}
}
diff --git a/dc3-dbs/src/main/java/com/pnoker/controller/IndexController.java b/dc3-dbs/src/main/java/com/pnoker/controller/IndexController.java
index 6944d885d..c0fc0db3d 100644
--- a/dc3-dbs/src/main/java/com/pnoker/controller/IndexController.java
+++ b/dc3-dbs/src/main/java/com/pnoker/controller/IndexController.java
@@ -1,6 +1,8 @@
package com.pnoker.controller;
import lombok.extern.slf4j.Slf4j;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.core.env.Environment;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RestController;
@@ -14,8 +16,11 @@ import org.springframework.web.bind.annotation.RestController;
@Slf4j
@RestController
public class IndexController {
+ @Autowired
+ private Environment environment;
+
@RequestMapping(value = "/hello", method = RequestMethod.GET)
public String helloController() {
- return "hello world";
+ return String.format("hello world with %s", environment.getProperty("server.port"));
}
}
diff --git a/dc3-dbs/src/main/resources/application.yml b/dc3-dbs/src/main/resources/application.yml
index bedecd462..9d260cb27 100644
--- a/dc3-dbs/src/main/resources/application.yml
+++ b/dc3-dbs/src/main/resources/application.yml
@@ -20,7 +20,7 @@ spring:
# 日志配置
logging:
- file: logs/dc3-dbs.log
+ file: dc3-logs/dc3-dbs.log
#配置Actuator监控路径 * 表示全部监控
management:
diff --git a/dc3-dbs/src/main/resources/banner.txt b/dc3-dbs/src/main/resources/banner.txt
index 885f0acb6..fcbf46409 100644
--- a/dc3-dbs/src/main/resources/banner.txt
+++ b/dc3-dbs/src/main/resources/banner.txt
@@ -1,7 +1,6 @@
- _ _____ _ _
- | | |____ | | | |
- __| | ___ / /______ __| | |__ ___
- / _` |/ __| \ \______/ _` | '_ \/ __|
-| (_| | (__.___/ / | (_| | |_) \__ \
- \__,_|\___\____/ \__,_|_.__/|___/
-
+ .___ ________ .___ ___________ .__ __ _____
+ __| _/____ \_____ \ ____ ______ ____ ____ __________ __ _________ ____ ____ | | ___\__ ___/ ______ | | _____ _/ |__/ ____\___________ _____
+ / __ |/ ___\ _(__ < / _ \\____ \_/ __ \ / \ ______ / ___/ _ \| | \_ __ \_/ ___\/ __ \ | |/ _ \| | \____ \| | \__ \\ __\ __\/ _ \_ __ \/ \
+/ /_/ \ \___ / \ ( <_> ) |_> > ___/| | \ /_____/ \___ ( <_> ) | /| | \/\ \__\ ___/ | ( <_> ) | | |_> > |__/ __ \| | | | ( <_> ) | \/ Y Y \
+\____ |\___ >______ / \____/| __/ \___ >___| / /____ >____/|____/ |__| \___ >___ > |___|\____/|____| | __/|____(____ /__| |__| \____/|__| |__|_| /
+ \/ \/ \/ |__| \/ \/ \/ \/ \/ |__| \/ \/
\ No newline at end of file
diff --git a/dc3-service-center/src/main/java/com/pnoker/ServiceCenterApplication.java b/dc3-service-center/src/main/java/com/pnoker/Dc3ServiceCenterApplication.java
similarity index 76%
rename from dc3-service-center/src/main/java/com/pnoker/ServiceCenterApplication.java
rename to dc3-service-center/src/main/java/com/pnoker/Dc3ServiceCenterApplication.java
index 3ec7230c5..198e1d128 100644
--- a/dc3-service-center/src/main/java/com/pnoker/ServiceCenterApplication.java
+++ b/dc3-service-center/src/main/java/com/pnoker/Dc3ServiceCenterApplication.java
@@ -10,9 +10,9 @@ import org.springframework.cloud.netflix.eureka.server.EnableEurekaServer;
*/
@EnableEurekaServer
@SpringBootApplication
-public class ServiceCenterApplication {
+public class Dc3ServiceCenterApplication {
public static void main(String[] args) {
- SpringApplication.run(ServiceCenterApplication.class, args);
+ SpringApplication.run(Dc3ServiceCenterApplication.class, args);
}
}
diff --git a/dc3-service-center/src/main/resources/application.yml b/dc3-service-center/src/main/resources/application.yml
index f446ca1ba..669f88d1f 100644
--- a/dc3-service-center/src/main/resources/application.yml
+++ b/dc3-service-center/src/main/resources/application.yml
@@ -7,11 +7,11 @@ server:
spring:
application:
- name: dc3-service
+ name: dc3-service-center
# 日志配置
logging:
- file: logs/dc3-service.log
+ file: dc3-logs/dc3-service-center.log
#配置Actuator监控路径 * 表示全部监控
management:
diff --git a/dc3-service-center/src/main/resources/banner.txt b/dc3-service-center/src/main/resources/banner.txt
index 7ad72fcc4..fcbf46409 100644
--- a/dc3-service-center/src/main/resources/banner.txt
+++ b/dc3-service-center/src/main/resources/banner.txt
@@ -1,7 +1,6 @@
- _ _____ _
- | | |____ | (_)
- __| | ___ / /______ ___ ___ _ ____ ___ ___ ___
- / _` |/ __| \ \______/ __|/ _ \ '__\ \ / / |/ __/ _ \
-| (_| | (__.___/ / \__ \ __/ | \ V /| | (_| __/
- \__,_|\___\____/ |___/\___|_| \_/ |_|\___\___|
-
+ .___ ________ .___ ___________ .__ __ _____
+ __| _/____ \_____ \ ____ ______ ____ ____ __________ __ _________ ____ ____ | | ___\__ ___/ ______ | | _____ _/ |__/ ____\___________ _____
+ / __ |/ ___\ _(__ < / _ \\____ \_/ __ \ / \ ______ / ___/ _ \| | \_ __ \_/ ___\/ __ \ | |/ _ \| | \____ \| | \__ \\ __\ __\/ _ \_ __ \/ \
+/ /_/ \ \___ / \ ( <_> ) |_> > ___/| | \ /_____/ \___ ( <_> ) | /| | \/\ \__\ ___/ | ( <_> ) | | |_> > |__/ __ \| | | | ( <_> ) | \/ Y Y \
+\____ |\___ >______ / \____/| __/ \___ >___| / /____ >____/|____/ |__| \___ >___ > |___|\____/|____| | __/|____(____ /__| |__| \____/|__| |__|_| /
+ \/ \/ \/ |__| \/ \/ \/ \/ \/ |__| \/ \/
\ No newline at end of file
diff --git a/dc3-webapp/src/main/java/com/pnoker/WebappApplication.java b/dc3-webapp/src/main/java/com/pnoker/Dc3WebappApplication.java
similarity index 87%
rename from dc3-webapp/src/main/java/com/pnoker/WebappApplication.java
rename to dc3-webapp/src/main/java/com/pnoker/Dc3WebappApplication.java
index 371c66961..d63b39274 100644
--- a/dc3-webapp/src/main/java/com/pnoker/WebappApplication.java
+++ b/dc3-webapp/src/main/java/com/pnoker/Dc3WebappApplication.java
@@ -15,9 +15,9 @@ import org.springframework.web.client.RestTemplate;
@EnableAsync
@EnableDiscoveryClient
@SpringBootApplication
-public class WebappApplication {
+public class Dc3WebappApplication {
public static void main(String[] args) {
- SpringApplication.run(WebappApplication.class, args);
+ SpringApplication.run(Dc3WebappApplication.class, args);
}
@Bean
diff --git a/dc3-webapp/src/main/java/com/pnoker/controller/IndexController.java b/dc3-webapp/src/main/java/com/pnoker/controller/IndexController.java
index 00fbb26cd..57bf25ad7 100644
--- a/dc3-webapp/src/main/java/com/pnoker/controller/IndexController.java
+++ b/dc3-webapp/src/main/java/com/pnoker/controller/IndexController.java
@@ -19,8 +19,8 @@ public class IndexController {
@Autowired
RestTemplate restTemplate;
- @RequestMapping(value = "/ribbon-consumer", method = RequestMethod.GET)
- public String helloController() {
- return restTemplate.getForEntity("http://DC3-CLI-MODBUS/hello", String.class).getBody();
+ @RequestMapping(value = "/hello", method = RequestMethod.GET)
+ public String hello() {
+ return restTemplate.getForEntity("http://DC3-DBS/hello", String.class).getBody();
}
}
diff --git a/dc3-webapp/src/main/resources/application.yml b/dc3-webapp/src/main/resources/application.yml
index cbce60ece..f7fd9517f 100644
--- a/dc3-webapp/src/main/resources/application.yml
+++ b/dc3-webapp/src/main/resources/application.yml
@@ -7,11 +7,11 @@ server:
spring:
application:
- name: dc3-web
+ name: dc3-webapp
# 日志配置
logging:
- file: logs/dc3-web.log
+ file: dc3-logs/dc3-webapp.log
#配置Actuator监控路径 * 表示全部监控
management:
diff --git a/dc3-webapp/src/main/resources/banner.txt b/dc3-webapp/src/main/resources/banner.txt
index 65cae1cea..fcbf46409 100644
--- a/dc3-webapp/src/main/resources/banner.txt
+++ b/dc3-webapp/src/main/resources/banner.txt
@@ -1,7 +1,6 @@
- _ _____ _
- | | |____ | | |
- __| | ___ / /________ _____| |__
- / _` |/ __| \ \______\ \ /\ / / _ \ '_ \
-| (_| | (__.___/ / \ V V / __/ |_) |
- \__,_|\___\____/ \_/\_/ \___|_.__/
-
+ .___ ________ .___ ___________ .__ __ _____
+ __| _/____ \_____ \ ____ ______ ____ ____ __________ __ _________ ____ ____ | | ___\__ ___/ ______ | | _____ _/ |__/ ____\___________ _____
+ / __ |/ ___\ _(__ < / _ \\____ \_/ __ \ / \ ______ / ___/ _ \| | \_ __ \_/ ___\/ __ \ | |/ _ \| | \____ \| | \__ \\ __\ __\/ _ \_ __ \/ \
+/ /_/ \ \___ / \ ( <_> ) |_> > ___/| | \ /_____/ \___ ( <_> ) | /| | \/\ \__\ ___/ | ( <_> ) | | |_> > |__/ __ \| | | | ( <_> ) | \/ Y Y \
+\____ |\___ >______ / \____/| __/ \___ >___| / /____ >____/|____/ |__| \___ >___ > |___|\____/|____| | __/|____(____ /__| |__| \____/|__| |__|_| /
+ \/ \/ \/ |__| \/ \/ \/ \/ \/ |__| \/ \/
\ No newline at end of file
diff --git a/pom.xml b/pom.xml
index 75d39a771..068106874 100644
--- a/pom.xml
+++ b/pom.xml
@@ -8,7 +8,7 @@
3.0
pom
- 数据采集系统 V3.0 , 基于Spring Cloud框架搭建
+ 开源分布式物联网(IOT)平台 , 基于Spring Cloud框架搭建