hamon-in / librtcdcpp

A simple WebRTC DataChannels library
BSD 3-Clause "New" or "Revised" License
13 stars 3 forks source link

Introduction

This is a fork of the librtcdcpp project which was written in C++. Changes include a C wrapper which is used by the python wrapper (implemented using CFFI) and the ability to run multiple peer connections within the same process. A stress test script and a CLI python client is bundled.

Quick start

After a clone, do:

Stress test

Running the stress test script without arguments will run a series of tests, first of which is a sequential test for each packet sizes of 2, 4, 8 ... 64 KBs. Secondly, it will do a concurrent test (2 peers at a time) for each of those packet sizes. At the end of this, it will plot :bar_chart: using matplotlib.

:recycle: Note: Each time the library is made to create new 'peers', an IPC socket file will be created which has the path "/tmp/librtcdcpp{pid}". If not closed properly, these files will be left back. Do check for /tmp/librtcdcpp* files and rm /tmp/librtcdcpp* to make sure the inodes don't get full.

Stress test results on AMD A8 7410 with the ZMQ/protocol buffers fixes-:

*concurrent test was done with 2 peers at a time with the same packet size for each packet size.

Signalling server

From project root, on the host machine or a different machine on the network (x86/amd64 only), set up the signalling server:

Signalling client

Go inside the debian container created from the quick start step above and do the following: