WeamonZW
Convex Community8mo ago
328 replies
WeamonZ

Caching system failure.

I already mentioned some of these issues in this GitHub post, but I’ll go into more detail here.

I've spent days trying to debug Convex's caching behavior, and at this point, it seems increasingly likely that the problems aren't coming from my end.

There are multiple issues with the caching system, including:

* Paginated query caching only working sporadically — sometimes it only works once every few days.
* Auth sessions refreshing too frequently, which seems to unnecessarily invalidate queries. According to the documentation, refreshes should happen every hour, but as shown in the screenshot, one occurred after just 40 minutes. (It even refreshed the authRefreshTokens >2000 times in less than a month. Even tho the tokens are not expired).
* Queries getting invalidated without any mutations. As you can see, nothing in the app has changed, yet almost every query is being re-run.
* Table updates invalidate all queries referencing that table, even if the updated field isn't part of the query result.

This makes it really hard to rely on the caching layer to reduce bandwidth or improve performance — especially in production scenarios.
image.png
GitHub
The open-source reactive database for app developers - Issues · get-convex/convex-backend
Issues · get-convex/convex-backend
Was this page helpful?