コード例 #1
0
 /**
  * Subscribed to RSQueueProducer event.
  *
  * Add to collect data a new producer action
  *
  * @param RSQueueProducerEvent $event Event fired
  *
  * @return QueueCollector self Object
  */
 public function onProducerAction(RSQueueProducerEvent $event)
 {
     $this->data['total']++;
     $this->data['prod'][] = array('payload' => $event->getPayloadSerialized(), 'queue' => $event->getQueueName(), 'alias' => $event->getQueueAlias());
     return $this;
 }
コード例 #2
0
 /**
  * Testing Redis getter
  */
 public function testGetRedis()
 {
     $this->assertSame($this->rsqueueProducerEvent->getRedis(), $this->redis);
 }