~/talk

Fully asynchronous queue solution with Kafka

Talkat PyCon Belarus 2017 · on Saturday, 2017-02-04· [nodejs, python]
links:none on file
slides:none on file

An endpoint writes each event (with receive timestamp) to Kafka and a consumer uses asyncio, aiokafka, aiopg to drain messages into a local in‑memory queue and perform bulk inserts and time‑based flush into Postgres when either batch size or age threshold is met. The system survives Postgres outages (Kafka persists to disk), boosts throughput from ~30 r/s to 10–40× depending on batch tuning, is ~80 lines of Python 3.6, and is validated by stopping consumers and simulating hours of DB downtime.

AI-written summary · about

  1. 0:00Introduction and problem overview
  2. 3:25Why Kafka for reliability
  3. 6:26Async processing with asyncio
  4. 12:53Consumer and producer design
  5. 19:24Parallel task execution
  6. 21:17Handling outages and testing
  7. 24:47Performance improvements
  8. 25:54Code availability and closing
~/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.