Replies: 1 comment 1 reply
-
Hey @tohagan , thanks for sharing. I understand your concern here. This is still early to predict as there aren't any pricing plans publicly available for neon (till date). Though, I have taken this as feedback and have escalated to respective stakeholders. We will keep you updated about the polling cost issue and more updates on this GH discussion. |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
I'm an Hasura novice but last time I looked you used internal query polling when a client performs a GraphQL subscription. Still true?
As you move to support serverless databases like Neon that will charge per query or transaction, polling then becomes a significant cost factor that can end up shaping your whole application archiecture to (where possible) avoid subscriptions! This in turn (rather sadly) means you might miss out on applying nice a pure real-time architectural pattern whereby an application developer can just push updates via GraphQL and rely soley on fast subscription responses to pull the state change back and reflect it in the user interface. As a developer, for each SPA app view, you just setup subscriptions at the start and then only care about sending updates. Client side code become trivial and tiny.
This pattern is feasible with say Firebase's RTDB & Firestore databases mainly because you don't pay a polling cost and because the update and pull can be done immediately client side via a client cache that may later rollback if the transaction fails. It can also work when temporarily offine. All this make the UX very snappy, very cheap to run and reduces developer code. The downside of course is that's not Postgres or relational and queries are rather restricted ... enter Hasura and Neon!
So a dream I have for the Neon / Hasura partnership is that you can collaboratively solve this polling cost issue. That would mean Neon would have to support real-time streaming queries and Hasura leverage them in GraphQL subscriptions. Then hopefully we can use use a smart GraphQL client to do caching & subscription tricks for fast UX and temporary offline support.
Beta Was this translation helpful? Give feedback.
All reactions