How to turn off all video feed depending on server load?


I would like to set a health check that runs, let’s say, every 15 seconds~, that would collect some server resource statistics, such as:

  • CPU Load
  • Free Memory
  • Network activity

If any of those are hitting critical levels, such as > 95% CPU usage/memory, or more than 45mb/s of upload being done, then drop the video feed for participants. Ideally, keeping the video feed of moderators.

This aims to reduce server load and prioritize voice feed, which is more important in my scenario, if the server resources reaches critical levels.

Has anyone attempted something like this before?

Can you point me to relevant APIs/code examples, such as the one that allows to drop video feed of all participants, for instance?


The JVB already does this.It will aggressively limit video if under unsustainable load.