@matters/apollo-server-plugin-response-cache
v0.3.6
Published
Apollo Server full query response cache. Forked from https://github.com/apollographql/apollo-server, with cache key injected to context.
Downloads
3
Keywords
Readme
Response Cache plugin
This Apollo server plugin implements a full GraphQL query response cache.
- Add the plugin to your ApolloServer's plugins list
- Set
@cacheControl
hints on your schema or callinfo.cacheControl.setCacheHint
in your resolvers - If the entire GraphQL response is covered by cache hints with non-zero maxAge, the whole response will be cached.
This cache is a full query cache: cached responses are only used for identical requests.