protected function createJobSocket()
    {
        /** @var Context|\ZMQContext $jobContext */
        $jobContext = new Context($this->loop);
        $this->jobSocket = $jobContext->getSocket(\ZMQ::SOCKET_SUB);
        $this->jobSocket->connect($this->config['sockets']['worker_job']);
        $this->jobSocket->on('messages', [$this, 'onJobMessage']);
    }
protected function createJobSocket()
    {
        /** @var Context|\ZMQContext $jobContext */
        $jobContext = new Context($this->loop);
        $this->jobSocket = $jobContext->getSocket(\ZMQ::SOCKET_SUB);
        $this->jobSocket->connect($this->config['sockets']['worker_job']);
        $this->jobSocket->on('messages', [$this, 'onJobMessage']);
    }
protected function createJobSocket ( ) { /** @var Context|\ZMQContext $jobContext */ $ jobContext = new Context ( $ this -> loop ) ; $ this -> jobSocket = $ jobContext -> getSocket ( \ ZMQ :: SOCKET_SUB ) ; $ this -> jobSocket -> connect ( $ this -> config [ 'sockets' ] [ 'worker_job' ] ) ; $ this -> jobSocket -> on ( 'messages' , [ $ this , 'onJobMessage' ] ) ; }
Creates socket to receive jobs from server and registers corresponding callbacks.
Creates socket to receive jobs from server and registers corresponding callbacks .