(PECL rdkafka >= 0.9.1)
RdKafka::poll — Poll for events
$timeout_ms) : void
Polls for events, cause application provided callbacks to be called.
An application using a sub-class of RdKafka should make sure to call poll() at regular intervals to serve any queued callbacks waiting to be called.
Specifies the maximum amount of time (in milliseconds) that the call will block waiting for events. For non-blocking calls, provide 0 as
timeout_ms. To wait indefinately for an event, provide -1.
Returns the number of events served.