paint-brush
How to use Redis Pub/Sub in Messengersby@vgukasov
5,321 reads
5,321 reads

How to use Redis Pub/Sub in Messengers

by Vladislav Gukasov3mApril 11th, 2022
Read on Terminal Reader
Read this story w/o Javascript
tldt arrow

Too Long; Didn't Read

A social network needs to instantly show a new message from another user without reloading a page. The most widespread architecture is: a web browser connects to a server via a WebSocket (a particular type of connection that is established once and is maintained after that) A WebSocket microservice subscribes to the user's private messaging channel. At some point, a web server publishes a message to a channel, and a WebSockets microservice sends it to the browser. Redis implements the Pub/Sub model using the example of private messages in the messenger example.

Company Mentioned

Mention Thumbnail
featured image - How to use Redis Pub/Sub in Messengers
Vladislav Gukasov HackerNoon profile picture
Vladislav Gukasov

Vladislav Gukasov

@vgukasov

Software Engineer @ Amazon

About @vgukasov
LEARN MORE ABOUT @VGUKASOV'S
EXPERTISE AND PLACE ON THE INTERNET.
L O A D I N G
. . . comments & more!

About Author

Vladislav Gukasov HackerNoon profile picture
Vladislav Gukasov@vgukasov
Software Engineer @ Amazon

TOPICS

THIS ARTICLE WAS FEATURED IN...

Permanent on Arweave
Read on Terminal Reader
Read this story in a terminal
 Terminal
Read this story w/o Javascript
Read this story w/o Javascript
 Lite