|
@@ -0,0 +1,73 @@
|
|
|
+spring:
|
|
|
+ # 数据源连接--start
|
|
|
+ datasource:
|
|
|
+ # url: jdbc:mysql://172.31.165.27:3306/caimei?characterEncoding=UTF8&serverTimezone=Asia/Shanghai
|
|
|
+ # username: developer
|
|
|
+ # password: J5p3tgOVazNl4ydf
|
|
|
+ url: jdbc:mysql://119.29.164.246:3306/caimei?characterEncoding=UTF8&serverTimezone=Asia/Shanghai
|
|
|
+ username: developer
|
|
|
+ password: 05bZ/OxTB:X+yd%1
|
|
|
+ # Hikari will use the above plus the following to setup connection pooling
|
|
|
+ type: com.zaxxer.hikari.HikariDataSource
|
|
|
+ hikari:
|
|
|
+ minimum-idle: 5
|
|
|
+ maximum-pool-size: 15
|
|
|
+ auto-commit: true
|
|
|
+ idle-timeout: 30000
|
|
|
+ pool-name: DatebookHikariCP
|
|
|
+ max-lifetime: 1800000
|
|
|
+ connection-timeout: 30000
|
|
|
+ connection-test-query: SELECT 1
|
|
|
+ # 数据源连接--end
|
|
|
+
|
|
|
+ redis:
|
|
|
+ host: 172.31.165.27
|
|
|
+ port: 6379
|
|
|
+ password: 6#xsI%b4o@5c3RoE
|
|
|
+ #Redis数据库索引(默认为0)
|
|
|
+ database: 0
|
|
|
+ #连接池最大连接数(使用负值表示没有限制)
|
|
|
+ jedis:
|
|
|
+ pool:
|
|
|
+ max-active: 50
|
|
|
+ #连接池最大阻塞等待时间(使用负值表示没有限制)
|
|
|
+ max-wait: 3000
|
|
|
+ #连接池中的最大空闲连接
|
|
|
+ max-idle: 20
|
|
|
+ #连接池中的最小空闲连接
|
|
|
+ min-idle: 2
|
|
|
+ #连接超时时间(毫秒)
|
|
|
+ timeout: 5000
|
|
|
+
|
|
|
+#整合mybatis
|
|
|
+mybatis:
|
|
|
+ #加载Mybatis映射文件
|
|
|
+ mapper-locations:
|
|
|
+ - classpath:mapper/*.xml
|
|
|
+
|
|
|
+# 指定服务注册中心的地址
|
|
|
+eureka:
|
|
|
+ instance:
|
|
|
+ prefer-ip-address: true # 是否使用 ip 地址注册
|
|
|
+ instance-id: ${spring.cloud.client.ip-address}:${server.port} # ip:port
|
|
|
+ client:
|
|
|
+ service-url: # 设置服务注册中心地址
|
|
|
+ defaultZone: http://47.119.112.46:18000/eureka/
|
|
|
+
|
|
|
+
|
|
|
+#日志配置
|
|
|
+logging:
|
|
|
+ file:
|
|
|
+ path: /mnt/newdatadrive/data/runtime/cloud-instance/server-product/logs
|
|
|
+ level:
|
|
|
+ root: info
|
|
|
+
|
|
|
+
|
|
|
+# swagger配置
|
|
|
+swagger:
|
|
|
+ # swagger开启状态,true开启,false关闭
|
|
|
+ enabled: true
|
|
|
+ ui-config:
|
|
|
+ operations-sorter: method
|
|
|
+
|
|
|
+
|