~/talk

The Event Loop

Talkat CascadiaJS 2013 · 2013-11-14..11-15· [javascript]
links:none on file
slides:none on file

Demonstrates that async is not free: a synchronous factorials.map blocks an HTTP server though it finishes in ~100ms; switching each item to setImmediate makes the server responsive but triples total execution time (>3×). Introducing a batching helper reduces blocking to ~22ms while keeping total time near the original. Shows inconsistent “maybe async” file caching returns “done” before load until the second path is wrapped in process.nextTick, warns process.nextTick before I/O can starve IO, and explains libuv threadpool behavior.

AI-written summary · about

  1. 0:00The problem with blocking
  2. 1:15Async performance pitfalls
  3. 3:12Batching for balance
  4. 4:46Consistent asynchronous behavior
  5. 7:14NextTick vs Immediate
  6. 8:20Understanding libuv
  7. 12:58Live demo and conclusion
~/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.