
Learn real-time communication with socket.io 3.x and Angular 11.x, delivering live updates across multiple clients without polling through hands-on projects like livestock updates and a Margo DBI server app.
Explore socket.io, a real-time, bi-directional, event-based library for server-browser communication. It offers reliability, auto-reconnect, heartbeat, binary support, multiplexing, and room-based broadcasting via namespaces.
Explore the socket.io api for server and client, covering events, middleware, namespaces, rooms, emitting, and broadcasting messages between server and client.
Develop a first socket io application with express js, creating a server that emits fake stock values for Apple, Google, and Microsoft to a browser client.
Set up a Socket.IO server with Express, create a random stock values module, and emit Apple, Google, and Microsoft stock updates to clients every five seconds.
Explain why two clients show different stock values in a socket.io angular app due to separate connections and blocking vs non-blocking operations in Node.js, highlighting the event loop and timers.
Broadcast stock updates to all clients by using socket.io namespaces and rooms, creating a default / namespace and a stocks room joined by the angular service.
this demo shows avoiding implicit connections to the default namespace in socket.io 3.x by connecting directly to the live namespace, with logs showing default namespace connection and live namespace connection.
Migrate socket.io 2.x to 3.x part II covers removing implicit default namespace, eliminating join/leave callbacks, and replacing with socket.on. Namespace.client's list becomes namespace.allSockets and returns a promise, with 11.x examples.
Build a real-time online pizza order app with socket.io and a MongoDB server, using results and pizza orders collections to display live status and counts.
Learn to write MongoDB queries using the mongo shell: create databases and collections, insert multiple documents, and fetch data with find and findOne, using pretty for readable output.
Build a real-time socket.io pizza orders app by writing an aggregate group-by query on the pizza orders collection and broadcasting counts to the orders room in the pizza namespace.
Add an Angular component integrated with a Socket.IO service, fetch documents via an observable, and display them in a table with images and currency formatting.
Migrate the pizza order ui from socket.io 2.x to 3.x in an angular 11 app, update the client package and services, and adopt new observable syntax to verify real-time updates.
Configure two routes in an Express router to fetch all Angular questions and post votes, using a data access layer and middleware.
Create a client front end using Angular, enable routing, choose the default css, and integrate Bootswatch Bootstrap styles for the end user voting app.
Write the service logic by configuring the http client, injecting it into a world service, and connecting to rest endpoints to fetch questions via an observable and post world data.
Explore the single page application structure with a home component and a navigation menu, using lazy loading, routes, and a router outlet to load modules.
Create a socket.io server with express to stream real-time vote aggregates from MongoDB change streams and push updates to the Angular client for display with high charts.
Build an express and socket.io app that runs an aggregate query on the angular warts collection, grouping by technology name and emitting results to the dashboard namespace, with change streams.
Explore the single-page application code for the client dashboard, including the home module, dashboard home component, navigation module, dashboard menu component, bootstrap menu, and the router outlet in Angular routing.
Have you ever thought of building real-time communication applications for your clients or in your organization? Are you tired of writing the same old long polling logic to get the updates from your databases? Do you want to share live updates of the data across two or more than two applications? Do you work with live stocks or tweets kind of applications?
As you know our clients or customers would like to get quick and live updates of the information like stocks, currencies, the sales data, tweets etc. Or they want to build live collaborative applications for the customers/in-house applications. This is where we can think of Real-time Communication and we can achieve that using one of the most popular library Socket.IO. Easy to learn and easy to implement.
This course is a complete hands-on course where we will take few real-time scenarios and develop several applications step-by-step. At the end of this course, you will have better understanding of Socket.IO library and you will be able use this library to build RTC applications.
Update - This course has been updated to Socket.IO 3.x and Angular 11.x
All the examples of this course has been updated from Socket.IO 2.x to Socket.IO 3.x. Also, all the client applications have been migrated from Angular 9.x to Angular 11.x.