~/talk

One Million Clicks per Minute with Kafka and Clojure

Talkat Clojure/west 2016 · 2016-04-15..04-16· [clojure]
slides:none on file

A Clojure consumer pipeline reads Kafka at 300K messages/sec and targets over one million clicks per minute by switching from per-message DB increments to 5,000-message batching, fixing a head-of-lazy-seq leak, and replacing clj-kafka messages with createMessageStreams plus multiple Kafka stream objects for concurrent pull-fetch. Clicks are imputed to positions via unreliable “hail mary” pings and joined against recent position windows stored in a Clojure priority-map of queues, which yields O(1) lookups and acceptable insert/decay cost — the system becomes stable, low-latency, and practical for real-time per-position click rates.

AI-written summary · about

  1. 0:00Intro
  2. 0:42HOW NOT TO PROCESS
  3. 4:04The User Story
  4. 5:53Apache Kalka
  5. 10:34The dangers of an infinite lazy seq
  6. 12:20Batching and Grouping
  7. 14:51Not lockstepping network and CPU
  8. 16:23Wrapping the KalkaStream in a channel
  9. 17:37Multithreading
  10. 20:08The New User Story
  11. 28:10What have we learned?
  12. 29:00The JVM is a first-class citizen in stream processing
~/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.