News for hackers. Stuff that matters.
Re:Why MQTT is better than REST by sametmax on Thursday May 31, 2018 @03:20PM (#17199241)
I'd rather use the WAMP protocol (not the stack...): https://wamp-proto.org/

Not only does it works well for iot, but it also is very nice for the web and micro-service oriented architectures.

It's based on websocket, so it kinda works out of the box on most networks without bugging your local sysadmin, and has a bonus benefit of TLS support. And it's open standard with lots of open source clients, like MQTT.

It's also higher level, so you get (routed) RPC and PUB/SUB, with transparent result and error propagation accross language (you JS code in the browser can call you Java code on android discussing with your C# code in the cloud and your python code on the raspi).

The main implementation for the router, crossbar.io, works very well, with plenty of knobs for introspection, security, performance, etc. And you get authentication backed in.

No really, MQTT is very low level to my taste compared to WAMP.

Re:Why MQTT is better than REST by stargrazer on Friday June 01, 2018 @08:23AM (#17204603)
With MQTT, there are a number of broker implementations which offer redundancy/resiliency. I did a quick check and didn't find any place stating anything about any of the routers being able to run in a redundant/resilient mode. If that is available, running WAMP becomes feasible, as I saw some interaction between MQTT and WAMP being possible.
Re:Why MQTT is better than REST by aramallo on Monday June 11, 2018 @11:00AM (#17284797)
Tomorrow I am presenting Bondy (our OSS WAMP router implementation) in the Riak London Meetup (https://www.meetup.com/riak-london/events/250813756/) and it will be available in Youtube later. As opposed to everything you might have seen, BONDY works in cluster. It is written in Erlang and uses eventual consistency model where data is replicated throughout the cluster using a gossip algorithm (plumtree - epidemic broadcast trees http://asc.di.fct.unl.pt/%7Ejleitao/pdf/srds07-leitao.pdf). Bondy embedds an HTTP/REST API Gateway and will provide an MQTT gateway in the future.
Re:Why MQTT is better than REST by sametmax on Friday June 01, 2018 @08:34AM (#17204679)
WAMP is just websocket, so basically any web load balancer can offer redundancy, like the would do with another web service. I haven't done it, but I'm pretty sure you can spaw 4 crossbar instances, put nginx in the front and it will work.
Re:Why MQTT is better than REST by aramallo on Monday June 11, 2018 @11:08AM (#17284875)
The problem with this approach is that the 4 Crossbar instances will need to have a connection/session with at least an instance of each service you want to have global visibility of. This is because WAMP is a session-based protocol, every peer needs to be connected to a Router in order to interact with other peers. A Router cannot initiate sessions, only clients can.
Re:Why MQTT is better than REST by mromanuk on Thursday May 31, 2018 @03:15PM (#17199180)
Alright kinda of link–baity, but the custom scrolling on the site, is unbearable.
Re:Why MQTT is better than REST by porsager on Thursday May 31, 2018 @03:59PM (#17199648)
It's impossible to scroll at all in Safari 11.1
Re:Why MQTT is better than REST by pwg on Thursday May 31, 2018 @06:57PM (#17201059)
It is also impossible to scroll on desktop Firefox, unless I first turn of CSS style sheets, then it will scroll just fine.
Re:Why MQTT is better than REST by ranjithdsm on Thursday May 31, 2018 @03:25PM (#17199289)
Sorry for the slow loading of the site. This is due to the traffic and slow loading of the site.

Do check the medium link of the post -

https://medium.com/bevywise/mqtt-vs-rest-from-iot-implementa...

Re:Why MQTT is better than REST by trowawee on Thursday May 31, 2018 @03:48PM (#17199532)
I don't really care about the loading, I know that HN traffic can overwhelm sites. The scrolljacking, on the other hand, is infuriating, especially replacing the standard "swipe to go back/forward" with "swipe to go down/up".
Re:Why MQTT is better than REST by meowface on Thursday May 31, 2018 @05:03PM (#17200241)
The issue isn't with the loading but the overridden scrollbar behavior. It's pretty much impossible to scroll smoothly on any of my devices.
Re:Why MQTT is better than REST by mromanuk on Thursday May 31, 2018 @03:28PM (#17199322)
thank you, much better!
Re:Why MQTT is better than REST by gullevek on Thursday May 31, 2018 @11:15PM (#17202333)
The scrolljacking is horrible. Without unblocking cloudflare JS I can't even scroll. This is 100 times more horrible than the usual scroll highjacking. That should be forbidden.
Re:Why MQTT is better than REST by ranjithdsm on Friday June 01, 2018 @01:54AM (#17202912)
Sorry for that experience. We are working on fixing it up. Please read it on MEdium if you are not able to read further - https://medium.com/bevywise/mqtt-vs-rest-from-iot-implementa...
Re:Why MQTT is better than REST by NelsonMinar on Thursday May 31, 2018 @03:20PM (#17199239)
Site's not handling traffic very well, I failed to capture an archive link. Here's a pastebin of the text: https://pastebin.com/raw/XjhNSfTs

Does MQTT have any sort of future? I played with it about six months ago and it felt like a half-baked thing with no momentum.

Re:Why MQTT is better than REST by danesparza on Thursday May 31, 2018 @03:23PM (#17199272)
AWS uses it extensively as part of their IoT platform. https://docs.aws.amazon.com/iot/latest/developerguide/protoc...
Re:Why MQTT is better than REST by ranjithdsm on Thursday May 31, 2018 @03:27PM (#17199315)
Sorry for the slow response of the site due to traffic. Check medium in case it fails - https://medium.com/bevywise/mqtt-vs-rest-from-iot-implementa...

All major providers of Platform supports MQTT and MQTT is going to be most widely used. Most of the current implementations are over REST which will not scale up as the frequency goes up.

interested to know what is the protocol you use today.

Re:Why MQTT is better than REST by travisgriggs on Thursday May 31, 2018 @04:02PM (#17199685)
We use MQTT for IoT type of stuff. I've been really really happy with it vs trying to use REST style stuff. MQTT has TLS support as well. The library is so lightweight that you can run it in a variety of environments. I did have to roll an RPC-over-MQTT convention, but it was pretty straightforward to do.
Re:Why MQTT is better than REST by bb88 on Thursday May 31, 2018 @04:52PM (#17200130)
Mods, can you clarify that this is for IoT?