protected function dispatch($message, MessageCallback $callback) : void
    {
        $sendable = $message;
        if (!($message instanceof Serializable)) {
            $sendable = new MessageWrapper($message);
        }
        $mf4phpMessage = $this->findObjectMessageFactory($message)->createMessage($sendable);
        $this->dispatcher->send($this->queue, $mf4phpMessage);
    }
protected function dispatch($message, MessageCallback $callback) : void
    {
        $sendable = $message;
        if (!($message instanceof Serializable)) {
            $sendable = new MessageWrapper($message);
        }
        $mf4phpMessage = $this->findObjectMessageFactory($message)->createMessage($sendable);
        $this->dispatcher->send($this->queue, $mf4phpMessage);
    }
protected function dispatch ( $ message , MessageCallback $ callback ) : void { $ sendable = $ message ; if ( ! ( $ message instanceof Serializable ) ) { $ sendable = new MessageWrapper ( $ message ) ; } $ mf4phpMessage = $ this -> findObjectMessageFactory ( $ message ) -> createMessage ( $ sendable ) ; $ this -> dispatcher -> send ( $ this -> queue , $ mf4phpMessage ) ; }
Send the message to the message queue.

@param $message
@param MessageCallback $callback
Send the message to the message queue .