Ejemplo n.º 1
0
 /**
  * @throws Exception\RuntimeException
  *
  * @return mixed
  */
 public function receiveMessageDirectly()
 {
     return $this->channel->receiveMessage();
 }
Ejemplo n.º 2
0
 /**
  * @param ChannelInterface $channel
  * @param WorkerStatus     $result
  *
  * @throws Exception\RuntimeException
  */
 public static function sendStatusMessage(ChannelInterface $channel, WorkerStatus $result)
 {
     $channel->sendMessage($channel instanceof SerializedChannel ? $result : ['_status_' => $result->toArray()]);
 }