Description: MQTT is an instant Messaging protocol developed by IBM that is likely to be an important part of the Internet of things. The protocol supports all platforms, almost all connected items and external connections, and is used as a communication protocol for sensors and actuators (such as the Internet of homes via Twitter). Apache Apollo is a proxy server, which is developed on the basis of ACTIVEMQ, can support stomp, AMQP, MQTT, Openwire, SSL, WebSockets and many other protocols.
Principle: The server creates a unique subscription number that the sender can send to this subscription number, and then the recipient (that is, the person subscribing to the subscription number) will receive a message from this subscription number. This completes the push of the message. The server is actually a message broker.
First, install Apache-apollo server
1.apache-apollo:http://activemq.apache.org/apollo/download.html
My use of the environment is Windows7
2. Download the file directory ( Note: Start looking at the tutorial said directly open the Bin directory under the Apollo.cmd file, flash back, because there is no java_home environment, you must add the Java environment ):
3. Install Java JDK, after deploying Java environment variable (must), administrator to run cmd
4. Open your Apache-apollo file location (open with the CD Apache-apollo directory) as follows:
5. Execute command:Apollo create Myapollo C:\apache-apollo\broker , after the broker is created, the following files appear in the C drive:
6. Enter the C:\apache-apollo\broker\bin directory and execute the following command:Apollo-broker run
7. After successful execution, return:
8. Open http://127.0.0.1:61680/, username admin, password Password:
The current connection status is as follows:
Second, the use of Google Mqttlens tool testing (my extension store cannot open, is the next good program decompression, loaded in):
Detailed Reference Tutorial: http://swf.com.tw/?p=1009
My configuration is as follows:
Third, the Apache-apollo file has a use of dome:
As follows:
MQTT + Apache-apollo Server beginner Use