I was able to get a GnatMQ working and test communication with it. I've decided that this is not going to work for me.
If there is no way for a gateway to use something other than MQTT? Yes, its great, but for this project, does not fit.
Future revision maybe?
HOST: [
http://intranet.p.org ]
URL: [ /myservice/{topic}/{id}/{value} ]
Or we publish the URL with the message data? Then we can process the returned data?
I could write a MQTT Subscriber that listens for a published event which then takes that event and dumps into our SQL Database or I can write Arduino code that specifically sends a message to a REST service, which does what it needs to.
I was able to create something within an hour using an ESP8266 that communicated to my internal web service, saves the data it gets into a SQL database, where we can send email,s run reports, etc.
Ideally, I would want my gateway to talk directly to my web service. Then the web service processes the data and does what is needed.
GnatMQ source is available, in theory, I could change the code in that to push the received data to a database and not worry about rebroadcasting the data out, I prefer not to do since we already have a Web Service available.
Here is a perfect example of the problems I'm talking about.
http://www.hivemq.com/blog/mqtt-sql-databaseThis will limit the mc-gateway from being used for certain enterprise solutions.
Thank you,
Trey