public function getUnsubscribeFrame($destination, array $headers = array(), $durable = false) { $frame = parent::getUnsubscribeFrame($destination, $headers, $durable); if ($this->hasClientId() && $durable) { $frame->setHeader('activemq.subscriptionName', $this->getClientId()); } return $frame; }
/** * Remove an existing subscription * * @param string $destination * @param array $properties * @param boolean $sync Perform request synchronously * @param boolean $durable durable subscription * @return boolean * @throws StompException */ public function unsubscribe($destination, $properties = null, $sync = null, $durable = false) { $unsubscribe = $this->sendFrame($this->protocol->getUnsubscribeFrame($destination, $properties ?: array(), $durable), $sync); if ($unsubscribe) { $this->subscriptions[$destination] = false; } return $unsubscribe; }
/** * RabbitMq unsubscribe frame. * * @param string $destination * @param array $headers * @param boolean $durable durable subscription * @return Frame */ public function getUnsubscribeFrame($destination, array $headers = array(), $durable = false) { $frame = parent::getUnsubscribeFrame($destination, $headers); $this->addClientId($frame); if ($durable) { $frame->setHeader('persistent', 'true'); } return $frame; }