StarpTech / apollo-datasource-http

Optimized JSON HTTP Data Source for Apollo Server
MIT License
73 stars 32 forks source link

[Proposal] Make the maxTtlIfError optional #43

Open kdybicz opened 2 years ago

kdybicz commented 2 years ago

In some of the case we might not need or event want the maxTtlIfError to work, it would be nice if we could omit it in the configuration and thus make sure it's not used by the code.

The temporary workaround might be using same ttl value for both maxTtlIfError and maxTtl, but this is just wasting the cache memory.

StarpTech commented 2 years ago

Hi, I am open to a PR that makes this option configurable globally and per request.