|
@@ -1,184 +0,0 @@
|
|
|
-mysql.addr=192.168.31.159
|
|
|
-#绑定IP
|
|
|
-server.address=0.0.0.0
|
|
|
-# 应用程序端口
|
|
|
-server.port=8020
|
|
|
-server.tomcat.max-threads=1000
|
|
|
-server.tomcat.max-connections=20000
|
|
|
-server.tomcat.min-spare-threads=50
|
|
|
-server.tomcat.accept-count=20000
|
|
|
-# 数据库连接地址
|
|
|
-spring.datasource.url=jdbc:mysql://${mysql.addr}:3306/cloud?useUnicode=true&characterEncoding=utf-8&serverTimezone=Asia/Shanghai&useSSL=false
|
|
|
-# 数据库驱动
|
|
|
-spring.datasource.driverClassName=com.mysql.cj.jdbc.Driver
|
|
|
-#spring.datasource.driverClassName = com.mysql.jdbc.Driver
|
|
|
-
|
|
|
-# 数据库用户名
|
|
|
-spring.datasource.username=cloud
|
|
|
-# 数据库密码
|
|
|
-spring.datasource.password=Cloud.123456
|
|
|
-# 参数别名设置
|
|
|
-mybatis.type-aliases-package=com.vcloud.game.vo
|
|
|
-#下划线与驼峰转换
|
|
|
-mybatis.configuration.mapUnderscoreToCamelCase=true
|
|
|
-# 指定连接池中最大的活跃连接数
|
|
|
-spring.datasource.max-active=30
|
|
|
-# 指定连接池最大的空闲连接数量
|
|
|
-spring.datasource.max-idle=30
|
|
|
-# 指定必须保持连接的最小值
|
|
|
-spring.datasource.min-idle=10
|
|
|
-# 指定启动连接池时,初始建立的连接数量
|
|
|
-spring.datasource.initial-size=10
|
|
|
-#指定注册到Eureka Server上的应用名称
|
|
|
-spring.application.name=cloud-game
|
|
|
-spring.rabbitmq.host=192.168.31.159
|
|
|
-spring.rabbitmq.port=5672
|
|
|
-spring.rabbitmq.username=cloud
|
|
|
-spring.rabbitmq.password=Cloud.123456
|
|
|
-#自定义eureka的IP地址,默认是本机
|
|
|
-eureka.addr=127.0.0.1
|
|
|
-#注册中心地址
|
|
|
-eureka.client.serviceUrl.defaultZone=http://${eureka.addr}:8010/eureka/
|
|
|
-#Eureka互相注册要求各个Eureka实例的eureka.instance.hostname
|
|
|
-eureka.instance.hostname=${spring.cloud.client.ip-address}:${server.port}
|
|
|
-# 将自己的IP注册到Eureka Server,并显示IP和端口
|
|
|
-eureka.instance.instance-id=${spring.cloud.client.ip-address}:${server.port}
|
|
|
-# 注册到Eureka Server的ip地址
|
|
|
-spring.cloud.inetutils.preferred-networks=127.0.0.1
|
|
|
-eureka.instance.prefer-ip-address=true
|
|
|
-#### ribbon ####
|
|
|
-# 开启饥饿加载
|
|
|
-ribbon.eager-load.enabled=true
|
|
|
-#### feign ####
|
|
|
-# 设置属性配置比java代码配置的优先级低
|
|
|
-feign.client.default-to-properties=false
|
|
|
-# 相当于Request.Options
|
|
|
-feign.client.config.default.connect-timeout=10000
|
|
|
-# 相当于Request.Options
|
|
|
-feign.client.config.default.read-timeout=10000
|
|
|
-# 配置Feign的日志级别,相当于代码配置中的Logger
|
|
|
-feign.client.config.default.logger-level=basic
|
|
|
-#feign.client.config.provider-demo01.connect-timeout=5000
|
|
|
-#feign.client.config.provider-demo01.read-timeout=5000
|
|
|
-#feign.client.config.provider-demo01.logger-level=full
|
|
|
-# 延长Hystrix超时时间,默认1000ms
|
|
|
-hystrix.command.default.execution.isolation.thread.timeoutInMilliseconds=10000
|
|
|
-# Ribbon超时设置
|
|
|
-#ribbon请求连接的超时时间- 限制3秒内必须请求到服务,并不限制服务处理的返回时间
|
|
|
-ribbon.ConnectTimeout=3000
|
|
|
-#请求处理的超时时间 下级服务响应最大时间,超出时间消费方(路由也是消费方)返回timeout
|
|
|
-ribbon.ReadTimeout=5000
|
|
|
-#当在配置时间窗口内达到此数量的失败后,进行短路。默认20个)
|
|
|
-hystrix.command.default.circuitBreaker.requestVolumeThreshold=20
|
|
|
-#短路多久以后开始尝试是否恢复,默认5s)
|
|
|
-hystrix.command.default.circuitBreaker.sleepWindowInMilliseconds=10
|
|
|
-#出错百分比阈值,当达到此阈值后,开始短路。默认50%)
|
|
|
-hystrix.command.default.circuitBreaker.errorThresholdPercentage=50%
|
|
|
-
|
|
|
-##### 重试机制 #######
|
|
|
-#该参数用来开启重试机制,默认是关闭
|
|
|
-#spring.cloud.loadbalancer.retry.enabled=true
|
|
|
-#对所有操作请求都进行重试
|
|
|
-#ribbon.OkToRetryOnAllOperations=true
|
|
|
-#对当前实例的重试次数
|
|
|
-#ribbon.MaxAutoRetries=1
|
|
|
-#切换实例的重试次数
|
|
|
-#ribbon.MaxAutoRetriesNextServer=1
|
|
|
-
|
|
|
-# 定位模板的目录
|
|
|
-spring.mvc.view.prefix=classpath:/templates/
|
|
|
-# 给返回的页面添加后缀名
|
|
|
-spring.mvc.view.suffix=.html
|
|
|
-## 静态资源前缀
|
|
|
-spring.mvc.static-path-pattern=/static/**
|
|
|
-## 默认路径
|
|
|
-spring.resources.static-locations=/META-INF/resources/,classpath:/resources/,classpath:/static/
|
|
|
-
|
|
|
-####### redis #######
|
|
|
-# Redis数据库索引(默认为0)
|
|
|
-spring.redis.database=0
|
|
|
-# Redis服务器地址
|
|
|
-spring.redis.host=192.168.31.159
|
|
|
-# Redis服务器连接端口
|
|
|
-spring.redis.port=6379
|
|
|
-# Redis服务器连接密码(默认为空)
|
|
|
-spring.redis.password=cloud
|
|
|
-# 连接池最大连接数(使用负值表示没有限制)
|
|
|
-spring.redis.jedis.pool.max-active=30
|
|
|
-# 连接池最大阻塞等待时间(使用负值表示没有限制)
|
|
|
-spring.redis.jedis.pool.max-wait=-1
|
|
|
-# 连接池中的最大空闲连接
|
|
|
-spring.redis.jedis.pool.max-idle=30
|
|
|
-# 连接池中的最小空闲连接
|
|
|
-spring.redis.jedis.pool.min-idle=0
|
|
|
-# 连接超时时间(毫秒)
|
|
|
-spring.redis.timeout=5000
|
|
|
-
|
|
|
-###### 日志 #######
|
|
|
-logging.path=/var/log/cloud
|
|
|
-#指向日志配置文件的位置
|
|
|
-logging.config=classpath:logback-spring.xml
|
|
|
-#控制台打印日志格式设置,注意在logback-spring.xml里用CONSOLE_LOG_PATTERN才能获取到
|
|
|
-logging.pattern.console=[%d{yyyy-MM-dd HH:mm:ss}] -- [%-5p]: [%c] -- %m%n
|
|
|
-#文件打印日志格式设置,注意在logback-spring.xml里用FILE_LOG_PATTERN才能获取到
|
|
|
-logging.pattern.file=[%d{yyyy-MM-dd HH:mm:ss}] -- [%-5p]: [%c] -- %m%n
|
|
|
-
|
|
|
-# 字符编码
|
|
|
-spring.http.encoding.charset=UTF-8
|
|
|
-spring.http.encoding.enabled=true
|
|
|
-spring.http.encoding.force=true
|
|
|
-
|
|
|
-# 文件保存路径
|
|
|
-upload.filePath =/usr/vcloud/upload
|
|
|
-
|
|
|
-#springboot 2.0后的配置文件大小方式
|
|
|
-spring.servlet.multipart.max-file-size=2000MB
|
|
|
-spring.servlet.multipart.max-request-size=2000MB
|
|
|
-
|
|
|
-#pagehelper分页插件配置
|
|
|
-pagehelper.helperDialect=mysql
|
|
|
-pagehelper.reasonable=true
|
|
|
-pagehelper.supportMethodsArguments=true
|
|
|
-pagehelper.params=count=countSql
|
|
|
-
|
|
|
-# ftp相关配置
|
|
|
-ftpHost=192.168.31.164
|
|
|
-ftpPort=21
|
|
|
-ftpUserName=ftpadmin
|
|
|
-ftpPassword=admin@123
|
|
|
-basePath=/var/ftp/pub
|
|
|
-
|
|
|
-
|
|
|
-# fadf文件系统配置信息
|
|
|
-# socket连接超时时长
|
|
|
-fdfs.so-timeout=15000
|
|
|
-# 连接tracker服务器超时时长
|
|
|
-fdfs.connect-timeout=8000
|
|
|
-#缩略图生成参数,可选
|
|
|
-fdfs.thumb-image.width=150
|
|
|
-fdfs.thumb-image.height=150
|
|
|
-#TrackerList参数,支持多个
|
|
|
-fdfs.tracker-list=192.168.129.194:22122,192.168.129.196:22122
|
|
|
-fdfs.web-server-url=192.168.129.194:88,192.168.129.196:88
|
|
|
-## 连接池最大数量,配置为-1表示不限制
|
|
|
-fdfs.pool.max-total=-1
|
|
|
-## 每个tracker(key)最大连接数
|
|
|
-fdfs.pool.max-total-per-key=200
|
|
|
-# 每个key对应的连接池最大空闲连接数
|
|
|
-fdfs.pool.max-idle-per-key=100
|
|
|
-# 每个key对应的连接池最小空闲连接数
|
|
|
-fdfs.pool.max_idle_per_key=5
|
|
|
-# 连接耗尽时是否阻塞(默认true)
|
|
|
-fdfs.pool.block-when-exhausted=true
|
|
|
-# 连接耗尽时等待获取连接的最大毫秒数
|
|
|
-fdfs.pool.max-wait-millis=60000
|
|
|
-# 视休眠时间超过了180秒的对象为过期
|
|
|
-fdfs.pool.min-evictable-idle-time-millis=180000
|
|
|
-# 在空闲时检查有效性, 默认false
|
|
|
-fdfs.pool.test-while-idle=true
|
|
|
-# 逐出扫描的时间间隔(毫秒),如果为负数,则不运行逐出线程, 默认-1
|
|
|
-fdfs.pool.time-between-eviction-runs-millis=20000
|
|
|
-# 每次逐出检查时 逐出的最大数目, -1表示清理时检查所有线程
|
|
|
-fdfs.pool.num-tests-per-eviction-run= -1
|
|
|
-# 设置token过期时长为15分钟
|
|
|
-token_timeout = 900000
|