mirror of https://github.com/halo-dev/halo
Replace R2DBC MySQL driver to io.asyncer:r2dbc-mysql (#3918)
#### What type of PR is this? /kind improvement /area core #### What this PR does / why we need it: Replace R2DBC MySQL driver to io.asyncer:r2dbc-mysql. See https://github.com/halo-dev/halo/issues/3804 for more. Please note that there will be an error like below when starting up Halo on MacOS: ```java 2023-05-09T14:24:45.161+08:00 ERROR 4668 --- [ restartedMain] i.n.r.d.DnsServerAddressStreamProviders : Unable to load io.netty.resolver.dns.macos.MacOSDnsServerAddressStreamProvider, fallback to system defaults. This may result in incorrect DNS resolutions on MacOS. Check whether you have a dependency on 'io.netty:netty-resolver-dns-native-macos'. Use DEBUG level to see the full stack: java.lang.UnsatisfiedLinkError: failed to load the required native library ``` After manual test, I haven't found any problems caused by the error. And this only occurs on MacOS when developing. #### Which issue(s) this PR fixes: Fixes https://github.com/halo-dev/halo/issues/3804 #### Special notes for your reviewer: Steps to test: 1. Start up a MySQL server, e.g.: ```bash docker run -it --rm --name halodb -p 3306:3306 -e MYSQL_ROOT_PASSWORD=openmysql -e MYSQL_DATABASE=halo mysql:8 ``` 3. Start Halo with mysql profile active ```bash make -C console dev ./gradlew bootRun --args="--spring.profiles.active=dev,mysql --halo.plugin.runtime-mode=deployment" ``` 5. Check the functionality of Halo #### Does this PR introduce a user-facing change? ```release-note 替换 R2DBC MySQL 驱动为:io.asyncer:r2dbc-mysql ```pull/4014/head^2
parent
4c2e8410b9
commit
ebcafe6117
|
@ -54,7 +54,7 @@ dependencies {
|
|||
runtimeOnly 'org.postgresql:postgresql'
|
||||
runtimeOnly 'org.postgresql:r2dbc-postgresql'
|
||||
runtimeOnly 'org.mariadb:r2dbc-mariadb'
|
||||
runtimeOnly 'com.github.jasync-sql:jasync-r2dbc-mysql'
|
||||
runtimeOnly 'io.asyncer:r2dbc-mysql'
|
||||
|
||||
testImplementation 'org.springframework.boot:spring-boot-starter-test'
|
||||
testImplementation 'org.springframework.security:spring-security-test'
|
||||
|
|
|
@ -1 +1,2 @@
|
|||
version=2.6.0-SNAPSHOT
|
||||
r2dbc-mysql.version=1.0.2
|
||||
|
|
|
@ -50,11 +50,7 @@ dependencies {
|
|||
api "com.github.java-json-tools:json-patch:$jsonPatch"
|
||||
api "org.thymeleaf.extras:thymeleaf-extras-springsecurity6"
|
||||
|
||||
runtime 'io.r2dbc:r2dbc-h2'
|
||||
runtime 'org.postgresql:postgresql'
|
||||
runtime 'org.postgresql:r2dbc-postgresql'
|
||||
runtime 'org.mariadb:r2dbc-mariadb:1.1.4'
|
||||
runtime 'com.github.jasync-sql:jasync-r2dbc-mysql:2.1.23'
|
||||
}
|
||||
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue