Caching paginated results, purging on update - how to solve?

前端 未结 8 961
忘掉有多难
忘掉有多难 2021-02-04 18:08

I\'ve created a forum, and we\'re implementing an apc and memcache caching solution to save the database some work.

I started implementing the cache layer with keys like

8条回答
  •  礼貌的吻别
    2021-02-04 18:43

    flungabunga: Your solution is very close to what I'm looking for. The only thing keeping me from doing this is having to store the relationships in memcache after each request and loading them back.

    I'm not sure how much of a performance hit this would mean, but it seems a little inefficient. I will do some tests and see how it pans out. Thank you for a structured suggestion (and some code to show for it, thanks!).

提交回复
热议问题