Skip to content

Add simple GET based caching option #85

@jimmythomson

Description

@jimmythomson

The response to GET requests for products, product projections, categories, product types, stores etc. should all be safely cacheable. Other GET requests such as when getting the cart, or the customer's profile, should never be cached.

We should look at implementing a basic cache allowing the user to opt in to caching various resource types through configuration options. Suggest to use node-cache as the caching engine.

There's 2 key pieces of analysis here:

  1. Identify the resources which can reasonably be cached
  2. Determine a clear and flexible way of configuring the caching options

Note: only GET requests can be cached, and should always be keyed on the auth token and all query params, so as to ensure that customer data is never leaked to another customer.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions