Tagged articles
738 articles
Page 4 of 8
macrozheng
macrozheng
Jul 25, 2023 · Backend Development

Dynamic SQL with MyBatis Interceptors in Spring Boot

This tutorial explains how to use MyBatis interceptor mechanisms to dynamically modify SQL statements at runtime in a Spring Boot application, covering interceptor types, implementation steps, configuration, core code, testing, and common use cases such as SQL monitoring, pagination, and data permission filtering.

Dynamic SQLInterceptorMyBatis
0 likes · 11 min read
Dynamic SQL with MyBatis Interceptors in Spring Boot
Selected Java Interview Questions
Selected Java Interview Questions
Jul 24, 2023 · Backend Development

Analyzing and Reproducing OutOfMemoryError Caused by MyBatis and DruidDataSource in a Java Backend Service

This article investigates the root causes of frequent OutOfMemoryError incidents in a distributed Java backend, explains how MyBatis and DruidDataSource can exhaust heap and metaspace, demonstrates a reproducible test with JVM options and multithreading, and offers practical mitigation strategies.

DockerMemoryLeakMyBatis
0 likes · 7 min read
Analyzing and Reproducing OutOfMemoryError Caused by MyBatis and DruidDataSource in a Java Backend Service
JavaEdge
JavaEdge
Jul 14, 2023 · Databases

How to Efficiently Insert 1,000 Records with MyBatis: Loop vs Batch

When interviewers ask how to insert a thousand rows with MyBatis, the answer isn’t just a simple Java for‑loop; you need to consider batch processing, disable autocommit, and understand MyBatis’s limits to choose the most reliable and performant approach.

Batch InsertMyBatisdatabase
0 likes · 3 min read
How to Efficiently Insert 1,000 Records with MyBatis: Loop vs Batch
Su San Talks Tech
Su San Talks Tech
Jul 14, 2023 · Backend Development

How to Use MyBatis Interceptor for Dynamic SQL in Spring Boot 3

This article demonstrates how to leverage MyBatis interceptor mechanism in a Spring Boot 3 application to dynamically modify SQL statements, showing step‑by‑step implementation, configuration, core code, testing, and common use cases such as SQL monitoring, pagination, and data permission filtering.

Dynamic SQLInterceptorMyBatis
0 likes · 11 min read
How to Use MyBatis Interceptor for Dynamic SQL in Spring Boot 3
Laravel Tech Community
Laravel Tech Community
Jul 13, 2023 · Databases

MyBatis-Flex: An Elegant MyBatis Enhancement Framework

MyBatis-Flex is a lightweight, high‑performance extension to MyBatis that adds full CRUD, pagination, multi‑table and batch operations while preserving all MyBatis features, supports multi‑datasource relations, recursive queries, and provides extensive annotations such as @Relation for flexible data mapping, with recent v1.4.9 updates and bug fixes.

FrameworkMyBatisORM
0 likes · 5 min read
MyBatis-Flex: An Elegant MyBatis Enhancement Framework
Programmer DD
Programmer DD
Jul 4, 2023 · Backend Development

Unlock MyBatis Performance: Mastering First and Second Level Caches

This article explains how MyBatis first‑level (session) and second‑level (cross‑session) caches work, the conditions required for them to function, common pitfalls when integrating with SpringBoot, and step‑by‑step instructions to enable and safely use second‑level caching in real projects.

CacheFirst-Level CacheMyBatis
0 likes · 11 min read
Unlock MyBatis Performance: Mastering First and Second Level Caches
ITPUB
ITPUB
Jun 23, 2023 · Databases

Seamless Sharding Migration: Dual‑Write, Mapping Keys, and Diff Validation

This article explains how to smoothly migrate a legacy single‑database system to a sharded architecture by using dual‑write, mapping‑key routing, custom transaction handling, and offline/real‑time diff checks, while detailing the underlying MyBatis integration and component‑based design.

MyBatisdatabase partitioningdiff-validation
0 likes · 36 min read
Seamless Sharding Migration: Dual‑Write, Mapping Keys, and Diff Validation
Selected Java Interview Questions
Selected Java Interview Questions
Jun 14, 2023 · Backend Development

Understanding MyBatis First‑Level and Second‑Level Cache and Their Integration with Spring Boot

The article explains MyBatis first‑level and second‑level caching mechanisms, their activation conditions, integration pitfalls with Spring Boot, and how to enable and use them safely, including configuration steps, code examples, and warnings about hidden risks of second‑level cache.

First-Level CacheMyBatisSecond-Level Cache
0 likes · 12 min read
Understanding MyBatis First‑Level and Second‑Level Cache and Their Integration with Spring Boot
Java Architect Essentials
Java Architect Essentials
Jun 11, 2023 · Backend Development

Using MyBatis Dynamic SQL: if, choose, trim, foreach, and bind Tags

This article provides a comprehensive guide to MyBatis dynamic SQL, demonstrating how to use if, choose, trim, foreach, and bind tags for conditional queries, updates, inserts, batch operations, and database‑agnostic expressions, complete with Maven project setup, SQL scripts, and test cases.

BackendDynamic SQLMyBatis
0 likes · 15 min read
Using MyBatis Dynamic SQL: if, choose, trim, foreach, and bind Tags
Sohu Tech Products
Sohu Tech Products
Jun 7, 2023 · Backend Development

MyBatis Streaming Query (Cursor) Tutorial and Best Practices

This article introduces MyBatis streaming query using the Cursor interface, explains its core methods, demonstrates implementation with code examples, discusses suitable application scenarios, and outlines important considerations for efficient and safe large‑scale data processing in Java backend development.

BackendCursorMyBatis
0 likes · 11 min read
MyBatis Streaming Query (Cursor) Tutorial and Best Practices
Top Architect
Top Architect
Jun 5, 2023 · Backend Development

MyBatis Streaming Query: Concepts, Cursor API, Implementation, and Use Cases

This article introduces MyBatis streaming queries, explains the Cursor interface and its methods, provides step‑by‑step code examples for configuration and implementation, discusses practical application scenarios such as large‑scale data processing, and highlights important considerations for efficient and safe usage.

CursorMyBatisStreaming Query
0 likes · 11 min read
MyBatis Streaming Query: Concepts, Cursor API, Implementation, and Use Cases
Qunar Tech Salon
Qunar Tech Salon
May 30, 2023 · Databases

Smooth Migration to Sharding: Design, Implementation, and Componentization of Qunar's Database Sharding Solution

This article describes the challenges of migrating a long‑running monolithic database to a sharded architecture, presents a two‑stage smooth migration strategy using double‑write, diff verification, and mapping‑key techniques, and details the componentized design, core implementation, and configuration of a reusable sharding framework built on MyBatis and Spring.

MyBatisSoftware Architecturedata synchronization
0 likes · 34 min read
Smooth Migration to Sharding: Design, Implementation, and Componentization of Qunar's Database Sharding Solution
Java Interview Crash Guide
Java Interview Crash Guide
May 24, 2023 · Backend Development

Why Lombok’s Getter/Setter Breaks MyBatis and EasyExcel: Hidden Pitfalls Explained

This article explores how Lombok’s auto‑generated getter/setter methods can conflict with MyBatis property naming conventions and cause null values, examines the underlying reflection logic in MyBatis, and also reveals why the @Accessor(chain=true) annotation disrupts EasyExcel’s CGLIB‑based mapping, offering practical solutions.

GetterSetterLombokMyBatis
0 likes · 7 min read
Why Lombok’s Getter/Setter Breaks MyBatis and EasyExcel: Hidden Pitfalls Explained
Selected Java Interview Questions
Selected Java Interview Questions
May 4, 2023 · Backend Development

Understanding Spring Boot Starters with MyBatis: mybatis‑spring vs mybatis‑spring‑boot‑starter

This article explains the concept and purpose of Spring Boot starters, compares mybatis‑spring with mybatis‑spring‑boot‑starter through code examples, and details how the starter simplifies MyBatis integration by handling dependencies, configuration files, auto‑configuration, and mapper scanning for Java backend projects.

MyBatisSpring BootStarter
0 likes · 7 min read
Understanding Spring Boot Starters with MyBatis: mybatis‑spring vs mybatis‑spring‑boot‑starter
Top Architect
Top Architect
Mar 31, 2023 · Backend Development

Why MyBatis PageHelper Pagination Is Slow and How to Optimize It

The article explains that MyBatis PageHelper performs an extra full‑table count query causing pagination to take over eight seconds on a 10,000‑row table, analyzes the root cause, and provides a concrete solution by customizing the count SQL with a _COUNT method and optimized mapper definitions.

MyBatisSQL Optimizationbackend-development
0 likes · 6 min read
Why MyBatis PageHelper Pagination Is Slow and How to Optimize It
Top Architect
Top Architect
Mar 27, 2023 · Backend Development

Three MyBatis Batch Insert Methods and Their Performance Comparison

The article explains three ways to perform batch inserts with MyBatis—ordinary single-row inserts, foreach‑based bulk inserts, and ExecutorType.BATCH—analyzes their SQL logs, performance bottlenecks, MySQL limits, and provides practical recommendations for large‑scale data insertion.

Batch InsertExecutorTypeMyBatis
0 likes · 13 min read
Three MyBatis Batch Insert Methods and Their Performance Comparison
macrozheng
macrozheng
Mar 20, 2023 · Backend Development

Boost MyBatis Batch Insert Speed: Avoid foreach Pitfalls and Use ExecutorType.BATCH

This article explains why MyBatis foreach‑based batch inserts become extremely slow with thousands of rows, demonstrates how the generated giant SQL statement hurts performance, and shows how switching to ExecutorType.BATCH or limiting rows per INSERT dramatically reduces insertion time.

Batch InsertExecutorType.BATCHMyBatis
0 likes · 9 min read
Boost MyBatis Batch Insert Speed: Avoid foreach Pitfalls and Use ExecutorType.BATCH
Architect
Architect
Mar 17, 2023 · Backend Development

Million‑Scale Data Export with JPA and MyBatis in Spring Boot

This article explains how to export tens of millions of rows from MySQL using Spring Boot by streaming data with JPA or MyBatis, avoiding OutOfMemoryError, switching to CSV format, and provides complete code examples, performance comparison, and tips for generating test data.

CSVDataExportMyBatis
0 likes · 12 min read
Million‑Scale Data Export with JPA and MyBatis in Spring Boot
Code Ape Tech Column
Code Ape Tech Column
Mar 17, 2023 · Backend Development

Using MybatisX Plugin with Spring Boot for Rapid MyBatis Development

This guide demonstrates how to integrate the MybatisX IDEA plugin with a Spring Boot project, covering database setup, Maven dependency configuration, plugin installation, connection testing, code generation, and sample controller implementation to accelerate MyBatis and MyBatis-Plus development.

IDEA PluginMyBatisSpring Boot
0 likes · 5 min read
Using MybatisX Plugin with Spring Boot for Rapid MyBatis Development
Programmer DD
Programmer DD
Mar 15, 2023 · Information Security

How to Prevent XSS and SQL Injection in SpringBoot: Filters and Code Examples

This article explains XSS attack types, SQL injection risks, and provides practical SpringBoot filter implementations with MyBatis prepared statements and custom deserializers to sanitize request parameters, JSON bodies, and prevent malicious script and database attacks.

MyBatisRequest SanitizationSQL injection
0 likes · 13 min read
How to Prevent XSS and SQL Injection in SpringBoot: Filters and Code Examples
Java Architect Essentials
Java Architect Essentials
Mar 3, 2023 · Backend Development

Master FastMyBatis: Quick Spring Boot Integration and CRUD Guide

This article introduces FastMyBatis—a lightweight, zero‑configuration MyBatis extension for Spring Boot—covering its core principles, Maven setup, sample CRUD controller, service and mapper implementations, a comprehensive list of mapper methods, Query object usage examples, and links to the open‑source repository.

CRUDFastMyBatisMyBatis
0 likes · 10 min read
Master FastMyBatis: Quick Spring Boot Integration and CRUD Guide
Programmer DD
Programmer DD
Mar 1, 2023 · Backend Development

Unlock MyBatis: 10 Essential Design Patterns Powering Its Architecture

This article examines how MyBatis leverages around ten core design patterns—including Factory, Singleton, Builder, Adapter, Proxy, Composite, Decorator, Template, Strategy, and Iterator—to decouple complex scenarios, improve modularity, and streamline ORM operations within its extensive codebase.

Design PatternsMyBatisORM
0 likes · 10 min read
Unlock MyBatis: 10 Essential Design Patterns Powering Its Architecture
Java Architect Essentials
Java Architect Essentials
Jan 10, 2023 · Backend Development

MyBatis and MyBatis-Plus Batch Insert Techniques with Performance Comparison

This article presents five common batch‑insert approaches for MyBatis and MyBatis‑Plus—including a for‑loop, manual batch commit, collection‑based batch, saveBatch, and InsertBatchSomeColumn—provides complete code examples, configuration steps, and measured execution times to help Java backend developers choose the most efficient method.

Batch InsertMyBatisSpring Boot
0 likes · 11 min read
MyBatis and MyBatis-Plus Batch Insert Techniques with Performance Comparison
Top Architect
Top Architect
Jan 9, 2023 · Backend Development

Using MyBatis Dynamic SQL Tags: foreach, if, choose, trim, selectKey and More

This article provides a comprehensive guide to MyBatis dynamic SQL tags—including foreach, if, choose, trim, selectKey, and related constructs—explaining their attributes, usage scenarios, and offering detailed Java and XML code examples for building flexible and error‑free database queries.

Dynamic SQLMyBatisjava
0 likes · 16 min read
Using MyBatis Dynamic SQL Tags: foreach, if, choose, trim, selectKey and More
Top Architect
Top Architect
Dec 12, 2022 · Backend Development

MyBatis Introduction, Setup Steps, and Dynamic Proxy Implementation

This article provides a comprehensive guide to MyBatis, covering its basic concepts, Maven dependency configuration, XML setup, entity and mapper definitions, execution flow using dynamic proxies, and a custom lightweight framework implementation with full Java code examples.

Dynamic ProxyMyBatisORM
0 likes · 12 min read
MyBatis Introduction, Setup Steps, and Dynamic Proxy Implementation
Architect's Tech Stack
Architect's Tech Stack
Dec 8, 2022 · Backend Development

Implementing Streaming Reads with MyBatis for Large-Scale Java Report Export

This article explains how to overcome export failures caused by large data volumes in a legacy Java system by switching from default full-result JDBC reads to a forward‑only streaming approach using MyBatis, detailing environment setup, configuration changes, and complete code examples for controller, service, DAO, and mapper layers.

JDBCMyBatisStreaming
0 likes · 5 min read
Implementing Streaming Reads with MyBatis for Large-Scale Java Report Export
Top Architect
Top Architect
Dec 8, 2022 · Backend Development

Common MyBatis Batch Insert Techniques and Performance Comparison

This article presents a detailed overview of five commonly used MyBatis and MyBatis-Plus batch insertion methods, including code examples, configuration steps, and performance measurements for inserting ten thousand records, helping developers choose the most efficient approach for large‑scale data insertion in Java backend projects.

Batch InsertMyBatisSpring Boot
0 likes · 11 min read
Common MyBatis Batch Insert Techniques and Performance Comparison
Top Architect
Top Architect
Dec 5, 2022 · Backend Development

Integrating Spring Batch with Spring Boot: Full Tutorial and Example

This article provides a comprehensive step‑by‑step guide on integrating Spring Batch with Spring Boot, covering configuration, entity and mapper definitions, job, step, reader, processor, writer implementations, database setup, error handling, and execution via a REST controller, complete with code examples.

Batch ProcessingMyBatisSpring Batch
0 likes · 22 min read
Integrating Spring Batch with Spring Boot: Full Tutorial and Example
Architect's Tech Stack
Architect's Tech Stack
Dec 4, 2022 · Backend Development

Unified Exception Handling in Spring Boot Using @ControllerAdvice, Assert, and Enum‑Based Business Errors

This article explains how to replace repetitive try‑catch blocks in Java Spring applications with a unified exception handling strategy that leverages @ControllerAdvice, custom Assert utilities, enum‑based error codes, and standardized response objects to improve code readability, maintainability, and internationalisation.

AssertMyBatisenum
0 likes · 21 min read
Unified Exception Handling in Spring Boot Using @ControllerAdvice, Assert, and Enum‑Based Business Errors
Selected Java Interview Questions
Selected Java Interview Questions
Dec 1, 2022 · Backend Development

Five Common Batch Insert Techniques for MyBatis and MyBatis‑Plus

This article presents and compares five practical batch‑insert methods for MyBatis and MyBatis‑Plus, covering preparation steps, code implementations, configuration details, and performance results, helping developers choose the most efficient approach for inserting large volumes of data in Java backend projects.

Batch InsertMyBatisSpring Boot
0 likes · 9 min read
Five Common Batch Insert Techniques for MyBatis and MyBatis‑Plus
Java Captain
Java Captain
Nov 23, 2022 · Backend Development

Free Comprehensive Collection of Big‑Tech Interview Questions and Answers (Java, Spring, Redis, MyBatis, etc.)

This post shares a free, extensive compilation of interview questions and detailed explanations covering Java fundamentals, multithreading, Spring framework, Redis, MyBatis and other backend technologies, encouraging systematic preparation and offering a QR‑code method to obtain the full document.

MyBatisbackend-developmentinterview-questions
0 likes · 8 min read
Free Comprehensive Collection of Big‑Tech Interview Questions and Answers (Java, Spring, Redis, MyBatis, etc.)
Architecture Digest
Architecture Digest
Nov 16, 2022 · Backend Development

Comprehensive Collection of Interview Questions and Answers for Major Tech Companies (Java, Spring, Redis, MyBatis, etc.)

This article compiles over a thousand interview questions and detailed explanations covering core Java fundamentals, multithreading, Spring framework, Redis, MyBatis, and related backend technologies, offering a free downloadable resource to help candidates prepare effectively for major tech company interviews.

MyBatisinterview-questionsjava
0 likes · 8 min read
Comprehensive Collection of Interview Questions and Answers for Major Tech Companies (Java, Spring, Redis, MyBatis, etc.)
dbaplus Community
dbaplus Community
Nov 2, 2022 · Backend Development

How We Cut DB QPS by 80% with a Custom DAO Cache Layer

This article explains how a high‑traffic e‑commerce system reduced database QPS by over 80% and response latency by more than 40% through a systematic DAO‑level caching solution, detailing the background, design trade‑offs, implementation steps, global cache architecture, deployment practices, and observed limitations.

MyBatisjavaperformance
0 likes · 28 min read
How We Cut DB QPS by 80% with a Custom DAO Cache Layer
Top Architect
Top Architect
Nov 1, 2022 · Backend Development

Deep Dive into MyBatis SQL Execution Process and Custom TypeHandler

This article thoroughly explains how MyBatis binds mapper interfaces to XML files, details the step‑by‑step SQL execution flow—including mapper retrieval, statement preparation, parameter handling, and result mapping—and demonstrates how to create custom typeHandlers for both input parameters and result sets.

MyBatisPersistenceTypeHandler
0 likes · 16 min read
Deep Dive into MyBatis SQL Execution Process and Custom TypeHandler
Java High-Performance Architecture
Java High-Performance Architecture
Nov 1, 2022 · Backend Development

How MyBatis Binds Mappers, Executes SQL, and Uses Custom TypeHandlers

This article dissects MyBatis’s internal workflow, explaining how mapper interfaces are linked to XML files, detailing the step‑by‑step SQL execution process, and demonstrating how to create and apply custom typeHandlers for parameter setting and result mapping, all based on MyBatis 3.5.5 source code.

Custom TypeHandlerMyBatisSQL Execution
0 likes · 20 min read
How MyBatis Binds Mappers, Executes SQL, and Uses Custom TypeHandlers
Cognitive Technology Team
Cognitive Technology Team
Oct 31, 2022 · Backend Development

Analysis of MyBatis First-Level and Second-Level Caches and Their Configuration

This article explains MyBatis's first-level (SqlSession-scoped) and second-level (Mapper-scoped) caching mechanisms, their default behaviors, key generation, configuration options, and the impact of Spring integration, and provides recommendations for disabling caches in distributed environments to avoid data inconsistency.

CacheMyBatisbackend-development
0 likes · 9 min read
Analysis of MyBatis First-Level and Second-Level Caches and Their Configuration
ITPUB
ITPUB
Oct 31, 2022 · Backend Development

Master MyBatis Caching: First- and Second-Level Cache Explained

This article explains MyBatis caching fundamentals, detailing first- and second-level cache concepts, configuration, cache invalidation scenarios, and custom cache integration with EHCache, supplemented by practical code snippets and quiz questions to illustrate cache behavior across SqlSessions.

CacheEhcacheMyBatis
0 likes · 12 min read
Master MyBatis Caching: First- and Second-Level Cache Explained
Java High-Performance Architecture
Java High-Performance Architecture
Oct 30, 2022 · Backend Development

Boost Your Java Backend: Master MyBatisCodeHelper Pro for Rapid Code Generation

This guide walks you through installing the MyBatisCodeHelper‑Pro IntelliJ plugin, configuring it to generate Java entity, DAO, mapper and service code, customizing type mappings, creating SQL scripts, and using shortcuts to produce find, update, delete, and pagination methods efficiently for backend development.

BackendIntelliJMyBatis
0 likes · 7 min read
Boost Your Java Backend: Master MyBatisCodeHelper Pro for Rapid Code Generation
macrozheng
macrozheng
Oct 30, 2022 · Backend Development

Which Java Technologies Are Obsolete? A 20‑Year Veteran’s Guide

Drawing on two decades of Java experience, this article evaluates outdated Java technologies—JSP, Struts, Hibernate, and others—based on real‑world development relevance, interview usefulness, and depth of understanding, and offers clear recommendations on what to skip and what to master.

HibernateJSPMyBatis
0 likes · 8 min read
Which Java Technologies Are Obsolete? A 20‑Year Veteran’s Guide
macrozheng
macrozheng
Oct 25, 2022 · Backend Development

Master MyBatis in Spring Boot: Essential Tips, Dynamic SQL, and Advanced Queries

This guide walks you through integrating MyBatis with Spring Boot, covering basic CRUD operations, dynamic SQL constructs like if, choose, where, set, foreach, as well as advanced mapping techniques, pagination plugins, and practical code examples to help you master MyBatis in real-world projects.

MyBatisORMSpring Boot
0 likes · 17 min read
Master MyBatis in Spring Boot: Essential Tips, Dynamic SQL, and Advanced Queries
Top Architect
Top Architect
Oct 20, 2022 · Databases

Performance Evaluation of Inserting Billion‑Scale Data into MySQL Using Java: MyBatis vs JDBC vs Batch Processing

This article presents a detailed performance test of inserting massive data into MySQL with Java, comparing three strategies—MyBatis lightweight insertion without transactions, direct JDBC handling with and without transactions, and JDBC batch processing—showing timing results for millions of rows and offering practical recommendations for high‑throughput data loading.

Batch ProcessingDatabase OptimizationJDBC
0 likes · 14 min read
Performance Evaluation of Inserting Billion‑Scale Data into MySQL Using Java: MyBatis vs JDBC vs Batch Processing
Top Architect
Top Architect
Oct 14, 2022 · Backend Development

Spring Annotation Development and MyBatis Integration Guide

This article provides a comprehensive tutorial on using Spring annotations for pure annotation‑based development, defining beans, managing bean scopes, performing various injection techniques, reading configuration properties, and integrating Spring with MyBatis, complete with code examples and best‑practice tips.

MyBatisannotationsbackend-development
0 likes · 10 min read
Spring Annotation Development and MyBatis Integration Guide
Java Architect Essentials
Java Architect Essentials
Oct 10, 2022 · Backend Development

Implementing MyBatis TypeHandler for Field Encryption in Java

This article demonstrates how to securely store and retrieve sensitive fields such as phone numbers in a MySQL database by creating a custom Java Encrypt class, a MyBatis TypeHandler for automatic encryption/decryption, configuring the mapper XML, and verifying the solution with test results.

MyBatisTypeHandlerdatabase
0 likes · 8 min read
Implementing MyBatis TypeHandler for Field Encryption in Java
JD Cloud Developers
JD Cloud Developers
Oct 10, 2022 · Backend Development

How MyBatis Executes Queries and Fixes a Pre‑3.4.5 Bug

This article walks through MyBatis's complete query lifecycle—from configuration parsing, SqlSessionFactory creation, and mapper loading to the actual SELECT execution—while reproducing a pre‑3.4.5 bug caused by foreach variable leakage and presenting the official fix and upgrade recommendations.

BackendMyBatisORM
0 likes · 20 min read
How MyBatis Executes Queries and Fixes a Pre‑3.4.5 Bug
Java Architect Essentials
Java Architect Essentials
Sep 30, 2022 · Backend Development

Comprehensive Guide to Spring Annotation Development and MyBatis Integration

This article provides a step‑by‑step tutorial on using Spring annotations for bean definition, component scanning, scope management, autowiring, qualifier usage, simple value injection, property file loading, and finally demonstrates how to integrate Spring with MyBatis for streamlined data access in Java backend projects.

ConfigurationMyBatisannotations
0 likes · 9 min read
Comprehensive Guide to Spring Annotation Development and MyBatis Integration
Mike Chen's Internet Architecture
Mike Chen's Internet Architecture
Sep 20, 2022 · Backend Development

Understanding MyBatis First-Level and Second-Level Caches: Principles, Implementation, and Differences

This article explains the principles, implementation steps, and configuration of MyBatis first‑level (SqlSession) and second‑level (mapper) caches, compares their scopes and behaviors, and provides practical guidance on when and how to enable each cache to improve database query performance.

BackendCacheFirst-Level Cache
0 likes · 7 min read
Understanding MyBatis First-Level and Second-Level Caches: Principles, Implementation, and Differences
Top Architect
Top Architect
Sep 13, 2022 · Information Security

Implementing Data Masking in MySQL and Java with MyBatis-Mate Sensitive Jackson

This article demonstrates how to mask sensitive data such as phone numbers and ID cards using SQL functions, introduces Java masking libraries, and provides a complete MyBatis-Mate Sensitive Jackson example with configuration, custom strategies, entity annotations, controller endpoints, and sample responses.

MyBatisdata maskingjava
0 likes · 11 min read
Implementing Data Masking in MySQL and Java with MyBatis-Mate Sensitive Jackson
Cognitive Technology Team
Cognitive Technology Team
Sep 8, 2022 · Backend Development

Recommendation: Use Wrapper Types for POJO Fields and Avoid Default Values to Prevent Common Pitfalls

The article advises that POJO class attributes should always use wrapper types without preset default values, illustrating several pitfalls such as null‑overridden defaults during Jackson deserialization, BeanUtils copy failures, MyBatis dynamic SQL issues, and RPC/API default‑value bugs.

MyBatisWrapper Typesbackend-development
0 likes · 7 min read
Recommendation: Use Wrapper Types for POJO Fields and Avoid Default Values to Prevent Common Pitfalls
Senior Brother's Insights
Senior Brother's Insights
Sep 5, 2022 · Backend Development

How a Hidden Ternary Operator Triggered Massive Data Deletion in a Java Backend

After taking over a system via a server image, the author uncovered malicious modifications that used a ternary expression to force id=1, causing MyBatis to generate a “where 1=1” clause that deleted the entire T_QUART_DATA table, and later discovered cron jobs that removed core jars, illustrating a thorough forensic debugging process.

LinuxMyBatisbackend debugging
0 likes · 7 min read
How a Hidden Ternary Operator Triggered Massive Data Deletion in a Java Backend
Su San Talks Tech
Su San Talks Tech
Sep 5, 2022 · Backend Development

Master MyBatis: Core Concepts, Interview Questions, and Practical Tips

This comprehensive guide explains MyBatis fundamentals, compares it with Hibernate, details its lifecycle, configuration, dynamic SQL, caching, lazy loading, batch operations, pagination, and plugin development, providing code examples and best‑practice recommendations for Java backend developers.

MyBatisORMPersistence
0 likes · 38 min read
Master MyBatis: Core Concepts, Interview Questions, and Practical Tips
Programmer DD
Programmer DD
Sep 2, 2022 · Backend Development

Speed Up MyBatis Batch Inserts: Avoid foreach Pitfalls with ExecutorType.BATCH

An in‑depth guide explains why using MyBatis’s foreach for bulk inserts can cause severe performance degradation, especially with large tables, and demonstrates how switching to ExecutorType.BATCH or limiting batch sizes to 20‑50 rows dramatically reduces insertion time from minutes to seconds.

Batch InsertExecutorType.BATCHMyBatis
0 likes · 10 min read
Speed Up MyBatis Batch Inserts: Avoid foreach Pitfalls with ExecutorType.BATCH
Java Captain
Java Captain
Aug 25, 2022 · Databases

Optimizing MyBatis Batch Inserts: Reducing CPU Usage and Improving Performance

The article explains why MyBatis foreach‑based batch inserts can cause extreme CPU usage and long execution times, demonstrates how combining multiple VALUES into a single INSERT or using ExecutorType.BATCH dramatically improves performance, and provides practical code examples and sizing recommendations.

Batch InsertExecutorType.BATCHMyBatis
0 likes · 8 min read
Optimizing MyBatis Batch Inserts: Reducing CPU Usage and Improving Performance
Su San Talks Tech
Su San Talks Tech
Aug 25, 2022 · Backend Development

Mastering Spring Transactions: From Basics to Advanced Propagation Types

This article explains the origins and purpose of Spring transactions, demonstrates how to quickly set them up with code examples, explores key features and common pitfalls, and provides an in‑depth comparison of the REQUIRED, REQUIRES_NEW, and NESTED propagation types for robust backend development.

BackendMyBatisaop
0 likes · 21 min read
Mastering Spring Transactions: From Basics to Advanced Propagation Types
Programmer DD
Programmer DD
Aug 21, 2022 · Backend Development

Why PageHelper Can Break Your MyBatis Queries: Hidden ThreadLocal Pitfalls

This article examines unexpected bugs caused by PageHelper in a Java/MyBatis project—such as duplicate registrations, limited dropdown results, and password‑reset errors—traces them to ThreadLocal misuse, explains the library’s internal pagination flow, and offers practical fixes to avoid these pitfalls.

MyBatisThreadLocaljava
0 likes · 14 min read
Why PageHelper Can Break Your MyBatis Queries: Hidden ThreadLocal Pitfalls
Architecture Digest
Architecture Digest
Aug 21, 2022 · Information Security

Implementing Database Field Encryption and Decryption with MyBatis Plugins

This article explains how to use MyBatis plugins to transparently encrypt specified database fields on write and decrypt them on read, covering the requirement background, system architecture, interceptor design, annotation usage, mapper adjustments, handling of pagination count queries, and practical implementation details.

MyBatisdatabase encryptionjava
0 likes · 17 min read
Implementing Database Field Encryption and Decryption with MyBatis Plugins
vivo Internet Technology
vivo Internet Technology
Aug 17, 2022 · Information Security

Implementing Database Field Encryption with a MyBatis Plugin

The article demonstrates how to implement lightweight field-level encryption in MyBatis by adding encrypted columns, creating a custom interceptor that encrypts annotated parameters on write and decrypts them on read, handling executor, statement, parameter, and result set processing, and addressing pagination count queries.

MyBatisORMdatabase encryption
0 likes · 18 min read
Implementing Database Field Encryption with a MyBatis Plugin
Selected Java Interview Questions
Selected Java Interview Questions
Aug 13, 2022 · Backend Development

Understanding PageHelper Pagination Issues and ThreadLocal Management in MyBatis

This article explains how PageHelper integrates with MyBatis, analyzes common pagination bugs such as unexpected LIMIT clauses, duplicate registrations, and password‑reset errors, and demonstrates the internal ThreadLocal handling, startPage usage, and proper cleanup to avoid thread‑local pollution.

MyBatisThreadLocalpagehelper
0 likes · 12 min read
Understanding PageHelper Pagination Issues and ThreadLocal Management in MyBatis
HomeTech
HomeTech
Aug 4, 2022 · Information Security

Preventing SQL Injection: Principles, Practices, and Safe MyBatis Usage

This article explains the fundamentals of SQL injection attacks, outlines their severe consequences, and provides a comprehensive set of prevention principles and practical measures—including parameterized queries, strong typing, input validation, and secure MyBatis configurations—to help developers safeguard backend applications and databases.

MyBatisPreparedStatementSQL injection
0 likes · 10 min read
Preventing SQL Injection: Principles, Practices, and Safe MyBatis Usage
Architect
Architect
Jul 28, 2022 · Information Security

Implementing Data Masking in MySQL and Java Using MyBatis‑Mate Sensitive Jackson

This article demonstrates how to mask sensitive data such as phone numbers, ID cards, and emails in MySQL and Java applications by combining SQL string functions with the MyBatis‑Mate Sensitive Jackson plugin, providing complete configuration, custom strategies, and runnable Spring Boot examples.

MyBatisSpring Bootdata masking
0 likes · 9 min read
Implementing Data Masking in MySQL and Java Using MyBatis‑Mate Sensitive Jackson
政采云技术
政采云技术
Jul 26, 2022 · Backend Development

Deep Dive into MyBatis: Architecture, Execution Flow, Plugins, Caching, and Spring Integration

This article provides a comprehensive analysis of MyBatis, covering its core architecture, the process of obtaining SqlSessionFactory and SqlSession, the dynamic proxy mechanism for mappers, the execution flow of SQL statements, the plugin system, first‑ and second‑level caching strategies, and how Spring manages MyBatis mappers through factory beans and import registrars.

MyBatisORMPlugins
0 likes · 39 min read
Deep Dive into MyBatis: Architecture, Execution Flow, Plugins, Caching, and Spring Integration
Java High-Performance Architecture
Java High-Performance Architecture
Jul 12, 2022 · Frontend Development

Build a Full-Stack Student Management System with Vue and SpringBoot

This guide walks through setting up a front‑back separated student management system, detailing Vue‑based front‑end deployment, SpringBoot + MyBatis back‑end configuration, database initialization, core features for admin, teacher, and student roles, and provides code snippets and screenshots to illustrate the complete workflow.

MyBatisSpringBootStudent Management
0 likes · 5 min read
Build a Full-Stack Student Management System with Vue and SpringBoot
DeWu Technology
DeWu Technology
Jul 11, 2022 · Databases

SQL Fine-Grained Management and Concurrency Control Best Practices

The guide recommends fine‑grained MySQL management in a MyBatis‑based order system—avoiding generic or dynamic SQL, explicitly using indexes, listing columns, limiting results, batching inserts, and checking row counts—while applying appropriate concurrency control (pessimistic FOR UPDATE or optimistic versioning) to improve performance, stability, and data integrity.

Concurrency ControlDatabase OptimizationMyBatis
0 likes · 18 min read
SQL Fine-Grained Management and Concurrency Control Best Practices
Cognitive Technology Team
Cognitive Technology Team
Jul 5, 2022 · Backend Development

Avoiding Unexpected Comma Formatting of Large Integers with MessageFormat in MyBatis SQL Generation

When using MessageFormat to inject integer parameters into dynamically generated MyBatis SQL, large numbers are automatically formatted with commas (e.g., 10000 becomes 10,000), which can break SQL statements, and the article explains why this happens and how to prevent it by converting numbers to strings before formatting.

DecimalFormatIntegerFormattingMessageFormat
0 likes · 3 min read
Avoiding Unexpected Comma Formatting of Large Integers with MessageFormat in MyBatis SQL Generation
Selected Java Interview Questions
Selected Java Interview Questions
Jul 4, 2022 · Backend Development

Introducing MyBatis-Mate: Enterprise‑Level Features for MyBatis‑Plus

This article introduces MyBatis‑Mate, an official MyBatis‑Plus extension that provides enterprise‑grade capabilities such as dictionary binding, field encryption, data masking, dynamic table maintenance, audit logging, sharding, multi‑datasource switching, and customizable data‑scope handling, all illustrated with code examples.

MyBatisdata encryptionsensitive data
0 likes · 13 min read
Introducing MyBatis-Mate: Enterprise‑Level Features for MyBatis‑Plus
Sanyou's Java Diary
Sanyou's Java Diary
Jun 23, 2022 · Backend Development

Master MyBatis: From Basics to Advanced Features and Best Practices

This comprehensive guide explains what MyBatis is, compares it with Hibernate, details its core components, configuration, dynamic SQL, caching, plugins, pagination, and practical usage patterns, providing Java developers with clear examples, code snippets, and visual diagrams to master the framework efficiently.

Dynamic SQLMyBatisORM
0 likes · 38 min read
Master MyBatis: From Basics to Advanced Features and Best Practices