Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

> Checkout Relay.js: https://relay.dev/

Relay is a GraphQL client. That's the irrelevant side of caching, because that can be trivially implemented by an intern, specially given GraphQL's official copout of caching based on primary keys [1], and doesn't have any meaningful impact on the client's resources.

The relevant side of caching is server-side caching: the bits of your system that allow it to fulfill results while skipping the expensive bits, like having to hit the database. This is what really matters both in terms of operational costs and performance, and this is what GraphQL fails to deliver.

[1] https://graphql.org/learn/caching/



https://relay.dev/docs/principles-and-architecture/thinking-...

Take a look at this. Either you didn't know what's challenging about caching nested graph data, or we have different definitions of triviality/interns.


> Take a look at this.

I repeat: client-side caching is not a problem, even with GraphQL.

The technical problems regarding GraphQL's blockers to caching lies in server-side caching.

For server-side caching, the only answer that GraphQL offers is to use primary keys, hand-wave a lot, and hope that your GraphQL implementation did some sort of optimization to handle that corner case by caching results.

Don't take my word for it. It's really that bad.

https://graphql.org/learn/caching/




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: