Benefit of ODM
- ODM provides us a framework to translate between objects in the backend code to the relational representation of data. It is easier for developers to manage data in the backend.
- Classes (Models) are mapping to the database entities. It provides us a framework to do object oriental programming.
- We can decouple the Class method with APIs. So the class methods are reusable in different APIs.
Design Diagram
Next Step:
- Use flask-mongoengine for ODM control, enable the dataflow from localhost backend to local/online database.
- Implement Models and APIs for existed functionalities
- Create unit-tests for both APIs and class methods