Input and Output stream ring buffers, output has unit tests.