src/Publisher/AsyncPublisher.php
public function publish($data, $routingKey = '', array $headers = [])
    {
        $this->driver->publish($this->exchangeName, new Message($data, $routingKey, $headers));

        return null;
    }
public function publish($data, $routingKey = '', array $headers = [])
    {
        $this->driver->publish($this->exchangeName, new Message($data, $routingKey, $headers));

        return null;
    }
Publish a message on the queue

@param mixed    $data
@param string   $routingKey
@param string[] $headers

@return mixed

@throws AssertionFailedException
@throws \InvalidArgumentException