~/talk

Multithreaded Data Insertion into a DB: From Speed to Atomicity — Spring + PostgreSQL

TalkinRussianat JPoint 2025 · 2025-04-03..04-04· [java, databases]
links:none on file
slides:none on file

Shows how to speed up database inserts in a Spring + PostgreSQL stack by parallelizing the insert work while still preserving atomicity of the overall operation. Covers Spring batch updates and PostgreSQL behavior, explains why updates/inserts are costly, demonstrates techniques to accelerate them in that stack, and compares different atomicity-preserving approaches with benchmark results.

AI-written summary · about

  1. 0:00Introduction
  2. 1:10Talk overview
  3. 2:14Multithreaded insertion basics
  4. 3:16Spring JDBC batch settings
  5. 4:40Atomic single-threaded insertion
  6. 5:01Making insertion async
  7. 6:03Making parallel insertion atomic
  8. 7:05Why updates are expensive
  9. 8:29Hibernate merge and caching
  10. 10:16Stateless session for updates
  11. 10:57Direct JDBC updates
  12. 11:58Transaction ID approach
  13. 12:42PostgreSQL MVCC explained
  14. 15:09Heap updates optimization
  15. 16:52FILLFACTOR tuning
  16. 19:23Final atomic multithreaded insertion
  17. 20:49Atomicity in separate table
  18. 22:36Active transaction entity
  19. 23:43PostgreSQL delete performance
  20. 24:23Lightweight transaction table
  21. 25:29Reading actual data options
  22. 28:32Fixing Hibernate query issues
  23. 30:19Benchmarking read ops
  24. 31:43Impact of uncommitted data
  25. 33:08Summary of transaction ID methods
  26. 34:10Hibernate fetch type problems
  27. 36:43PostgreSQL two-phase commit
  28. 39:54Final recommendations
  29. 40:59Q&A
~/search
type to search 8,222 conferences, 162,397 speakers and 219,688 talks
~/help
cmdctrl k
search every conference, speaker and series
/
focus the filter search
h
home
c
conferences
s
speakers
e
series
t
light / dark — the status bar button does the same
← →
on a talk: 5 seconds back / forward
0–9
on a talk: jump to 0%–90% of the recording
?
this help
esc
close this, then clear every filter — or just the search, while you are typing in it

Ignored while you are typing. Pages without a filter rail have no search to focus.