Development

(Almost) Lockless Stream Buffering

Sharing (and saving) bytestreams effectively.

Recently, I’ve been working on retooling the audio processing code for serenity, a Discord bot library. Adding features like looping, seeking, and shared resources between calls is made difficult when all input data arrives over pipes from ffmpeg and similar decoders. Due to this, I’ve designed a thread-safe shared stream buffer intended to lock only on accessing and storing new data.

Custom Open vSwitch Actions

A short tutorial on extending Open vSwitch.

For a project I’ve been working on (reimplementing some past work), being able to easily enable pushback at various points in the network is fairly important. For this, I wanted to try something I’d both learn from and be able to use as a springboard for later development and testing – mininet (and by extension, Open vSwitch) seemed like a good fit. Part of this requires a new feature to be hacked on top of OpenFlow: probabilistic packet dropping. I’ve written this short walkthrough/tutorial on the process for the benefit of anyone looking to make their own modifications. A full repository is included here.

[EDIT 2019-03-27]: Updated for OVS revision 8e73833.