apollo 源自 activemq,以快速、可靠著称,支持多协议:STOMP, AMQP, MQTT, Openwire, SSL, and WebSockets,下面就STOMP, AMQP, MQTT客户端进行介绍。
以下针对apollo 1.7.1 进行介绍
1、stomp
单就stomp协议方面,apollo目前支持stomp1.0、1.1、1.2三个版本,各种语言的客户端支持的版本各不相同,下面是官方给的一个完整的列表
Name | Language | Description | Compliance |
---|---|---|---|
activemessaging |
Ruby | an attempt to bring the simplicity and elegance of Rails development to the world of messaging | 1.0 |
AnyEvent::STOMP |
Perl | a lightweight event-driven STOMP client | 1.0 |
Apache CMS |
C++ | is a JMS-like API for C++ | 1.0 |
Apache NMS |
C# and .Net | a JMS-like API for .Net | 1.0 |
as3-stomp |
Flash | an actionscript 3 implementation of the STOMP protocol | 1.0 |
delphistompclient |
Delphi and FreePascal | a STOMP client for Embarcadero Delphi and FreePascal | 1.0 |
dstomp |
Dynamic C | a STOMP client library written in Dynamic C for Rabbit | 1.0 |
Gozirra |
Java | a lightweight implementation of the STOMP specification | 1.0 |
hxStomp |
Haxe | a TCP socket-based STOMP protocol client library written for the Haxe language | 1.0 |
libstomp |
C | an APR based C library | 1.0 |
Net::Stomp |
Perl | a Streaming Text Orientated Messaging Protocol client | 1.0 |
Net::STOMP::Client |
Perl | STOMP object oriented client module | 1.0 1.1 1.2 |
objc-stomp |
Objective-C | a simple STOMP client based on AsynSocket | 1.0 |
POE::Component::Client::Stomp |
Perl | a Perl extension for the POE Environment | 1.0 |
onstomp |
Ruby | client library for message passing with brokers that support the STOMP protocol | 1.0 1.1 |
Public.Protocols.Stomp |
Pike | Public.Protocols.Stomp | 1.0 |
pyactivemq |
Python | module for communicating with the ActiveMQ message broker | 1.0 |
React/STOMP |
PHP | STOMP bindings for React | 1.1 |
simplisticstompclient |
PHP | a simpler STOMP client for PHP | 1.0 |
Stampy |
Java | a Java implementation of the STOMP 1.2 specification | 1.2 |
stomp |
PHP | STOMP client extension | 1.0 |
stomp |
Ruby | client for the STOMP messaging protocol | 1.0 1.1 |
stomper |
Python | a client implementation of the STOMP protocol | 1.0 |
stomp.erl |
Erlang | a STOMP client for Erlang | 1.0 |
stompest |
Python | a full-featured STOMP implementation for Python including both synchronous and asynchronous clients | 1.0 1.1 1.2 |
StompKit |
Objective-C | modern event-driven Objective-C library for STOMP | 1.2 |
stompy |
Python | implementation of the STOMP protocol in Python | 1.0 |
stompngo |
Go | a STOMP 1.1+ Client Package | 1.0 1.1 1.2 |
stomp-php |
PHP | the FuseSource PHP client implementation | 1.0 |
stomp.py |
Python | a Python client library which can also be run as a standalone, command-line client for testing. | 1.0 1.1 1.2 |
stomp.js |
JavaScript | is a JavaScript library for Web browsers using STOMP Over HTML Web Sockets | 1.0 1.1 |
tStomp |
TCL | a STOMP Implementation for TCL | 1.1 |
Zend_Queue |
PHP | for Zend PHP clients | 1.0 |
2、AMQP协议
Apollo 1.7.1 支持AMQP 1.0,凡是支持AMQP1.0的client,都可以与Apollo 1.7.1 进行交互。
官方特别推荐了 Apache Qpid Proton project (支持C、C++、Java、Python) http://qpid.apache.org/proton/
当然,为了更好地支持amqp协议,建议你在apollo的配置文件中添加以下amqp的默认协议端口
<connector id="amqp" bind="tcp://0.0.0.0:5672"/> <connector id="amqps" bind="ssl://0.0.0.0:5671"/>
3、mqtt协议
apollo支持 v3.1 协议,支持以下客户端
官方示例为Java: mqtt-client
- Java : mqtt-client, MeQanTT
- C : libmosquitto
- Erlang : erlmqtt, my-mqtt4erl
- .NET : MQTTDotNet, nMQTT
- Perl : net-mqtt-perl, [anyevent-mqtt-perl]https://github.com/beanz/anyevent-mqtt-perl()
- Python : nyamuk
- Ruby : mqtt-ruby, ruby-em-mqtt
- Javascript : Node.js MQTT Client
- Delphi : TMQTTCLient
- Device specific: Arduino, mbed, Nanode, Netduino
完整列表请移步这里 https://github.com/mqtt/mqtt.github.io/wiki/libraries
时间: 2024-10-10 08:27:37