Open aaltonja opened 8 months ago
Comment from Jeremy: Vegard might provide some information for this
It seems that the APISIX caches consumers when the key-auth plugin is run for the first time. It creates a simple lru-cache for 512 items for 5mins The secrets are cached here https://github.com/apache/apisix/blob/987d33d168761afd9e125ad0f7caadfef21f0bb7/apisix/secret.lua#L248 And a second time when the consumers are cached here https://github.com/apache/apisix/blob/987d33d168761afd9e125ad0f7caadfef21f0bb7/apisix/consumer.lua#L116
local lrucache = core.lrucache.new({
ttl = 300, count = 512
})
Apisix should respect cache-control header coming from upstream.
Discussed that we might need to implement centralised caching in APISIX. This requires co-working with data providers to understand what data and for how long it can be cached.