~/talk

What I now know about HAproxied Django DB connections, and wish I'd known sooner

Talkat PyConline AU 2020 · 2020-09-04..09-06· [databases, django]
slides:none on file

If Django talks to a Galera MySQL/MariaDB cluster through HAProxy the default timeout client = 50s often causes MySQL error 2013 “Lost connection to MySQL server during query” for long Celery tasks while MySQL’s wait_timeout defaults to 28800s (8h). Fixes that work: close Django connections after the initial read, add retries with tenacity around DB updates, or set HAProxy’s timeout server/client to match MySQL (watch HAProxy’s ms/s units).

AI-written summary · about

  1. 0:00Intro
  2. 2:20Setting the stage
  3. 14:14Real world applications
  4. 16:48Making it robust
  5. 21:11Fixing HAproxied configuration
~/search
type to search 6,249 conferences, 138,987 speakers and 185,172 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
?
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.