Skip to content
This repository has been archived by the owner on Jan 3, 2024. It is now read-only.

Server to create realtime collaborative rooms

License

Notifications You must be signed in to change notification settings

collabserver/collabserver-server

Repository files navigation

Collab Server

license Build Status

master dev
Build Status Build Status

Overview


Server for realtime collaboration on any CollabData from collab-data-crdts project.

  • User point of view: a Collaborative room is a current instance of collaboration where several users are working on the same Data. The data itself is any implementation of CollabData interface with a set of Operation implemented (See collab-data-crdts).
  • In server: the server doesn't know anything about the concrete data implementation. A room only store the list of operations applied since the beginning. The server deals with the broadcasting system and ensure that all users in a room receive each operations.

Getting Started


  1. Clone project with submodules
    • Clone with recursive: git clone --recursive https://github.com/CollabServer/collabserver-server.git
    • To pull changes from submodules, uses: git pull --recurse-submodules=on
    • For further informations about submodules, check the official Git documentation
  2. Build the server
    • Be sure you have all the requirements
    • Build collabserver-server (See build instructions)
  3. Start the server
    • Open a console and run the collabserver executable
    • Logs are displayed here
    • Ctrl+C to stop server
  4. Connect users

Features


  • Users
    • Connection
    • Disconnection
    • Enter room
    • Leave room
    • Create room
    • Delete room
  • Room
    • Room ID (to join the room of collaboration)
    • Add user
    • Remove user
    • Has user
    • Broadcast operation to all users

Build (CMake)


# Build and start the server
mkdir build
cd build
cmake -DCMAKE_BUILD_TYPE=Release ..
make
make run # This start the CollabServer

# Or using build script
./build.sh
cd build
make run
# Build the tests
mkdir build
cd build
cmake -DCOLLABSERVER_SERVER_TESTS=ON ..
make
make runAllTests

# Or use the build script
./build.sh
CMake option Description
COLLABSERVER_SERVER_TESTS (ON / OFF) Set ON to build unit tests
CMAKE_BUILD_TYPE Debug, Release, RelWithDebInfo, MinSizeRel

Generate Documentation


  1. Install Doxygen
  2. Run doxygen Doxyfile
  3. Files are placed in doc folder

Contribution


Feel free to ask me any question, share your ideas or open an issue. I started this project during my master thesis at University of Montreal. Format uses clang-format with the Google Coding style https://google.github.io/styleguide/cppguide.html (see .clang-format for further information). Make sure you autoformat on save (see https://clang.llvm.org/docs/ClangFormat.html)