Tagged articles
Spring Data JPA
28 articles · Page 1 of 1
This article analyzes the performance bottleneck of LIMIT OFFSET deep pagination in MySQL with millions of rows, demonstrates EXPLAIN plan analysis, compares traditional pagination, subquery, covering index, and keyset pagination approaches, provides Spring Boot implementation examples for MyBatis-Plus and JPA, and benchmarks showing keyset pagination maintains constant response time regardless of page depth.
Cursor PaginationDeep PaginationKeyset Pagination
0 likes · 22 min read

The article analyzes Spring Data JPA's Page and Slice pagination options, explains the hidden COUNT(*) overhead of Page, demonstrates both approaches with code examples, compares performance and UX impacts, and provides guidance on when to choose Slice for large‑scale or infinite‑scroll scenarios.
BackendPaginationSpring Boot
0 likes · 11 min read

This article provides a comprehensive interview self‑test covering JPA, Hibernate, and Spring Data JPA, including entity lifecycle states, repository proxy creation, PartTree method parsing, first‑level cache behavior, dirty checking, transaction binding, N+1 query problems, lazy loading exceptions, JPQL vs native queries, save vs persist differences, and the semantics of findAll returning an empty collection.
HibernateJPARepository
0 likes · 19 min read

The article explains three typical deadlock scenarios in Spring Boot 3.5—circular‑wait, connection‑pool starvation, and implicit DML deadlocks—shows minimal 10‑line code reproductions, demonstrates the resulting errors, and provides concrete fixes such as ordered locking, removing REQUIRES_NEW propagation, and using asynchronous events.
@TransactionalConcurrencyJava
0 likes · 9 min read

This article walks through Spring Data JPA interface projections—from basic setup and field aliasing to association queries, closed vs. open projections, pagination, and dynamic use—showing how they eliminate redundant data fetching, improve performance, and avoid common pitfalls.
BackendJPAJava
0 likes · 11 min read

This tutorial walks through integrating SpringBoot with JPA (Hibernate) from adding dependencies to configuring the datasource, defining entities, using JpaRepository, building service and controller layers, applying method‑naming rules, writing custom queries, comparing JPA with MyBatis and JdbcTemplate, and highlighting key pitfalls for rapid, low‑boilerplate data‑access development.
CRUDHibernateJPA
0 likes · 11 min read

The author measured six realistic Spring Boot scenarios on PostgreSQL with over 40,000 records, comparing Spring Data JPA and native JDBC, and found JDBC to be 4‑460× faster for batch inserts, updates, deletes and complex statistics, while JPA remains adequate for small‑scale CRUD operations.
JDBCORMPostgreSQL
0 likes · 10 min read

This article introduces Spring Data JPA and demonstrates six advanced capabilities—including Optional return types, Stream API, asynchronous CompletableFuture queries, offset‑based scrolling, and keyset‑based scrolling—each illustrated with concise code examples and execution results to boost productivity and performance.
Keyset ScrollingOptionalPagination
0 likes · 8 min read

This article compares MyBatis and Spring Data JPA, explaining their core concepts, performance, flexibility, learning curve, community support, and real‑world scenarios, and provides code examples and decision criteria to help developers choose the right data‑access framework for their Spring Boot applications.
JavaMyBatisORM
0 likes · 14 min read

This article introduces the most practical Spring Data JPA methods, explains when and why to use each one, and provides real‑world code examples ranging from basic CRUD operations to custom @Query, @Modifying, QBE, and dynamic specifications for advanced backend development.
JPA methodsJava PersistenceSpring Boot
0 likes · 11 min read

This article compares five major Java database access technologies—JDBC, Hibernate, Spring Data JPA, JOOQ, and MyBatis—detailing their code examples, strengths, weaknesses, and ideal use cases, while also offering a downloadable Spring Boot 3 case collection PDF for hands‑on practice.
HibernateJDBCJava
0 likes · 19 min read

This article presents a comprehensive guide to Spring Data JPA in Spring Boot 3, covering 131 practical cases, core repository interfaces, Specification and Criteria Builder techniques, and dozens of performance‑optimizing tips such as lazy loading, caching, batch processing, transaction management, projections, and stream queries.
JavaJpaRepositorySpring Boot
0 likes · 15 min read

IntelliJ IDEA 2024.2 introduces a suite of developer‑focused enhancements—including instant Spring Data JPA queries, cron expression auto‑completion, GraalJS‑powered HTTP client, advanced log management, real‑time performance charts, and rich data‑format visualizers—designed to boost productivity for Java and Kotlin programmers.
GraalJSIntelliJ IDEAJava
0 likes · 6 min read

IntelliJ IDEA 2024.2 introduces a suite of enhancements—including in‑IDE Spring Data JPA execution, smarter cron expression handling, GraalJS‑powered HTTP client, faster startup, improved code completion, new UI defaults, advanced Scala support, Markdown math rendering, and focused profiling—to boost developer productivity across Java and other languages.
GraalJSIDE FeaturesIntelliJ IDEA
0 likes · 14 min read

This article introduces Spring Data JPA's Query by Example (QBE) feature, explains its benefits and limitations, and provides step‑by‑step code examples—including entity definition, repository setup, and various query scenarios—illustrated with SQL output and screenshots.
Fluent APIJavaQuery by Example
0 likes · 11 min read

This article explains how Domain‑Driven Design (DDD) combined with Spring Data JPA enables clean, object‑oriented modeling of order workflows, introduces the Repository pattern for persistence, and demonstrates the full lifecycle—from creation to address modification and payment—through concise Java code and SQL examples.
DDDJavaSpring Data JPA
0 likes · 21 min read

This tutorial explains why auditing is essential, outlines the benefits such as data tracking, security, troubleshooting and compliance, and provides a complete Spring Data JPA implementation with code examples, testing procedures, and required dependencies.
JPAJavaSpring Data JPA
0 likes · 6 min read

This article explains how domain‑driven design (DDD) leverages object‑oriented principles and the Repository pattern, demonstrates integrating Spring Data JPA for persistence, and walks through a complete order lifecycle—including creation, address modification, and payment—showcasing lazy loading, automatic synchronization, and practical unit‑test examples.
DDDJavaSpring Data JPA
0 likes · 22 min read

After encountering repeated errors and timeouts while retrieving the newly introduced 'nucleic acid code' in China, the author uses the experience to discuss why Spring Data JPA can cause performance problems in high‑concurrency systems compared to MyBatis, urging careful framework selection and deep SQL knowledge.
HibernateJavaMyBatis
0 likes · 6 min read

This article introduces the Java Persistence API (JPA), explains why Spring Data JPA has become an essential skill for large companies, outlines its benefits for development efficiency and career growth, and recommends the comprehensive book “Spring Data JPA: From Basics to Advanced” with its detailed structure and practical examples.
Database AccessJavaJava Persistence API
0 likes · 27 min read

Learn how to extend Nacos’s configuration persistence beyond Derby and MySQL by cloning the feature_multiple_datasource_support branch, compiling the source with Maven, configuring Oracle as a datasource in application.properties, and launching Nacos in standalone mode, with step‑by‑step commands and essential scripts.
BackendConfigurationNacos
0 likes · 3 min read

This article analyzes why the test4 transaction in Spring Data JPA rolls back, covering common pitfalls such as wrong storage engine, improper JPA usage, non‑public transactional methods, and the role of Bean Validation exceptions in triggering rollbacks.
Hibernate ValidatorJavaSpring Data JPA
0 likes · 9 min read

The article compares Spring Data JPA and MyBatis, highlighting that while Spring Data JPA speeds up individual development, it can create maintenance challenges for teams, especially when tracking slow queries, and argues that MyBatis may be a better choice for collaborative projects.
Java PersistenceMyBatisSpring Data JPA
0 likes · 3 min read

This tutorial explains why caching is essential for growing Spring Boot applications, walks through adding Spring's annotation‑based cache support to an existing Spring Data JPA project, and details the key cache annotations, configuration steps, and observable performance improvements.
@CacheableSpring BootSpring Data JPA
0 likes · 10 min read

This guide explains step‑by‑step how to set up two separate databases in a Spring Boot application, configure Spring Data JPA for each, create the necessary configuration classes, and verify the setup with a simple integration test.
ConfigurationJavaMultiple Data Sources
0 likes · 9 min read

This tutorial walks through adding and initializing multiple Spring Boot data sources for JdbcTemplate, Spring Data JPA, and MyBatis, including property setup, configuration classes, bean definitions, testing code, and repository links for complete examples.
JdbcTemplateMulti Data SourceMyBatis
0 likes · 7 min read

This article explains how Spring Data JPA streamlines CRUD operations in Spring Boot by configuring dependencies, defining entity classes and repository interfaces, leveraging method‑name query derivation and @Query annotations, and validating functionality with comprehensive unit tests.
Spring Data JPAspring-boot
0 likes · 12 min read

This tutorial explains how to enable and configure transaction locks—including pessimistic and optimistic modes—in Spring Data JPA repositories, demonstrates the use of @Lock and @QueryHints annotations, and shows how to set lock timeouts to ensure data integrity under high concurrency.
JavaLockModeTypeOptimistic Lock
0 likes · 6 min read
