parent
f6313df57a
commit
695b730384
|
@ -29,7 +29,7 @@ public class DataSourceLoader {
|
|||
|
||||
public void refreshDataSources() {
|
||||
DynamicRoutingDataSource ds = (DynamicRoutingDataSource) dataSource;
|
||||
DataSource mainDataSource = ds.getDataSource("");
|
||||
DataSource mainDataSource = ds.getDataSource("devops");
|
||||
|
||||
// 从主数据源读取配置
|
||||
List<DataSourceEntity> configs = new JdbcTemplate(mainDataSource).query(
|
||||
|
|
|
@ -185,18 +185,17 @@ spring:
|
|||
username: nu_sys
|
||||
password: nu_sys
|
||||
driver-class-name: com.mysql.cj.jdbc.Driver
|
||||
# 多数据源配置
|
||||
# multi-datasource1:
|
||||
# url: jdbc:mysql://1.92.152.160:33061/nursing_unitMediaManageMQListener?characterEncoding=UTF-8&useUnicode=true&useSSL=false&tinyInt1isBit=false&allowPublicKeyRetrieval=true&serverTimezone=Asia/Shanghai
|
||||
# username: root
|
||||
# password: root
|
||||
# driver-class-name: com.mysql.cj.jdbc.Driver
|
||||
#运维只读账号
|
||||
devops:
|
||||
url: jdbc:mysql://192.168.2.199:3306/nu_devops?characterEncoding=UTF-8&useUnicode=true&useSSL=false&tinyInt1isBit=false&allowPublicKeyRetrieval=true&serverTimezone=Asia/Shanghai
|
||||
username: nudoro
|
||||
password: nudoro
|
||||
username: nu_sys
|
||||
password: nu_sys
|
||||
driver-class-name: com.mysql.cj.jdbc.Driver
|
||||
#运维只读账号
|
||||
# devops:
|
||||
# url: jdbc:mysql://192.168.2.199:3306/nu_devops?characterEncoding=UTF-8&useUnicode=true&useSSL=false&tinyInt1isBit=false&allowPublicKeyRetrieval=true&serverTimezone=Asia/Shanghai
|
||||
# username: nudoro
|
||||
# password: nudoro
|
||||
# driver-class-name: com.mysql.cj.jdbc.Driver
|
||||
#redis 配置
|
||||
redis:
|
||||
database: 0
|
||||
|
|
|
@ -185,18 +185,17 @@ spring:
|
|||
username: fw8864sshdang
|
||||
password: uGDBkM25I6nZCNM2
|
||||
driver-class-name: com.mysql.cj.jdbc.Driver
|
||||
# 多数据源配置
|
||||
#multi-datasource1:
|
||||
#url: jdbc:mysql://localhost:3306/jeecg-boot2?useUnicode=true&characterEncoding=utf8&autoReconnect=true&zeroDateTimeBehavior=convertToNull&transformedBitIsBoolean=true&allowPublicKeyRetrieval=true&serverTimezone=Asia/Shanghai
|
||||
#username: root
|
||||
#password: root
|
||||
#driver-class-name: com.mysql.cj.jdbc.Driver
|
||||
#运维只读账号
|
||||
devops:
|
||||
url: jdbc:mysql://mysql8-prod:3306/nu_devops?characterEncoding=UTF-8&useUnicode=true&useSSL=false&tinyInt1isBit=false&allowPublicKeyRetrieval=true&serverTimezone=Asia/Shanghai
|
||||
username: nudoro
|
||||
password: nudoro
|
||||
username: fw8864sshdang
|
||||
password: uGDBkM25I6nZCNM2
|
||||
driver-class-name: com.mysql.cj.jdbc.Driver
|
||||
#运维只读账号
|
||||
# devops:
|
||||
# url: jdbc:mysql://mysql8-prod:3306/nu_devops?characterEncoding=UTF-8&useUnicode=true&useSSL=false&tinyInt1isBit=false&allowPublicKeyRetrieval=true&serverTimezone=Asia/Shanghai
|
||||
# username: nudoro
|
||||
# password: nudoro
|
||||
# driver-class-name: com.mysql.cj.jdbc.Driver
|
||||
#redis 配置
|
||||
redis:
|
||||
database: 1
|
||||
|
|
Loading…
Reference in New Issue