I want to use aws lambda for creating a REST interface. As a database I have chosen RDS (presumably using MySQL), since my Data is highly relational and write intensive.
In the past I have used Django for Web backends, which I really liked. Theres a feature in particular that I am really missing for lambda, which is automatic Object generation and validation. Basically what this means is that Django can automatically generate MySQL schemas from a simple Python object and even validate User input. It also makes atomic transactions really easy.
Is there a similar functionality in Django? Basically a way to set some basic paramters like max length for a string, only positive numbers, etc, and create objects using standard JSON/Python objects?
The programming language can either be js or python.
1 Answer
I was looking for sequelize. Protipp: check out sequelize auto migrations, it can be found on https://sequelize.org/. It allows the creation of SQL relational data schemas within JS. One problem is, is that migration need to either be written manually, or the SQL shema be created before deployment. This can be solved by sequelize auto migrations, which will generate and run migration simply by looking at your models.