vsurabhi
We've been working on SQL server native support and we're happy to announce support for read-only GraphQL cases with new or existing SQL Servers.
Next up is adding support for stored procedures, mutations, Hasura event triggers [1] and more!
[1]: https://hasura.io/docs/latest/graphql/core/event-triggers/in...
Clodl: Turn dynamically linked ELF binaries into self-contained closures
Building a GraphQL to SQL Compiler on Postgres, MS SQL and MySQL
Hasura 2.0 Engineering Overview
Rust Async vs. Linux threads: context switch time and memory usage
Facebook should be treated as co-accused in riots: Delhi govt. panel
New AMD Ryzen 3000XT Processors Available Today
The UChicago χ-Projects
Show HN: Hasura Cloud: Managed GraphQL for your database and services
Jim: An open-source, small footprint implementation of Tcl
Build Your Own Text Editor
Court says Melbourne dentist can seek user details from Google over bad review
A Small and Simple Pen Plotter
gc: A garbage collector for C and C++
Lnav: Watch and analyze your log files from a terminal
Osquery: SQL-powered operating system instrumentation, monitoring, and analytics
OpenDrop: An Open Source AirDrop Implementation
> .. caching .. This is related to GraphQL in general. The support for caching is nowhere close to what is possible with RESTful APIs but it should eventually get there.
One of the main reasons why this is possible with Hasura and not possible with say Graphcool is the abstraction which Hasura provides. Hasura is not a black box which lets you do CRUD operations. It is a tool that adds powerful GraphQL APIs on top of Postgres, i.e, it works with any Postgres database, existing or new, no restrictions whatsoever. This means you are free to write your own code (and encouraged to) which speaks to Postgres directly with your favorite ORM and expose these APIs with "schema stitching" alongside Hasura.
Hasura therefore lessens the work of a GraphQL backend developer: use Hasura's GraphQL APIs when they fit your bill and write your own custom logic when needed as you would have done without Hasura.
In fact Hasura is a superset of Prisma when it comes to Postgres, you can also use Hasura as an ORM if you want to.
Disclosure: I work at Hasura on graphql-engine
Thanks for the feedback. We thought that the 'BaaS' part would convey it.
> .. small datamodel to a very complete GraphQL types ..
Given any GraphQL server, you can generate the types/functions (using introspection) to access the GraphQL server in a typesafe/idiomatic way for a language. A project which does this: https://github.com/dotansimha/graphql-code-generator.
The biggest challenge is access control which we have modeled based on Postgres's RLS but for application users and roles.
Hasura is meant to be exposed to the clients directly with declarative access control rules. When you have complex business logic you would write the logic yourselves and expose it alongside Hasura.
Disclosure: I work at Hasura on graphql-engine
The primary difference is how authorization is handled. In Postgraphile, you map your application roles to Postgres users and define policies using Postgres's RLS. With Hasura, you define rules on roles (similar to Postgres's RLS) but it integrates into your existing auth system using webhooks.
You can write fairly complex rules with the access control layer ! The first two conditions are possible (except for the project is only visible on Mondays).
allow select on rows which satisfy this property:
{ "project_type" : { "_eq" : "whatever" } }
allow update on rows which satisfy this property:
{ "closed_data" : { "_is_null" : true } }
The idea is simple, we provide a boolean expression based access control layer which can use variables from headers. When you can't specify it using the access control layer, you can write this in your own graphql layer and schema stitch with hasura. So you only have to write what is not possible with the access control layer.> The other point I don't see is how do you ...
You can use the tooling around Postgres ! You can create an `ON INSERT` trigger on the table and listen to these events.
We're launching something very cool in the subscriptions/event-source to solve these kinds of problems. We also have 2 nice projects that work independent of the graphql-engine to help with change subscription on postgres (skor[1], pgdeltastream[2])
[1] https://github.com/hasura/skor [2] https://github.com/hasura/pgdeltastream
Hasura and Prisma have very different approaches and end-goals at the moment.
TL;DR: Very simply put, Hasura is postgres first and adds an access-control layer to make it possible to query from the front end directly.
The longer version:
Prisma is intended to be a GraphQL ORM to Postgres (and several other databases with a common API) whereas Hasura is more database first and intended to let you leverage Postgres features over GraphQL.
Hasura comes with and lets you use any postgres migration system and then gives you GraphQL on top of it. This is what allows Hasura to give you GraphQL over any existing Postgres database and application even.
Hasura also comes with an optional access-control layer that makes it feasible to be used by frontend clients directly. This access control is inspired from postgres's RLS but does not depend on or use postgres RLS and can be coupled with application logic/auth.