---
title: "Chapter 14. Meteor: The Application as One System"
url: "https://www.mikefluff.com/en/read/from-closures-to-autonomous-systems/ch14"
locale: "en"
author: "Mikhail Savchenko (Mike Fluff)"
updated: "2026-11-18T12:24:57.879Z"
book: "https://www.mikefluff.com/en/books/from-closures-to-autonomous-systems"
access: "lead-in"
purchase: "https://www.mikefluff.com/en/books/from-closures-to-autonomous-systems"
alternates:
  - locale: "ru"
    url: "https://www.mikefluff.com/ru/read/from-closures-to-autonomous-systems/ch14"
    markdown: "https://www.mikefluff.com/ru/read/from-closures-to-autonomous-systems/ch14.md"
  - locale: "en"
    url: "https://www.mikefluff.com/en/read/from-closures-to-autonomous-systems/ch14"
    markdown: "https://www.mikefluff.com/en/read/from-closures-to-autonomous-systems/ch14.md"
  - locale: "pt"
    url: "https://www.mikefluff.com/pt/read/from-closures-to-autonomous-systems/ch14"
    markdown: "https://www.mikefluff.com/pt/read/from-closures-to-autonomous-systems/ch14.md"
---

# Chapter 14. Meteor: The Application as One System

*[JavaScript: From Closures to Autonomous Systems](https://www.mikefluff.com/en/books/from-closures-to-autonomous-systems)*

From the very beginning the web had one limitation nobody thought about for a long time: the browser always starts the conversation. It sends a request, the server answers, and there the conversation ends. If the server has something new, say a chat message has arrived or someone has changed a document, it cannot tell the browser until the browser asks. So the first «live» pages simply asked every few seconds whether there was anything new. The answer was almost always «no», almost all the traffic went to these empty questions, and the news still arrived late, at the next question.

In March 2006 Alex Russell, the lead of the Dojo library, wrote a blog post giving a name to a set of techniques some developers were already using by then. He called them Comet. The simplest was called long polling: the browser sends a request, the server takes its time answering and keeps the connection open until data appears, answers, and the browser immediately sends the next request. Cleverer was the hidden-frame technique. The page opened a frame that never finished loading, and the server every now and then appended bits of script to it, which the browser executed as soon as it received each one. Both techniques worked, but on the servers of the time every open connection occupied a thread or a process, and a thousand users waiting for news meant a thousand sleeping threads. Three years later Ryan Dahl would run into the same difficulty and put it on his slides when presenting Node. And Russell himself, in 2012, together with Wirfs-Brock, would lead the discussion of the «maximally minimal classes» from the second chapter.

The real solution came in December 2011, when the WebSocket standard was published. The browser opens a connection once, and from then on both it and the server can write to it whenever they like. But browsers did not learn this at once, and proxies and corporate networks kept breaking such connections for a long time, so libraries became popular that tried to open a WebSocket and, if that failed, quietly fell back to long polling. One of them, SockJS, became the foundation of Meteor.

---

The rest of this chapter is free on the site once the reader confirms an email address: https://www.mikefluff.com/en/read/from-closures-to-autonomous-systems/ch14
