Skip to content

Cvanshulll/NodeChat

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

NodeChat

NodeChat is a simple, real-time chat application that allows users on the same LAN to communicate through a centralized server. It uses Redis for managing chatrooms and message delivery.


Features

  • LAN Chat: Chat with users on the same Wi-Fi or LAN network.
  • Server Discovery: Clients automatically find the server using UDP broadcasting.
  • Chatrooms: Join specific chatrooms to communicate with others. To leave a chatroom, type exit.
  • Real-Time Messaging: Messages are delivered instantly using Redis Pub/Sub.

image


How It Works

  1. Server:

    • Broadcasts its IP for discovery.
    • Manages chatrooms using Redis channels.
    • Forwards messages between clients.
  2. Client:

    • Discovers the server via UDP broadcast.
    • Connects to the server and joins a chatroom.
    • Sends and receives messages in real-time.
  3. Redis:

    • Acts as a message broker.
    • Manages chatrooms and distributes messages.

Example:

Server Output:

alt text

Client 1 Output:

alt text

Client 2 Output:

alt text

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages