Skip to content

Stay curious. Build better.

Appearance

Choose how BestHub looks on this device.

Changes apply immediately.

Search articles

Open Discover with these filters

Suggested searches

Latest articles

11 min read

Spring Boot @Transactional Pitfalls: Deadlocks, Long Transactions & Propagation Failures

This article analyzes three critical @Transactional pitfalls in Spring Boot 3.5.0: deadlocks from inconsistent lock ordering during concurrent transfers, long transactions holding row locks during external RPC calls causing blocking and inconsistency, and nested transaction propagation causing unexpected rollbacks despite try-catch. Solutions include consistent lock ordering, transaction splitting, and using REQUIRES_NEW or programmatic transactions.

7 min read

Why Does @Transactional(REQUIRES_NEW) Still Roll Back Your Audit Log?

When a Spring @Transactional method with REQUIRES_NEW fails to persist audit logs after a rollback, the issue often stems from misconfigured rollback rules, caught exceptions, self‑invocation, non‑public or final methods, or incorrect propagation settings, all of which prevent the new transaction from committing.