- Refer to the table below to determine the appropriate version of
mybatis-r2dbcfor your project.
Exclude the
vprefix when using the version number.
| Compiled JDK | 8 | 17 |
|---|---|---|
| r2dbc-spi | 0.9.1.RELEASE |
1.0.0.RELEASE |
| mybatis-r2dbc | ||
| mybatis-r2dbc-generator | ||
| mybatis-r2dbc-spring | ||
| Spring Boot | [2.7.x,3.0.0) |
[3.0.0,~) |
- The whole project
reactive-mybatis-support(2.x.x)is compiled withJDK8andSpringBoot(2.7.x), akar2dbc-spi(0.9.1.RELEASE) - The
mybatis-r2dbc(3.0.x)andmybatis-r2dbc-generator(3.0.x)are compiled withJDK11, akar2dbc-spi(1.0.0.RELEASE). - Since
3.1.0themybatis-r2dbcandmybatis-r2dbc-generatorandmybatis-r2dbc-springare compiled withJDK17, andSpringBoot(3.x.x),akar2dbc-spi(1.0.0.RELEASE).
- Reactive Mybatis Support is aimed to adapt original mybatis to reactive project (aka WebFlux/Reactor3) with r2dbc drivers.
mybatis-r2dbcmodule is inspired by linux-china/mybatis-r2dbc and based onmybatis3's original source code.mybatis-generatormodule is used to generatemybatis-dynamic-sqlcode with reactive types.- Most of the MyBatis3 features are applicable, but there are a few features that are not supported:
- ❌ 1 . mybatis-plugin
- ❌ 2 . multi ResultSets or Results
- ❌ 3 . nested query with multi SQL statements
- ❌️ 4 . blocking java type (aka: InputStream .eg)
- For more usage instructions, please refer to the wiki: WIKI
- dependency
<dependencies>
<dependency>
<groupId>pro.chenggang</groupId>
<artifactId>mybatis-r2dbc</artifactId>
<version>${compatible-version}</version>
</dependency>
<dependency>
<groupId>pro.chenggang</groupId>
<artifactId>mybatis-r2dbc-generator</artifactId>
<version>${compatible-version}</version>
</dependency>
<dependency>
<groupId>pro.chenggang</groupId>
<artifactId>mybatis-r2dbc-spring</artifactId>
<version>${compatible-version}</version>
</dependency>
</dependencies>