Caching for tag topic lists?

Are tag routes like /tag/featured.json route supposed to be cached? It appears to be running 29 SQL queries for every page view, but this tag has a very low update frequency. As I’m on a crusade to reduce CPU load on our server it would be great if I could set it to cache for 10 minutes or so (or even better: cache until we apply this tag to a new topic).

1 Like

Is this question related to the topic list thumbnails component, or can we move it elsewhere?

29 SQL queries does not sound too unusual. We do have whole-page caching, but it only applies for anonymous users, not signed-in users. We can’t easily cache topic lists for signed-in users because every user is shown different information based on their group membership, preferences, read state, etc.

2 Likes

Sorry, I ran into it in the context of Homepage Feature Component TC, not this one :facepalm: It’s probably better as a stand-alone topic yes.

1 Like

:+1: moved

Ah I see, so this tag/featured.json request is being made every time someone views your homepage.

Unfortunately we don’t have any way for theme components to modify the data sent in the real homepage request, so that’s why the Homepage Feature Component has to make a separate HTTP request.

2 Likes

Well, the request is fine, it would just be great if it used the anonymous version (this list is/should be the same for everyone).

Tangentially related: I’m trying to get this to list the tags by tagging date and not by ‘last updated/replied’ date as this is throwing off the order of my featured topics. I’ll try hacking some external static JSON for that and see how it goes.

1 Like