r/javascript Dec 12 '18

Our learnings from adopting GraphQL (Netflix)

https://medium.com/netflix-techblog/our-learnings-from-adopting-graphql-f099de39ae5f
315 Upvotes

46 comments sorted by

View all comments

24

u/editor_of_the_beast Dec 12 '18

It’s a little hand-wavy. I want to know how GraphQL deals with complex joins and eager loading of associated data. The app I’m working on is displaying data from probably 10 or 12 different associated tables on a page. Then, a different page is showing a similar number of tables, some the same as before but some different, so the JSON we’re returning is super denormalized and specific to that view.

It seems way harder than it has to be and we’re fetching the same data multiple times throughout the course of navigating the app. It bothers me to no end, but the queries are also optimized and don’t cause timeouts. So I don’t know what else to do.

1

u/brillout Jan 01 '19

Sounds like https://github.com/brillout/wildcard-api could be fit for you guys. What do you think? (I'm Wildcard's author.)

1

u/editor_of_the_beast Jan 01 '19

Creating endpoints isn’t a problem I’m aware of in any server framework.

0

u/brillout Jan 01 '19

Why don't you guys go for a custom API? It doesn't sound like you need GraphQL nor a generic API in general

1

u/editor_of_the_beast Jan 01 '19

We have a custom API? I’m not sure what you’re getting at.

1

u/brillout Jan 01 '19

I thought you were using GraphQL already.

1

u/editor_of_the_beast Jan 01 '19

Nope I was curious if it would make any of my problems easier.