• Remote control • Flexible policy to reduce energy and save money • Be able to communication with 3rd parties • Forecast monthly energy bills • Remote firmware upgrade for device • Remote monitoring and management of entire network
and two public IP addresses to achieve almost Zero downtime. (because passenger restart can be several minutes for big application) • MongoDB is schema less, do not need migrate • Config MongoDB replica sets support auto failover
memory MongoDB: - At least 3 replSet instances for auto failover - Huge difference without index on query (when disk I/O in high load, probably you are querying without index in big collections)
power consumption data reading • Data integrity between cloud server and local devices • Control device behind router • Security • License • Global customers
• Minimize data package in json, e.g: - {"device_serial": "xxx"} -> {"s": "xxx"} • Replica set secondary use for web portal and API - Write on Primary, Read on Secondary - Note there is latency between Primary to Secondary
the network may unstable • Device may powered off sometimes - Local device store data for a month - Background ruby fork job scan data missing, and request data from local device when it become online. - Cron task monitor this process every minute, start it when not exist in processes.
server, it benefit on: - Notify device activity and network activity - Make server be able to send UDP message to device any time • Delayed_job in background for command queue • Retry when no feedback from end device