MySQL 数据库适配
James 配置修改
James
中涉及数据库配置的配置文件 conf/james-database.properties
调整配置后需 将 MySQL 对应的驱动包放入 lib
文件夹 中,否则启动会报驱动找不到的错
properties
database.driverClassName=com.mysql.cj.jdbc.Driver
database.url=jdbc:mysql://localhost:3306/james?serverTimezone=GMT%2B8&nullCatalogMeansCurrent=true&useUnicode=true&characterEncoding=utf-8&rewriteBatchedStatements=true&useCompression=true&useSSL=false&allowPublicKeyRetrieval=true
database.username=root
database.password=111111
vendorAdapter.database=MYSQL
webmail 配置修改
配置文件所在位置 risenet-y9boot-webapp-webmail/src/main/resources/application.yml
yaml
spring:
datasource:
druid:
y9-public:
driver-class-name: com.mysql.cj.jdbc.Driver
url: jdbc:mysql://localhost:3306/y9_public?serverTimezone=GMT%2B8&nullCatalogMeansCurrent=true&useUnicode=true&characterEncoding=utf-8&rewriteBatchedStatements=true&useCompression=true&useSSL=false&allowPublicKeyRetrieval=true
username: root
password: 111111
webmail:
# 连接 james 的库,用于邮箱的管理
driver-class-name: com.mysql.cj.jdbc.Driver
url: jdbc:mysql://localhost:3306/james?serverTimezone=GMT%2B8&nullCatalogMeansCurrent=true&useUnicode=true&characterEncoding=utf-8&rewriteBatchedStatements=true&useCompression=true&useSSL=false&allowPublicKeyRetrieval=true
username: root
password: 111111
jpa:
#修改为 MySQL 版本对应的方言
database-platform: org.hibernate.dialect.MySQL8Dialect
properties:
hibernate:
#修改为 MySQL 版本对应的方言
dialect: org.hibernate.dialect.MySQL8Dialect