Meeting the Challenge
DataArt has been closely collaborating with the client’s IT team to build and support the cloud based smart home platform and provide professional development services and ongoing support of the cloud platform and the web and mobile user interfaces.
The cloud platform was implemented as a set of micro components. Each component addresses only one part of the whole functionality, but does it well. It provides metrics that can be used for live monitoring and further analysis. The microservice approach made scaling the platform for load increases simple and also made continuous delivery possible.
The underlying communication with hubs — transmitting devices installed in customer homes — is implemented via encrypted AMQP (Advanced Message Queuing Protocol) using RabbitMQ as the message broker. Upstream messages are sent to edge servers, where they are routed to multiple destinations as required. The current states of the devices update snapshots in Hazelcast cluster. Information about registration is stored in a MySQL database. Sensor data is recorded in long-term storage that is backed up by a Cassandra cluster. Most of the information is also mirrored to a Kafka message bus for further analysis. Events that require actions from the platform are routed to other components via the RabbitMQ bus.
The public facing part of the platform consists of public and engineering web APIs and notification sending components. The web API is used by public and administration web-sites, clients for all well-known mobile platform and voice recognition systems. The flexibility of the microservice approach offered the ability to easily extend email and SMS notifications with more convenient push notifications.
All components are provisioned automatically with Ruby AWS SDK. For some components blue-green deployment pipelines (2 independent production environments, at any time only 1 environment is live) were developed, which made it possible to release updates with zero downtime. Functional and performance characteristics and logs are gathered in an ELK cluster that simplified the monitoring and troubleshooting.
