Simplifies and refines producer and consumer stuff

Signed-off-by: Mathias Garbe <mail@mathias-garbe.de>