Skip to content

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

22 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

RofRof

A Pusher-protocol WebSocket server — public / private / presence channels, client events, and the HTTP push + channel-info API — built on uWebSockets.

Development

Standard: C++20

Dependencies

Project dependencies are fetched into a gitignored third_party/ directory by CMake's FetchContent, so no system -dev packages are required:

  • uWebSockets v18.15.0
  • uSockets 7dea1e0 (built with the epoll backend + OpenSSL)
  • jsoncpp 1.9.5

Located from the system (present on any normal toolchain):

  • OpenSSL (libssl / libcrypto)
  • zlib

Build

Requires cmake (>= 3.16) and a C++20 compiler.

cmake -S . -B build -DCMAKE_BUILD_TYPE=Release
cmake --build build -j

or via the Makefile wrapper:

make          # RelWithDebInfo build
make release  # optimized build

Run

./build/rofrof      # run from the repo root so apps.json is found
# or
make run

The server listens on port 7000 and reads its app definitions from apps.json in the working directory.

Threading

The server runs on a single uWebSockets event loop that owns all connection and channel state. Each connection is pinned to the loop that accepted it, so channel fan-out and HTTP-triggered broadcasts all execute on the same loop.

Features

  • App support
  • Client messages
  • Private channels
  • Presence channels
  • HTTP Channels API
  • HTTP Channel API
  • HTTP Users API
  • HTTP Trigger API
  • Signature verification (constant-time)
  • Per-app connection limit
  • Hostname check
  • Path check
  • Cluster support
  • Webhook support
  • Tests
  • Benchmarks

About

WebSocket Server for ThriveDesk

Resources

Stars

Watchers

Forks

Releases

Packages

Contributors

Languages