inflearn logo

From Polling to WebSockets: Designing Real-Time Interfaces That Stay in Sync After Disconnects

There are moments when a price changes in another window but doesn’t show up on your screen, even though it says “Connected.” Let’s walk through real execution logs, step by step—from how to choose between polling, long polling, SSE, and WebSocket with two virtual auction windows open, to resynchronizing after a disconnect and tracking changes across multiple servers and proxies.

6 learners are taking this course

Level Basic

Course period Unlimited

Node.js
Node.js
PostgreSQL
PostgreSQL
Redis
Redis
nginx
nginx
websocket
websocket
Node.js
Node.js
PostgreSQL
PostgreSQL
Redis
Redis
nginx
nginx
websocket
websocket

What you will gain after the course

  • You can choose between polling, long polling, SSE, and WebSocket based on the acceptable latency and input frequency, while also taking request costs into account.

  • By separating “Connected” from “Latest status confirmed,” you can determine when it’s safe to use the screen again after reconnecting.

  • Using eventId, revision, and the position through which changes have been applied, you can detect duplicates, out-of-order events, and gaps, then choose the right recovery method: replaying records or taking a new snapshot.

  • We can explain why we recheck bids that timed out using the same application key, and why we use an outbox to bridge saving and publishing.

  • When you scale out the servers or route traffic through Nginx, you can narrow down why only some windows are delayed by checking the connection list, Redis Pub/Sub, and response buffering.

Recommended for
these people

Who is this course right for?

  • For those who have tried changing the screen via the API but need guidelines on when and how to display values changed by someone else.

  • Anyone considering whether to shorten the polling interval or switch to SSE or WebSockets

  • Anyone who has experienced notifications being missed after reconnecting, or the same notification appearing twice when returning to a tab.

  • For anyone trying to figure out why only some screens update slowly after scaling up servers or adding a proxy.

Need to know before starting?

  • It’s enough if you can read HTTP requests and responses, JSON, and JavaScript functions, events, and asynchronous calls, and have experience changing on-screen values based on API results.

  • You only need to know how to store and retrieve rows in a database. Transactions and concurrent updates are covered in that lecture.

  • It’s okay if you haven’t worked with SSE, WebSockets, message brokers, or proxies.

Hello
This is haeyeomiso

Career Verified

606

Learners

23

Reviews

40

Answers

4.7

Rating

17

Courses

Nice to meet you!

I am Haeyeo, someone who explores the infinite possibilities of AI and computer science and wishes to share that journey with all of you.

During my undergraduate years, my passion for my major was so intense that I was nicknamed a 'Computer Science Addict.' I graduated at the top of my class with a major GPA of over 4.4. I then earned my Master's degree in AI from Seoul National University and further deepened my expertise through a doctoral program.

However, as I felt as much of a fascination for solving real-world problems with AI as I did for theoretical exploration, I took a break from my doctoral studies to gain valuable hands-on experience by working on AI-based LLM and video analysis projects at a startup.

Currently, I am working as an LLM project developer and PM at one of the top three conglomerates in Korea, contributing to creating positive changes that AI technology will bring to our lives. I will generously share with you the challenges I faced, the problem-solving processes I went through, and the vivid know-how I gained in the field. I will be your reliable guide on this journey into the exciting world of AI.

Inquiries and Proposals: haeyeo.open@gmail.com

More

Curriculum

All

36 lectures ∙ (5hr 35min)

Published: 
Last updated: 

Reviews

Not enough reviews.
Please write a valuable review that helps everyone!

haeyeomiso's other courses

Check out other courses by the instructor!

Similar courses

Explore other courses in the same field!

Limited time deal

$20.90

59%

$51.70