RdKafka\Queue::consume

(PECL rdkafka >= 0.9.1)

RdKafka\Queue::consumeConsume a single message

Description

public RdKafka\Queue::consume ( int $timeout_ms ) : RdKafka\Message

Consume a single message. See RdKafka\ConsumerTopic::consume().

Parameters

timeout_ms

The maximum amount of time to wait for a message to be received.

Return Values

Returns a RdKafka\Message or NULL on timeout.