调整配置

This commit is contained in:
wanggeng888 2021-05-06 17:56:48 +08:00
parent 063cc9c0b1
commit b9f639e286
2 changed files with 22 additions and 22 deletions

View File

@ -1,6 +1,6 @@
server:
port: 8080
url: http://192.168.0.106:8080/pollutant
port: 7004
url: http://106.12.218.237:8001/pollutant
title: 污染物上报系统
servlet:
context-path: /pollutant
@ -22,11 +22,11 @@ spring:
max-request-size: 1GB
datasource:
druid:
url: jdbc:mysql://127.0.0.1:3306/db_pollutant_data?useUnicode=true&characterEncoding=utf8&characterSetResults=utf8&autoReconnect=true&failOverReadOnly=false&useSSL=false&serverTimezone=UTC
url: jdbc:mysql://localhost:8668/db_pollutant_data?useUnicode=true&characterEncoding=utf8&characterSetResults=utf8&autoReconnect=true&failOverReadOnly=false&useSSL=false&serverTimezone=UTC
db-type: mysql
driver-class-name: com.mysql.jdbc.Driver
username: root
password: root
password: TSkj@0471.123
initial-size: 2
min-idle: 2
max-active: 10
@ -57,19 +57,20 @@ spring:
api-path:
user-center: ${security.oauth2.oauth-server}
inspection: http://192.168.0.106:7006/inspection
inspection: http://106.12.218.237:8081/inspection
system:
# 预警通知上限
alarm-notice-limit: 5
netty:
port: 1991
# 安全
security:
oauth2:
oauth-server: http://192.168.0.103:7001/usercenter
oauth-server: http://106.12.218.237:8001/usercenter
oauth-logout: ${security.oauth2.oauth-server}/logout?redirect_uri=${server.url}
client:
client-id: 74e4b55ad48840f9b4de86ce5da58b53
client-secret: VjlWbUFFbkJKMmZ3U29lekROb2x3M3Q1SmEzOGlwV3NzT3ZqSDByQVZoWW1ac2wwZTJHWk5NbXh3L3h3U2c4Rg==
client-id: e8c97882fbad4e1c8ca12e63b1a7baa5
client-secret: M0ZnWGpHdExzZEUrM3BZYzB0M1ZjZ0xNSkk1QXFzQkZ1dlNtSmozOFgxWW1ac2wwZTJHWk5NbXh3L3h3U2c4Rg==
user-authorization-uri: ${security.oauth2.oauth-server}/oauth_client/authorize
access-token-uri: ${security.oauth2.oauth-server}/oauth_client/token
grant-type: authorization_code
@ -85,10 +86,8 @@ mybatis:
config-location: classpath:mybatis/mybatis-config.xml
mapper-locations: classpath*:mybatis/mapper/**/*.xml
netty:
port: 19091
logging:
file: /tenlion/projects/logs/pollutant/pollutant-logs.log
level:
root: error
com.cm.tenlion: debug
@ -97,14 +96,14 @@ logging:
swagger:
title: 接口文档
description: 隐患排查系统接口文档
service-url: https://baidu.com/
service-url: http://106.12.218.237:8001/pollutant
version: 1.0
swagger-base-package: com.cm
# 文件上传管理
file:
# 文件的保存路径
upload-path: /Users/wanggeng/Desktop/UploadFiles/
upload-path: /tenlion/projects/uploadFiles/
# 图片类型
image-types: png,jpg,jpeg,gif,blob
# 视频类型

View File

@ -31,7 +31,7 @@ import java.util.Random;
*/
public class HJ212Test {
public HJ212DataUtil.Data getData() {
public static HJ212DataUtil.Data getData() {
HJ212DataUtil.Data data = new HJ212DataUtil.Data();
data.setQn(DateUtil.formatDate(System.currentTimeMillis(), "yyyyMMddHHmmssSSS"));
data.setSt(StEnum.AIR.getValue());
@ -59,7 +59,7 @@ public class HJ212Test {
return data;
}
public void hj212ClientTest() {
public static void hj212ClientTest() {
Bootstrap bootstrap = new Bootstrap();
EventLoopGroup eventLoopGroup = new NioEventLoopGroup();
try {
@ -100,7 +100,7 @@ public class HJ212Test {
});
}
});
ChannelFuture channelFuture = bootstrap.connect("124.67.110.246", 1991).sync();
ChannelFuture channelFuture = bootstrap.connect("106.12.218.237", 1991).sync();
channelFuture.addListener((ChannelFutureListener) future -> {
if (!future.isSuccess()) {
future.channel().pipeline().fireChannelInactive();
@ -119,6 +119,7 @@ public class HJ212Test {
}
public static void main(String[] args) {
hj212ClientTest();
// a00000: 废弃
// a05001: 二氧化碳
// a05002: 甲烷
@ -151,11 +152,11 @@ public class HJ212Test {
// w20113: 烷基汞
// 3.乌兰察布市集宁区碧水蓝天污水处理有限公司
// new Thread(new ConnectRunner(StEnum.SEWAGE, "CJY003001", "CJQ003001001", "w00000")).start();
new Thread(new ConnectRunner(StEnum.SEWAGE, "CJY003001", "CJQ003001002", "w01001")).start();
new Thread(new ConnectRunner(StEnum.SEWAGE, "CJY003002", "CJQ003002001", "w01006")).start();
new Thread(new ConnectRunner(StEnum.SEWAGE, "CJY003002", "CJQ003002002", "w01019")).start();
new Thread(new ConnectRunner(StEnum.SEWAGE, "CJY003003", "CJQ003003001", "w02006")).start();
new Thread(new ConnectRunner(StEnum.SEWAGE, "CJY003003", "CJQ003003002", "w20113")).start();
// new Thread(new ConnectRunner(StEnum.SEWAGE, "CJY003001", "CJQ003001002", "w01001")).start();
// new Thread(new ConnectRunner(StEnum.SEWAGE, "CJY003002", "CJQ003002001", "w01006")).start();
// new Thread(new ConnectRunner(StEnum.SEWAGE, "CJY003002", "CJQ003002002", "w01019")).start();
// new Thread(new ConnectRunner(StEnum.SEWAGE, "CJY003003", "CJQ003003001", "w02006")).start();
// new Thread(new ConnectRunner(StEnum.SEWAGE, "CJY003003", "CJQ003003002", "w20113")).start();
}
}