Building Hasura: Instant realtime, high-performance GraphQL on Postgres
Submitted by Tanmai Gopal (@tanmaigo) on Thursday, 19 July 2018
Hasura is an open-source engine that gives developers instant GraphQL on a new or existing Postgres database. This GraphQL server can handle upwards of a 1000 requests per second, even for deeply nested queries, with an extremely low resource footprint of 50-60MB of RAM.
Hasura does this by taking a unique approach of compiling GraphQL queries instead of resolving them. This results in huge-performance benefits.
In this talk, I’ll touch upon the design of the system, the structure of the GraphQL query and Postgres optimizations that can be leveraged and share other engineering learnings as we built Hasura.
- Brief introduction to GraphQL
- Why Postgres and GraphQL go well together
- Designing GraphQL query syntax
- Preventing n+1 queries
- Handling authorization
- Postgres optimisations to speed up GraphQL query execution
Tanmai is the co-founder of hasura.io. He is a StackOverflow powered fullstack, polyglot developer whose areas of interest and work span react, nodejs, python, haskell, docker, postgres, kubernetes. He is passionate about making the power of building things accessible to everyone and is the instructor of India’s largest MOOC imad.tech with over 250,000 students.
You will occasionally see him speaking, or more often being quietly awkward, at conferences and meetups. He has recently moved to the Bay Area and Bangalore, just like everyone else.