Node Background Jobs: Async Processing for Async Language
No matter what you web application does, it’s likely that you can get value from having a background processing framework.
With Node.js, there are a number of unique things we can do to handle jobs outside of the request cycle or get high parallelism from our singe event-loop thread.
“Everything is better in node, including the bad ideas” says Evan Tahler, Director of Technology at TaskRabbit.
Imagine someone comes to your website, they sign up, you write a record to the database, and now you need to respond with an email or 200. In this talk, speaker Evan Tahler presents this very situation and explores several strategies for executing this task, node background jobs, each of which use Node.js.
- Possible Task Strategies
- Foreground (in-line)
- Parallel (threaded-ish)
- Local Messages
- Remote Messages
- Remote Queues (Resque-ish)
- Event Bus
For each of these strategies, Evan discusses the pros and cons of implementation using Node.js, comparing Node.js to other languages and environments. He also shows how to avoid blocking web workers, save web server resources, increase communication speed for email and other network applications, and more.
About Evan Tahler
Evan Tahler is the Director or Technology for TaskRabbit. Evan is also the creator & maintainer of the actionhero.js, a Node.js framework. Evan was previously a Lead Ruby engineer at Modcloth, a BluRay software architect for Disney, and once founded a “dumb phone” game company.