Esempio n. 1
0
 /**
  * Removes the message from the queue
  *
  * @param \Aimeos\MW\MQueue\Message\Iface $msg Message object
  */
 public function del(\Aimeos\MW\MQueue\Message\Iface $msg)
 {
     try {
         $this->client->delete($msg->getObject());
     } catch (\Exception $e) {
         throw new \Aimeos\MW\MQueue\Exception($e->getMessage());
     }
 }
Esempio n. 2
0
 /**
  * Removes the message from the queue
  *
  * @param \Aimeos\MW\MQueue\Message\Iface $msg Message object
  * @throws \Aimeos\MW\MQueue\Exception
  */
 public function del(\Aimeos\MW\MQueue\Message\Iface $msg)
 {
     try {
         $this->channel->basic_ack($msg->getObject()->delivery_info['delivery_tag']);
     } catch (\Exception $e) {
         throw new \Aimeos\MW\MQueue\Exception($e->getMessage());
     }
 }
Esempio n. 3
0
 /**
  * Removes the message from the queue
  *
  * @param \Aimeos\MW\MQueue\Message\Iface $msg Message object
  * @throws \Aimeos\MW\MQueue\Exception
  */
 public function del(\Aimeos\MW\MQueue\Message\Iface $msg)
 {
     if ($this->client->ack($msg->getObject()) === false) {
         throw new \Aimeos\MW\MQueue\Exception('Couldn\'t acknowledge frame: ' . $msg->getBody());
     }
 }