We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
In a plugin, if I subscribe to a particular MQ message like 'device-stats' in this plugin example:
self.log.info(u"==> Subscribe to MQ 'device-stats' messages") self.add_mq_sub("device-stats") # ------------------------------------------------------------------------------------------------- def on_message(self, msgid, content): ''' Receive 'device-stats' messages msgid = 'device-stats' content = {u'timestamp': 1500937509, u'sensor_id': u'210', u'device_id': 32, u'stored_value': u'10240971'} ''' self.log.debug(u"Receive MQ '%s' message: %s" % (msgid, format(content))) if msgid == 'device-stats': ...
The on_message function will receive other messages too:
2017-07-26 10:58:56,944 domogik-flowmeter DEBUG Receive MQ 'device-stats' message: {u'timestamp': 1501059536, u'sensor_id': u'444', u'device_id': 84, u'stored_value': u'0.0'} 2017-07-26 10:58:57,055 domogik-flowmeter DEBUG Receive MQ 'device-stats' message: {u'timestamp': 1501059536, u'sensor_id': u'452', u'device_id': 89, u'stored_value': u'0.0'} 2017-07-26 10:59:02,869 domogik-flowmeter DEBUG Receive MQ 'device.update' message: {u'client_id': u'plugin-flowmeter.hades', u'device_id': u'86'} 2017-07-26 10:59:02,971 domogik-flowmeter DEBUG Receive MQ 'device.update' message: {u'client_id': u'plugin-flowmeter.hades', u'device_id': u'86'}
The text was updated successfully, but these errors were encountered:
No branches or pull requests
In a plugin, if I subscribe to a particular MQ message like 'device-stats' in this plugin example:
The on_message function will receive other messages too:
The text was updated successfully, but these errors were encountered: