123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566 |
- ## eureka客户端配置
- # 注册是使用真实IP
- eureka.instance.preferIpAddress = true
- # 是否启用 eureka
- eureka.client.enabled = true
- # eureka 地址
- #eureka.client.serviceUrl.defaultZone = http://eureka1:8766/eureka/,http://eureka2:8767/eureka,http://eureka3:8768/eureka
- eureka.client.serviceUrl.defaultZone = http://127.0.0.1:8821/eureka/
- # 是否注册到eureka
- eureka.client.register-with-eureka = true
- # 是否从eureka服务器获取注册信息
- eureka.client.fetch-registry = true
- ## redis 配置
- #spring.redis.host=r-2zee62341d4d38f4.redis.rds.aliyuncs.com
- #spring.redis.port=6379
- #spring.redis.password=Efun20170407
- spring.redis.host=192.168.1.151
- spring.redis.port=6379
- spring.redis.password=
- spring.redis.timeout=3000
- spring.redis.pool.max-idle=8
- spring.redis.pool.min-idle=0
- spring.redis.pool.max-active=8
- spring.redis.pool.max-wait=-1
- spring.redis.key.prefix=service.user
- ## 数据源配置
- # 默认数据源
- afw.datasource.default = master
- # 激活数据源列表 起名规则slave_1...
- afw.datasource.active = master,slave
- # 主数据源
- afw.datasource.master.url = jdbc:mysql://localhost:3306/iaas_user?useUnicode=true&characterEncoding=utf-8&autoReconnect=true&allowMultiQueries=true
- afw.datasource.master.username = root
- afw.datasource.master.password = 123456
- afw.datasource.master.initial_size = 10
- afw.datasource.master.min_idle = 10
- afw.datasource.master.max_active = 100
- afw.datasource.master.test_while_idle = true
- afw.datasource.master.max_wait = 60000
- afw.datasource.master.test_on_borrow=true
- afw.datasource.master.validation_query=SELECT 1;
- # 从数据源
- afw.datasource.slave.url = jdbc:mysql://localhost:3306/iaas_user?useUnicode=true&characterEncoding=utf-8&autoReconnect=true&allowMultiQueries=true
- afw.datasource.slave.username = root
- afw.datasource.slave.password = 123456
- afw.datasource.slave.initial_size = 10
- afw.datasource.slave.min_idle = 10
- afw.datasource.slave.max_active = 100
- afw.datasource.slave.test_while_idle = true
- afw.datasource.slave.max_wait = 60000
- afw.datasource.slave.test_on_borrow=true
- afw.datasource.slave.validation_query=SELECT 1;
- # 打印sql
- spring.jpa.properties.hibernate.show_sql=true
- spring.jpa.properties.hibernate.format_sql=true
|