PHP Zero MQ
use ZMQ;
use ZMQContext;
use ZMQSocket;
$addr = "tcp://127.0.0.1:5555";
$context = new ZMQContext();
$socket = new ZMQSocket($context, ZMQ::SOCKET_REQ);
$socket->connect($addr);
$socket->send("hello , this is a messgae");
$reply = $socket->recv();
$socket->disconnect($addr);
本文提供了一个使用 PHP 进行 ZeroMQ 编程的例子。演示了如何建立连接、发送消息及接收回复的基本流程。
1139

被折叠的 条评论
为什么被折叠?



