Lesson 17: [Coming Soon] Building the Chat Server Core

Integrate all components into a complete chat server - message routing, user sessions, room management, and real-time communication

Edit on GitHub

Building the Chat Server Core

Coming Soon

This lesson will integrate all the components you’ve built into a complete, working chat server. You’ll learn how to:

  • Integrate WebSocket connections with chat rooms
  • Implement message routing and delivery
  • Build user session management
  • Create room discovery and management
  • Handle connection lifecycle events

What You’ll Build

By the end of this lesson, you’ll have implemented:

  • A complete chat server with multiple rooms
  • User session management with authentication
  • Message routing and delivery systems
  • Room creation and management
  • A working real-time chat application

Key Concepts Preview

% Chat server architecture
-module(chat_server).
-behaviour(gen_server).
% Core functionality
handle_websocket_message(UserId, RoomId, Message) ->
case chat_room_manager:send_message(RoomId, UserId, Message) of
ok -> broadcast_to_room(RoomId, {message, UserId, Message});
{error, Reason} -> send_error(UserId, Reason)
end.

This lesson builds on the WebSocket protocol from Lesson 15 and prepares you for the message broadcasting patterns we’ll explore in Lesson 17.


This lesson is currently under development. Check back soon for the complete content!

Finished this lesson?

Mark it as complete to track your progress

This open source tutorial is brought to you by Pennypack Software - we build reliable software systems.

Found an issue? Edit this page on GitHub or open an issue