3 ms·
We are running Erlang/OTP for telemetry backend in the industrial automation field. Basically, we have hundreds of thousands sensors connected through gateways
by datetime 3y ago
We are running Erlang/OTP for telemetry backend in the industrial automation field.
Basically, we have hundreds of thousands sensors connected through gateways that keep open TCP/IP connections to the Erlang/OTP distributed backend. We do bidirectional communication as we have many control functions, OTA firmware updates, etc.
There are frequent failures which we handle with supervision trees and “let it fail” design principles. Failures are due to:
* Gateways which are connected through cellular networks with varying signal strength conditions.
* Sensors failing and providing incorrect data (eg. invalid float binaries).
* Buggy firmware in some 3rd party gateways / sensors.
* Buggy firmware in our own gateways and sensors ;-)
I highly recommend Elrang/OTP due to:
* Fault tolerance - processes fail, nodes carry on.
* Concurrency model (mailboxes, linking processes via supervision trees, monitors, trapping, etc)
* Built-in distribution and related modules in standard library
* Pattern matching which makes processing binary data super convenient
* Mnesia database (if used for right things)