示例#1
0
 public function __construct($name, $queues, Client $client, $interval = 60)
 {
     $this->workerName = $name;
     $this->queues = [];
     $this->client = $client;
     $this->interval = $interval;
     foreach ($queues as $queue) {
         $this->queues[] = $this->client->getQueue($queue);
     }
     $this->logger = new NullLogger();
 }
示例#2
0
 public function queueLength($queue)
 {
     return $this->client->getQueue($queue)->length();
 }