2021-01-21

Data layer development via ORM and API Gateway

Not sure what pushed me to this direction but search "DB with graphql" lead to https://www.prisma.io/ - a tool for auto-generation GraphQL endpoints for DB schemas without programming. Open Surce, Apache 2 licence, MySQL/PostgreSQL capable.

Prisma is a next-generation ORM that can be used to build GraphQL servers, REST APIs, microservices & more. (222 kB)

For me DB-first approach is essential . The schema change is reflected in code just by re-generating code by CLI, no coding involved. Of course the discipline of migration for DB schema itself is still in place.


And last peace of back-end puzzle: ORM integration with API gateway( will serve security, authentication, licensing, analytics ) : Prisma + Apollo https://www.howtographql.com/graphql-js/5-connecting-s
erver-and-database/

The generated classes out of DB schema could(and should) be reused as on back-end as in front-end code via versioned (npm?) package.