Skip to content

Simplifies the development of creating a MyBatis-based data access layer.

License

Notifications You must be signed in to change notification settings

easybest/spring-data-mybatis

Repository files navigation


The primary goal of the Spring Data project is to make it easier to build Spring-powered applications that use data access technologies.

This module deals with enhanced support for MyBatis based data access layers. This module does not make any modifications to MyBatis. Non-invasive enhancement of MyBatis functionality by using the pre-compiled MyBatis Mapper Statement mode take developers more flexibility. At the same time, you can use the Spring Data pattern to reduce the amount of code and improve development efficiency.

To put it bluntly, it is to help you automatically generate the Mapper files in advance, all the SQLs are ready, and then, the essence is still MyBatis. Developers who use MyBatis no longer need to envy Spring Data JPA and the like ^_^

Useful Links

Features

  • Do not invade MyBatis, completely native use
  • Use standard Java Persistence API (JPA) annotations
  • Supports full CRUD operations on Entities, as well as more complex queries
  • Support to generate corresponding query by method name in interface (Spring Data)
  • Support associated queries, support automatic identification of associated query conditions
  • Entity base class that provides basic properties
  • Support transparent auditing (such as creation time, last modification)
  • Self-sustained custom writing of MyBatis-based queries, convenient and flexible
  • Easy integration with Spring and Spring Boot
  • Support MySQL, Oracle, SQL Server, H2, PostgreSQL, DB2, Derby, HSQL, Phoenix, MariaDB, Sqlite, Informix, HerdDB, Impala, Clickhouse, CUBRID, EnterpriseDB, Firebird, HANA, Ingres, PolarDB, DM, OSCAR, HighGO, XUGU, Kingbase etc.

Quick Start

Installation

Maven

<dependency>
    <groupId>io.easybest</groupId>
    <artifactId>spring-data-mybatis</artifactId>
    <version>2.1.0</version>
</dependency>

In Spring Boot, use the following starter directly:

<dependency>
    <groupId>io.easybest</groupId>
    <artifactId>spring-data-mybatis-starter</artifactId>
    <version>2.1.0</version>
</dependency>

Gradle

implementation('io.easybest:spring-data-mybatis:2.1.0')

In Spring Boot, use the following starter directly:

implementation('io.easybest:spring-data-mybatis-starter:2.1.0')

Contributing

Here are some ways for you to get involved in the community:

  • GitHub is for social coding: if you want to write code, we encourage contributions through pull requests from forks of this repository.

Getting Help

Here is a reference documentation to help you learn Spring Data Mybatis quickly.

If you have any questions or suggestions, you can record an issue.

In addition, you can also add a QQ group to conduct related discussions and seek some help.

QQ Group 1: 497907039

Donation

paypal