thanks @edenhill - I've already set it to 1ms, but just going to upgrade to version 0.9.4 and see if that helps. Also, the way I was calling poll was with the following:
$this->getProducer()->poll(-1);
which from what I can gather waits until it gets a response. I tried changing to a while loop of $producer->poll(10);
etc but didn't see any difference - so are there any implications in using my original methodology of $this->getProducer()->poll(-1);
or any reasons not to do it that way etc?
$conf->set('client.id', 'track');
$conf->set('socket.blocking.max.ms', 1);
$conf->set('queue.buffering.max.ms', 1);
$conf->set('batch.num.messages', 1);
I can’t even set a stats_cb
as a config value as it throws the following error:
RdKafka\Exception: Property "stats_cb" must be set through dedicated .._set_..() function