AMQPChannel::setPrefetchCount PHP Method

setPrefetchCount() public method

Set the number of messages to prefetch from the broker during a call to AMQPQueue::consume() or AMQPQueue::get(). Any call to this method will automatically set the prefetch window size to 0, meaning that the prefetch window size setting will be ignored.
public setPrefetchCount ( integer $count ) : boolean
$count integer The number of messages to prefetch.
return boolean TRUE on success or FALSE on failure.
    public function setPrefetchCount($count)
    {
    }

Usage Example

Esempio n. 1
0
 /**
  * @param $count
  *
  * @return bool
  */
 public function setPrefetchCount($count)
 {
     try {
         return $this->rawChannel->setPrefetchCount($count);
     } catch (\AMQPConnectionException $e) {
         ClientHelper::throwRightException($e);
     }
 }
All Usage Examples Of AMQPChannel::setPrefetchCount