Code like the buffer and splitter share very similar code to generate common response, add utility functions for these.