System Design Fundamentals

0% completed

What is Long-Polling?

Long-polling is a technique where the client asks the server for data, and the server holds the request open until it actually has data to send. Instead of answering "nothing yet" every few seconds, the server stays quiet until there is real news.

Think of calling a support hotline. Regular polling is calling every five minutes to ask "any update?" and hearing "no" almost every time. Long-polling is calling once and staying on hold. The moment there is an update, the agent tells you.

Because the request just hangs there waiting for an answer, long-polling is sometimes called a "Hanging GET"

.....

.....

.....

Like the course? Get enrolled and start learning!