🌐Polling
Also known as Long Polling, Short Polling, HTTP Polling
The browser asks the server, is there news? It asks again and again.
Think of it like
Think of it like a child in a car asking, are we there yet? every few minutes.
Example
Jack's first version checked for new orders every 10 seconds. With 1,000 shop owners online, that was 100 requests a second, mostly empty.
Why it matters
Polling is the easiest way to get updates. Sometimes it is all you need.
Definition
Common mistake
Key takeaways
- 1Ask on a timer. Again and again.
- 2Mostly empty. Many requests bring nothing.
- 3Long polling waits. The server holds the request.