mqtt

MQTT topic names for request/response

不问归期 提交于 2021-01-28 23:55:38
问题 I'm designing a system with many devices using MQTT to connect to a central broker. There are some masters that can send requests to certain devices that are slaves. The request from one master is usually directed to one slave. The topic for requests could be: mysystem/slaveId/req , so the slaves can subscribe to this topic and master publishes to the same topic. Only the addressed slave will receive the request, as it should be. My question is how to decide the topic for responses. I'm in

How Can I Publish File to AWS- IoT using Mosquitto in Python

一个人想着一个人 提交于 2021-01-28 22:56:43
问题 I am trying to publish a file to AWS IoT using Mosquitto and python. The file i need to publish is a jpg file that is in my local directory. I have secret key and access key that are required to publish data to IoT. I am very new to programming and don't know how to write this program. can someone help me please? I apologize if this is something very basic. Thank you I have already tried this How can I publish a file using Mosquitto in python? and did not work for me. This is how i tired to

advice on mqtt messaging implementation

柔情痞子 提交于 2021-01-28 22:09:57
问题 I'm developing a messaging app using MQTT, after moving off GCM due to multiple failures. I have a server broker online, and a client connecting and subscribing to it, and receiving messages of subscribed topics. Now I'm thinking about to what to subscribe to and what message to send. I have a server for the GCM implementation (user id, google key); I think I don't need that anymore? I thought about subscribing to the broker with the user ID and if user B wants to send a message to user A,

How Can I Publish File to AWS- IoT using Mosquitto in Python

心已入冬 提交于 2021-01-28 21:40:22
问题 I am trying to publish a file to AWS IoT using Mosquitto and python. The file i need to publish is a jpg file that is in my local directory. I have secret key and access key that are required to publish data to IoT. I am very new to programming and don't know how to write this program. can someone help me please? I apologize if this is something very basic. Thank you I have already tried this How can I publish a file using Mosquitto in python? and did not work for me. This is how i tired to

Apache Artemis Master-Slave Configuration: RAM consumption increases continuously up to 100% RAM usage - after that Broker stops working

和自甴很熟 提交于 2021-01-28 12:13:04
问题 I have a problem with the artemis failover cluster (master-slave configuration) and do not find an answer what I am doing wrong. My systems are two Ubuntu Linux 18 VM's with 4 Cores, 16GB RAM and 120 GB SSD and I use apache-artemis-2.11.0 with java version 1.8.0_111. I configured "-Xmx14G" in the artemis.profile file to give the artemis enough memory to run. JAVA_ARGS=" -XX:+PrintClassHistogram -XX:+UseG1GC -Xms512M -Xmx14G -Dhawtio.realm=activemq -Dhawtio.offline=true -Dhawtio.role=amq

Offline messages not being send to adafruit iot portal by mosquitto broker

旧巷老猫 提交于 2021-01-28 05:11:18
问题 I have a raspberry pi in which I have installed mosquitto broker and mqtt. Pi is connected to sensor and I need to send this data to adafruit IOT protal . I am able to send all the data when the pi is connected but when the pi goes offline, I am only able to transmit data for 20-30 sec. If the pi is offline for more than 2-3 mins then that data is not transmitted to portal. I have created a bridge.conf file and add all the configurations to be used my mosquitto. Here is the content:

Poll and get MQTT messages from AJAX in browser

最后都变了- 提交于 2021-01-28 05:06:09
问题 Beginner here. Ok, I'm trying to accomplish a simple data flow: MQTT-Data-source ---> MQTT Broker ---> NodeJS-MQTT-Client ---> AJAX-on-web-browser (polling-every-3-seconds) I want to be able to get the MQTT message and show it in the AJAX component in browser side. Secondly, on console.log(mqttMessage); , how do i clear previous messages? Because on console I can see all previous data as well as the new data adding up. I'm using mqtt.js for my nodejs mqtt support on Express. //Server.js var

Google Cloud IoT - Invalid MQTT publish topic

非 Y 不嫁゛ 提交于 2021-01-28 04:25:14
问题 I am using a Python client with paho-mqtt to publish in this specific topic of Google Cloud IoT: projects/my_project/topics/sm1 . My code is below, based on examples of the Google IoT documentation: import paho.mqtt.client as mqtt import ssl, random, jwt_maker from time import sleep root_ca = './../roots.pem' public_crt = './../my_cert.pem' private_key = './../my_pr.pem' mqtt_url = "mqtt.googleapis.com" mqtt_port = 8883 mqtt_topic = "/projects/my_project/topics/sm1" project_id = "my_project"

Google Cloud IoT - Invalid MQTT publish topic

ぐ巨炮叔叔 提交于 2021-01-28 04:00:56
问题 I am using a Python client with paho-mqtt to publish in this specific topic of Google Cloud IoT: projects/my_project/topics/sm1 . My code is below, based on examples of the Google IoT documentation: import paho.mqtt.client as mqtt import ssl, random, jwt_maker from time import sleep root_ca = './../roots.pem' public_crt = './../my_cert.pem' private_key = './../my_pr.pem' mqtt_url = "mqtt.googleapis.com" mqtt_port = 8883 mqtt_topic = "/projects/my_project/topics/sm1" project_id = "my_project"

Mosquitto-auth-plugin ACL for subscription

╄→尐↘猪︶ㄣ 提交于 2021-01-28 02:08:32
问题 I am currently using the mosquitto broker to see if I can build something interesting with it and I came across this plugin for authentication called mosquitto-auth-plugin. I followed the documentation of the plugin and I am using postgres as the back-end table. It seems to be working with respect to user authentication. When it comes to ACL I find the publish ACL is on spot but the subscription ACL is something I am not able to wrap my mind around. |-- GETTING USERS: karthik 1546887525: |--