MyBatis-Plus Documentation Hub

repository·master·Indexed 20 days ago

https://github.com/baomidou/mybatis-plus-doc

Official documentation hub for MyBatis-Plus, a Java framework for simplifying database development. This repository includes the documentation source, an AI-powered translation plugin for multi-language support (supporting providers like DeepSeek, OpenAI, Claude, and Gemini), and configuration for Astro/Starlight content collections.

Tokens
183.2K
Snippets
509
Records
699
Agent score
72%

What's inside mybatis-plus-doc

  1. Overview of the Snowy SpringBoot Low-Code Platform

    master

    Snowy is an enterprise-grade, open-source low-code application development platform designed for SpringBoot. It is the first in China to implement a decoupled front-end and back-end architecture with integrated national cryptographic (Guomi) encryption support.

    Core Tech Stack:

    • Frontend: Vue3, AntDesignVue3, Vite
    • Backend: SpringBoot2, MyBatis-Plus (Mp), Hutool, SaToken
    • Cache: Redis
    • Database Support: MySQL, Oracle, SQLServer, PostgreSQL, Dameng, and Kingbase.

    It is designed for compatibility with domestic Chinese hardware, middleware, and operating systems (Windows, Linux, and domestic OS).

  2. Overview of PIG Microservices Development Platform

    master

    PIG Microservices Development Platform is a SpringCloud-based, enterprise-level open-source low-code application development platform. It is designed for microservices development management and supports SaaS model applications using cloud-native technologies like containers and DevOps.

    Key features include:

    • Microservices Framework: A set of application frameworks based on Spring Cloud for efficient development.
    • Reusable Components: Out-of-the-box modules for common enterprise needs (e.g., payment, messaging, connectivity) and business scenarios (e.g., SRM, HRM, Project Management, E-commerce).
    • Enterprise-Grade Stack: Uses mainstream Java microservices technology, making it easier to find technical talent and integrate with existing middle platforms.
    • Extensibility: Provides source code for commonly used modules, allowing for flexible configuration and extension.
  3. Overview of PIG Microservices Platform

    master

    PIG is a cloud-native microservices digital integration platform designed for rapid business system development. It utilizes Spring Cloud and supports SaaS modes.

    Key Features

    • Enterprise-grade Tech Stack: Built on mainstream Java microservices technologies, ensuring high maturity and a large talent pool for maintenance.
    • Reusable Business Components: Provides ready-to-use components for common business scenarios such as Payment, Messaging, and Connection services.
    • Industry Experience: Proven implementation in sectors including Retail, Automotive, Steel, E-commerce, and Real Estate.
    • Product Deliverables:
      • Source Code: Includes common out-of-the-box modules with high configurability and extensibility.
      • Framework: A Spring Cloud-based microservices application framework for efficient development.
      • Enhanced Support: Offers more robust functionality and service support compared to standard open-source versions.
  4. Overview of Batch Operations

    master

    Batch operations in MyBatis-Plus allow for efficient processing of large datasets by executing multiple database operations (Insert, Update, Delete) in a single interaction, reducing overhead and improving performance.

    Key Specifications

    • Supported Version: 3.5.4 +
    • Transaction Control: Manual management required (disabled by default).
    • Execution Result: Returns a List<BatchResult> representing grouped results of the MappedStatement + SQL operations.
    • Exception Type: Throws PersistenceException on failure.
    • Compatibility: Supports both Spring and non-Spring projects.
  5. Overview of MyBatis-Mate features

    master

    MyBatis-Mate is an enterprise-grade low-code solution for data processing designed to handle data more agilely and elegantly. It provides several advanced features for MyBatis-Plus users:

    • Data Auditing (Reconciliation): Quickly compare property differences between two objects.
    • Sensitive Word Filtering: Automatically filters sensitive words using a controllable sensitive word library.
    • Data Scoping: Implements data permission functions quickly via annotations.
    • Automatic Table Structure Maintenance: Automatically manages table structures to prevent missing SQL executions during deployment.
    • Field Data Binding: Conveniently maps data to objects, eliminating the need for manual glue code.
    • Field Encryption/Decryption: Provides quick encryption and decryption for private information.
    • Field Masking: Helps protect user privacy through data masking.
    • Multi-Data Source Support: Handles sharding, dynamic loading, and multi-data source transactions.
  6. Overview of MyBatis-Plus Features

    master

    MyBatis-Plus is an enhancement tool for MyBatis designed to simplify development and improve efficiency without changing the core MyBatis behavior. Key features include:

    • Non-intrusive: Enhances existing projects without causing side effects.
    • Low Overhead: Automatically injects basic CRUD operations with minimal performance impact.
    • Powerful CRUD: Provides built-in Generic Mapper and Generic Service for single-table operations via minimal configuration.
    • Lambda Support: Allows writing query conditions using Lambda expressions to prevent field name errors.
    • Automatic Primary Key Generation: Supports 4 different strategies, including a distributed unique ID generator (Sequence).
    • ActiveRecord Pattern: Enables CRUD operations directly on entity classes by inheriting from the Model class.
    • Custom Global Operations: Supports injecting global common methods (Write once, use anywhere).
    • Code Generator: Includes a built-in generator (via code or Maven plugin) for Mapper, Model, Service, and Controller layers with template engine support.
    • Pagination Plugin: Provides physical pagination based on MyBatis; once configured, pagination is handled automatically during standard List queries.
    • Performance Analysis Plugin: Outputs SQL statements and execution times (recommended for development/testing to identify slow queries).
    • Global Interceptor Plugin: Provides intelligent analysis and blocking for full-table delete or update operations to prevent accidental data loss.
  7. Overview of the Guns development framework

    master

    Guns is a modern Java application development framework built on Spring Boot 2. It is designed as a plugin-based integrated development platform that supports both monolithic and microservices architectures. Its core strength lies in its plugin-based architecture, which allows developers to combine fine-grained module dependencies, enabling the flexible integration or exclusion of specific functionalities.

    Key enterprise features include:

    • Microservices
    • SSO unified authentication
    • SaaS multi-tenancy
    • Workflow engine
    • Reporting
    • Payment systems
    • Code encryption and obfuscation
  8. Overview of the Guns Java Application Development Framework

    master

    Guns is a modern Java application development framework built on Spring Boot 2. It supports both monolithic and microservices architectures. The framework is designed with a plugin-based architecture, allowing developers to freely combine or remove fine-grained module dependencies.

    Key features available in the Enterprise version include:

    • Microservices
    • SSO Unified Authentication
    • SaaS Multi-tenancy
    • Workflow engines
    • Reporting
    • Payment integration
    • Code encryption and obfuscation

    Guns is suitable for developing various information management systems such as OA systems, project management, e-commerce, supply chain, CRM, and mobile app/mini-program backends.

  9. Use MyBatisX Core Features

    master

    MyBatisX provides several key productivity features:

    • XML Mapping Navigation: Quickly switch between Java Mapper interfaces and their corresponding XML mapping files.
    • Code Generation: Automatically generate Java entity classes, Mapper interfaces, and XML mapping files based on your database schema.
    • Template Management: Customize or reset code generation templates to fit your project's specific needs.
    • JPA-Style Hints: Provides automatic code generation for common CRUD operations (Insert, Select, Update, Delete) directly within your code via context menu hints.
  10. Explore the MyBatis-Plus Enterprise Ecosystem

    master

    The MyBatis-Plus ecosystem includes several enterprise-grade tools and platforms designed for advanced development needs, such as low-code development, microservices, and rapid application scaffolding. Key resources include:

    • Mybatis-Mate: An enterprise-level module for MyBatis-Plus that supports advanced features like sharding (database/table splitting), data auditing, field encryption, data binding, data permissions, and automatic SQL maintenance for table structures.
    • AiZuDa: A component-based low-code development platform.
    • Guns: A modern Java application development framework featuring a pluggable architecture for fine-grained module dependency management.
    • PIG: A microservices-based digital integration platform designed for rapid development of business systems and enterprise service middle-ends.
    • frsimple: An agile development scaffold providing enterprise-level mid-and-back-office solutions.
    • Snowy: A rapid development platform focused on front-back separation and support for national cryptographic standards (Guomi), including support for domestic hardware, middleware, and databases.
  11. Explore the Baomidou Open Source Ecosystem

    master

    The Baomidou open source team maintains several specialized tools and components for development, ranging from IDE plugins to distributed task scheduling and security components. You can explore these projects to enhance your MyBatis-Plus or SpringBoot-based development workflows.

    IDE Plugins & Enterprise Modules

    • MybatisX: A free IntelliJ IDEA plugin providing navigation, SQL auto-completion, and code generation.
    • Mybatis-Mate: An enterprise-level module for MyBatis-Plus supporting sharding, data auditing, field encryption, and automatic SQL maintenance.

    Infrastructure & Middleware

    • SnailJob: A distributed task retry and scheduling platform.
    • Dynamic-Datasource: A SpringBoot multi-datasource component with Seata distributed transaction support.
    • Lock4j: A SpringBoot distributed lock component supporting RedisTemplate, Redission, and Zookeeper.
    • FlowLong: A workflow engine designed for approval processes.

    Security & UI

    • Shuan: A WEB security component based on Pac4J-JWT.
    • Kisso: A single sign-on (SSO) component based on Cookie.
    • Kaptcha: A simple SpringBoot captcha component.
    • AiZuDa: A component library for low-code development platforms.