2017 © Pedro Peláez
 

library zmq

ZeroMQ bindings for Swoole.

image

swoole/zmq

ZeroMQ bindings for Swoole.

  • Friday, August 18, 2017
  • by matyhtf
  • Repository
  • 6 Watchers
  • 33 Stars
  • 48 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 5 Forks
  • 1 Open issues
  • 2 Versions
  • 12 % Grown

The README.md

Swoole/Async/ZMQ

ZeroMQ bindings for Swoole., (*1)

Install

The recommended way to install swoole/zmq is through composer., (*2)

{
    "require": {
        "swoole/zmq": "0.1.*"
    }
}
composer require swoole/zmq

Example

And don't forget to autoload:, (*3)

<?php
require 'vendor/autoload.php';

Here is an example of a push socket:, (*4)

$zmq = new Swoole\Async\ZMQ();

$zmq->on('Message', function ($msg)
{
    echo "Received: $msg\n";
});

$zmq->bind('tcp://0.0.0.0:9530');

And the pull socket that goes with it:, (*5)

$zmq = new Swoole\Async\ZMQ();

$zmq->connect('tcp://0.0.0.0:5555');

Swoole\Timer::tick(1000, function () use ($zmq)
{
    static $i = 0;
    $msg = "hello-" . $i++;
    echo "Sending: $msg\n";
    $zmq->send($msg);
});

The Versions

18/08 2017

dev-master

9999999-dev

ZeroMQ bindings for Swoole.

  Sources   Download

GPL

The Requires

  • php >=5.4.0
  • ext-zmq *

 

The Development Requires

zeromq zmq

18/08 2017

v0.1.3

0.1.3.0

ZeroMQ bindings for Swoole.

  Sources   Download

GPL

The Requires

  • php >=5.4.0
  • ext-zmq *

 

The Development Requires

zeromq zmq