#Is there a delay in cache invalidation taking effect?

1 messages · Page 1 of 1 (latest)

ionic seal
#

We're on the Pro plan and have recently started using cache invalidation w/ our accelerate queries. We're seeing that queries immediately after cache invalidation are still getting the cached value - is this expected?

Our use-case is that we're storing user data in the cache w/ a sanitized version of the user email as cache tag. When a new user signs-up, they'll originally have a null value in the cache. After we create the user in our DB, we invalidate the cache, but we see that queries still get the null value for 1-2 seconds after invalidation. What is the typical delay for invalidating the cache?

muted charmBOT
#

To help others find answers, you can mark your question as solved via Right click solution message -> Apps -> ✅ Mark Solution

fallow glade
#

Hey @ionic seal 👋

Thanks for reporting. Let me check with our Accelerate team about the delay. In my opinion a certain amount of delay is expected as the invalidation needs to be propagated to all the POPs.

ionic seal
#

Thanks @fallow glade ! From our logs, it looks like this happens for 1-2 seconds. If that is expected, we'll work around it.

fallow glade
#

Hey @ionic seal

I checked with the team and also tested myself. There is a delay of 1-2 seconds for the updated response to come through. At the moment, this is expected. Our team is looking into ways on how we can reduce it further 🙏

ionic seal
#

Got it. Thanks @fallow glade !