You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
43 lines
2.1 KiB
43 lines
2.1 KiB
# 应用服务 WEB 访问端口
|
|
server.port=8090
|
|
#
|
|
spring.datasource.driver-class-name=com.mysql.cj.jdbc.Driver
|
|
spring.datasource.url=jdbc:mysql://localhost:3306/bcdb
|
|
spring.datasource.username=root
|
|
spring.datasource.password=root
|
|
#
|
|
#Java代码实体字段命名与数据库表结构字段之间的名称映射策略
|
|
spring.jpa.hibernate.naming.implicit-strategy=org.hibernate.boot.model.naming.ImplicitNamingStrategyLegacyJpaImpl
|
|
#下面配置开启后,会禁止将驼峰转为下划线
|
|
#spring.jpa.hibernate.naming.physical-strategy=org.hibernate.boot.model.naming.PhysicalNamingStrategyStandardImpl
|
|
spring.jpa.database-platform=org.hibernate.dialect.MySQL5Dialect
|
|
# 调试语句
|
|
spring.jpa.show-sql=true
|
|
#
|
|
# logback日志操作
|
|
logging.config=classpath:logback-spring.xml
|
|
logging.path=./logs/
|
|
#
|
|
#spring.datasource.hikari.connection-timeout=1200
|
|
#spring.datasource.hikari.connection-test-query=SELECT * FROM DUAL;
|
|
|
|
## Spring HikariConfig
|
|
# 事务自动提交 - 默认值:true
|
|
spring.datasource.hikari.auto-commit=true
|
|
# 连接测试查询 - Using the JDBC4 <code>Connection.isValid()</code> method to test connection validity can be more efficient on some databases and is recommended.
|
|
# 如果你的驱动程序支持JDBC4,强烈建议不要设置此属性。
|
|
spring.datasource.hikari.connection-test-query=select 1
|
|
# 连接超时时间 - 默认值:30秒。
|
|
spring.datasource.hikari.connection-timeout=30000
|
|
# 连接池中允许闲置的最长时间 - 默认值:10分钟
|
|
spring.datasource.hikari.idle-timeout=600000
|
|
# 一个连接生命时长(毫秒),超时而没被使用则被释放 - 默认值:30分钟
|
|
spring.datasource.hikari.max-lifetime=1800000
|
|
# 连接池中允许的最大连接数,包括闲置和使用中的连接 - 默认值:10
|
|
spring.datasource.hikari.maximum-pool-size=100
|
|
# 连接池中允许的最小空闲连接数 - 默认值:10。
|
|
spring.datasource.hikari.minimum-idle=10
|
|
# 连接被测试活动的最长时间 - 默认值:5秒。
|
|
spring.datasource.hikari.validation-timeout=5000
|
|
# 指定连接池的名称 - 默认自动生成
|
|
spring.datasource.hikari.pool-name=HikaraPool-1
|
|
|