On this question, several approaches are possible:
- Deploy servers and their applications.
- Use Kubernetes-type orchestrators to simplify infrastructure deployment and administration.
- Use clouds providers and their managed services
Depending on the needs, use cases and constraints (Financial, Legal, Technical, Human), the choices may be different.
In my last realization, the choice fell on the use of managed service for reasons of speed, simplicity and cost.
#API
The API created makes it possible to retrieve data collected by #IoT sensors.
The main functions requested from this API:
- Secure communication (HTTPS)
- User authentication (secure password management, recovery)
- Management of objects, identities: Creation, Reading, Update
- Retrieval and export of measured data:
- Live (JSON)
- Delayed by sending a e-mail with a download link of an export.
The solution has been realized with AWS, without the installation of a single server !
As a bonus, it’s Scalable, Secure and Efficient !
In this case, the use of the API being moderate, it is economical compared to renting virtualized instances.
API Architecture
We use several services:
- API Gateway : Route HTTPS requests to the correct resources , linked with Cognito authentication.
- Cognito : Manages the identity of clients (Authentication) : this allows you to have an interface for creating, logging in and recovering the password without development. In addition, no risk of corruption of customer passwords, they are never stored in the customer’s data.
- The Lambda Functions: The Serverless Core
- This is where Serverless comes into its own, the only code of the application is written in these functions (in Python or Javascript) which allows formatting, processing data, using other services.
- These functions are called by the API Gateway, or triggered by other services, we define only the usable memory, and we pay by the time of use.
It’s not magic, but it allows you to avoid maintaining servers for periodic use, and if the load is heavy, you can run several processes at the same time.
Other services in this API are:
- S3: For storing and processing files.
- DynamoDB: A No SQL database for storing administrative data..
- TimeStream: a Timeserie database for IoT data.
- SES: To manage the sending of secure Mail to end customers .
Conclusion
This is just an example with #AWS services, it is possible to do the same thing with other providers.
With modern tools, it is now possible to create long-lasting and efficient solutions while controlling costs.
If you need assistance and implementation on your #Cloud #Iot architectures,
#Cloud #Serverless #backend #AWS #API #Iot