2
gvnix
14d

Started learning/using graphQL for my personal project and it’s really interesting! It solves my major concern of huge json response

Comments
  • 4
    It trades transport and client parsing load for server load, and it isnt a fair exchange: the server gets a much worse deal.

    So while it feels amazing and makes your life easier on the frontend, use it with caution and keep scaling in mind.
  • 2
    @Root that’s always true. You can have your cake and eat it too. But sometimes you have downstream systems not necessarily UI that will incur performance penalties per response because your payload was huge.

    Some one has to sacrifice their cpu cycles. So it’s better than one system does than 20 others.
  • 1
    I've used it for two projects now and it definitely comes with its pitfalls, but I still prefer it over rest - depending on the data model.

    If you are on dotnet, check out hot chocolate. It takes care of a *lot* for you while still allowing you granular control like usual. Out of the box you can just hand it your EF dbcontext, and when you ask for a deep nested query it manages to write it as a join instead of ending up with a foreach lookup.
  • 0
    Does it work well with SQL databases ?
  • 0
    I'll take another look at hot chocolate, last time I couldn't find a production ready example and ended up inventing some way to represent large schemas which is...not ideal.
Add Comment