Unverified Commit f94dc38c authored by zhangyongtian's avatar zhangyongtian Committed by GitHub

[Optimization][admin] Lack of H2 dependency (#2128)

* [Optimization][admin] Lack of H2 dependency * [Optimization][admin] Lack of H2 dependency * [Optimization][admin] Modified the Chinese garbled characters
parent 134d16ed
...@@ -121,6 +121,11 @@ ...@@ -121,6 +121,11 @@
<artifactId>mysql-connector-java</artifactId> <artifactId>mysql-connector-java</artifactId>
<scope>${scope.runtime}</scope> <scope>${scope.runtime}</scope>
</dependency> </dependency>
<dependency>
<groupId>com.h2database</groupId>
<artifactId>h2</artifactId>
<scope>${scope.runtime}</scope>
</dependency>
<!-- postgresql --> <!-- postgresql -->
<dependency> <dependency>
<groupId>org.postgresql</groupId> <groupId>org.postgresql</groupId>
......
...@@ -16,61 +16,63 @@ ...@@ -16,61 +16,63 @@
# #
# #
########################## application级别通用配置 ########################## ##############################################################################################################################################
##### druid配置 ################################################# Application Level General Configuration ####################################################
#连接池配置(通常来说,只需要修改initialSize、minIdle、maxActive ##############################################################################################################################################
##### Druid Configuration
# Connection pool configuration (usually, only need to modify initialSize, minIdle, maxActive)
spring.datasource.druid.initial-size=10 spring.datasource.druid.initial-size=10
spring.datasource.druid.max-active=500 spring.datasource.druid.max-active=500
spring.datasource.druid.min-idle=10 spring.datasource.druid.min-idle=10
# 配置获取连接等待超时的时间 # Configure the time to wait for the connection to be timed out
spring.datasource.druid.max-wait=60000 spring.datasource.druid.max-wait=60000
#打开PSCache,并且指定每个连接上PSCache的大小 # Open PSCache, and specify the size of PSCache on each connection
spring.datasource.druid.pool-prepared-statements=true spring.datasource.druid.pool-prepared-statements=true
spring.datasource.druid.max-pool-prepared-statement-per-connection-size=20 spring.datasource.druid.max-pool-prepared-statement-per-connection-size=20
spring.datasource.druid.validation-query=SELECT 'x' spring.datasource.druid.validation-query=SELECT 'x'
spring.datasource.druid.test-on-borrow=false spring.datasource.druid.test-on-borrow=false
spring.datasource.druid.test-on-return=false spring.datasource.druid.test-on-return=false
spring.datasource.druid.test-while-idle=true spring.datasource.druid.test-while-idle=true
#配置间隔多久才进行一次检测,检测需要关闭的空闲连接,单位是毫秒 # How long does it take to configure the detection interval to detect idle connections that need to be closed, in milliseconds
spring.datasource.druid.time-between-eviction-runs-millis=60000 spring.datasource.druid.time-between-eviction-runs-millis=60000
#配置一个连接在池中最小生存的时间,单位是毫秒 # Configure the minimum survival time of a connection in the pool, in milliseconds
spring.datasource.druid.min-evictable-idle-time-millis=300000 spring.datasource.druid.min-evictable-idle-time-millis=300000
spring.datasource.druid.filters=stat,wall spring.datasource.druid.filters=stat,wall
# WebStatFilter配置,说明请参考Druid Wiki,配置_配置WebStatFilter # WebStatFilter configuration, please refer to Druid Wiki for instructions, configuration_configure WebStatFilter
#是否启用StatFilter默认值true # Whether to enable StatFilter default value true
spring.datasource.druid.web-stat-filter.enabled=true spring.datasource.druid.web-stat-filter.enabled=true
spring.datasource.druid.web-stat-filter.url-pattern=/* spring.datasource.druid.web-stat-filter.url-pattern=/*
spring.datasource.druid.web-stat-filter.exclusions="*.js , *.gif ,*.jpg ,*.png ,*.css ,*.ico , /druid/*" spring.datasource.druid.web-stat-filter.exclusions="*.js , *.gif ,*.jpg ,*.png ,*.css ,*.ico , /druid/*"
spring.datasource.druid.web-stat-filter.session-stat-max-count=1000 spring.datasource.druid.web-stat-filter.session-stat-max-count=1000
spring.datasource.druid.web-stat-filter.profile-enable=true spring.datasource.druid.web-stat-filter.profile-enable=true
spring.datasource.druid.web-stat-filter.session-stat-enable=false spring.datasource.druid.web-stat-filter.session-stat-enable=false
# StatViewServlet配置 # StatViewServlet configuration
#展示Druid的统计信息,StatViewServlet的用途包括:1.提供监控信息展示的html页面2.提供监控信息的JSON API # To display Druid statistics, the purpose of StatViewServlet includes: 1. Provide html pages for monitoring information display 2. Provide JSON API for monitoring information
#是否启用StatViewServlet默认值true # Whether to enable StatViewServlet default value true
spring.datasource.druid.stat-view-servlet.enabled=true spring.datasource.druid.stat-view-servlet.enabled=true
#根据配置中的url-pattern来访问内置监控页面,如果是上面的配置,内置监控页面的首页是/druid/index.html例如:http://127.0.0.1:9000/druid/index.html # Access the built-in monitoring page according to the url-pattern in the configuration. If it is the above configuration, the home page of the built-in monitoring page is /druid/index.html For example: http://127.0.0.1:9000/druid/index.html
spring.datasource.druid.stat-view-servlet.url-pattern=/druid/* spring.datasource.druid.stat-view-servlet.url-pattern=/druid/*
#允许清空统计数据 # Allow clearing statistics
spring.datasource.druid.stat-view-servlet.reset-enable=true spring.datasource.druid.stat-view-servlet.reset-enable=true
spring.datasource.druid.stat-view-servlet.login-username=admin spring.datasource.druid.stat-view-servlet.login-username=admin
spring.datasource.druid.stat-view-servlet.login-password=admin spring.datasource.druid.stat-view-servlet.login-password=admin
spring.datasource.druid.stat-view-servlet.allow= spring.datasource.druid.stat-view-servlet.allow=
##### mybatis-plus配置 ##### Mybatis-plus Configuration
#字段策略 IGNORED:"忽略判断",NOT_NULL:"非 NULL 判断"),NOT_EMPTY:"非空判断" # Field strategy IGNORED: "ignore judgment", NOT_NULL: "non-NULL judgment"), NOT_EMPTY: "non-null judgment"
mybatis-plus.global-config.db-config.field-strategy=NOT_NULL mybatis-plus.global-config.db-config.field-strategy=NOT_NULL
# 原生配置 # native configuration
mybatis-plus.configuration.map-underscore-to-camel-case=true mybatis-plus.configuration.map-underscore-to-camel-case=true
mybatis-plus.configuration.cache-enabled=false mybatis-plus.configuration.cache-enabled=false
logging.config= classpath:log4j2.xml logging.config= classpath:log4j2.xml
####### 国际化配置 ##### Internationalization Configuration
spring.messages.basename=i18n/messages spring.messages.basename=i18n/messages
# 国际化编码 # Internationalized encoding
spring.messages.encoding=utf-8 spring.messages.encoding=utf-8
# 表示 messages 文件的缓存失效时间,如果不配置则缓存一直有效。 # Indicates the cache expiration time of the messages file, if not configured, the cache will always be valid.
spring.messages.cache-duration=3600 spring.messages.cache-duration=3600
# 在找不到当前系统对应的资源文件时,如果该属性为 true,则会默认查找当前系统对应的资源文件,否则就返回 null,返回 null 之后,最终又会调用到系统默认的 messages.properties 文件 # When the resource file corresponding to the current system cannot be found, if this property is true, it will search for the resource file corresponding to the current system by default, otherwise it will return null. After returning null, it will eventually call the system default messages.properties file
spring.messages.fallback-to-system-locale=true spring.messages.fallback-to-system-locale=true
...@@ -60,6 +60,7 @@ ...@@ -60,6 +60,7 @@
<docker.java.version>3.2.14</docker.java.version> <docker.java.version>3.2.14</docker.java.version>
<druid-starter>1.2.8</druid-starter> <druid-starter>1.2.8</druid-starter>
<guava.version>31.1-jre</guava.version> <guava.version>31.1-jre</guava.version>
<h2database.version>1.4.200</h2database.version>
<hamcrest.version>1.3</hamcrest.version> <hamcrest.version>1.3</hamcrest.version>
<hibernate-validator.version>6.2.0.Final</hibernate-validator.version> <hibernate-validator.version>6.2.0.Final</hibernate-validator.version>
<httpclient.version>4.5.13</httpclient.version> <httpclient.version>4.5.13</httpclient.version>
...@@ -292,6 +293,11 @@ ...@@ -292,6 +293,11 @@
<artifactId>mysql-connector-java</artifactId> <artifactId>mysql-connector-java</artifactId>
<version>${mysql-connector-java.version}</version> <version>${mysql-connector-java.version}</version>
</dependency> </dependency>
<dependency>
<groupId>com.h2database</groupId>
<artifactId>h2</artifactId>
<version>${h2database.version}</version>
</dependency>
<dependency> <dependency>
<groupId>com.oracle.database.jdbc</groupId> <groupId>com.oracle.database.jdbc</groupId>
<artifactId>ojdbc8</artifactId> <artifactId>ojdbc8</artifactId>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment