add IT tests for kafka producer + adapt code for better testing