IoT/OT in Retool and realtime handling

Hi, Everyone.

I'm sure I'm not the only one using Retool for app that has some realtime component to it.
In my case it's a status dashboard of an autonomous catamarans and boats floating in the middle of the ocean doing it's servers.

The way it's built at the moment: boats talk LoRa to Mothership that has a satellite modem that serves Retool this data via restAPI. Works so far.

But at some point real time connectivity would be required for time sensitive decision. And I'd love to see something more elegant than a Node-Red Webhook-Api bridge.

Anybody is tinkering with something alike? Ideas? Suggestions?
Would Retool benefit from IoT/OT functionality?

1 Like

@Scottsky what are you running over LoRa RF inhouse protocol ? or LoRaWAN?
Either way I would be considering an MQTT broker.

If you are running LoRaWAN what LNS are you running?
As all LNS app servers support MQTT either a client or TTN/i as a server.

MQTT.js support web sockets so should be able to run in mobile app.

I use LoRa SX1278 transmitters based radios for clients and CH9102 for bridging.

MQTT is an option I'm looking towards.

Basically my constrains are as follows:

100% of data must be stored. Logged and later transmitted.
Messages are generated once every minute.
Messages are sent via satellite every hour on the hour.

If assuming 100% uptime reliable connection to the aset (and at the moment it's not always the case) I can have some MQTT broker working on a much shorter cycle. I will still need to account for message buffer in case of uplink interruptions.

What are the chances we will see MQTT broker in Retool? =)

Interesting I had a look at doing MQTT in the client and that looks like a non starter.
Also if you search for retool realtime you will find that it's not supported as a concept.
So what ever you message store is DB/MQTT/REDIS your retool app will have to poll.

Now interestingly it seems retool are starting to support http/2 SSE server sent events for postgres. Using SSE fits very well with retool can only hope this is an ongoing and strategic choice to build responsive apps.

I was able to setup a websocket connection with a custom component. i use webhookrelay to basically turn webhooks into a websocket for me. it's rather handy, but the websocket does let you stream realtime data.

<script crossorigin src=""></script>

webSocket = new window.WebSocket('wss://');
webSocket.addEventListener('open', onOpen);
webSocket.addEventListener('message', onMessage);

Thanks for the share not herd of webhookrelay.
I'm using retool mobile and felt wss was worth a try.