race condition on cache expiration
-
Hi,
I have a high traffic website, some of the pages are extremely popular with more than 100 people online on the same page.When the cache of theses popular pages expire (due to updating the page or adding a comment or etc) suddenly a race condition happens, 100 requests is sent to the server asking for one page which has no cached version and the server is trying to create it, while the server is trying to generate the page more and more requests are sent to the server asking for the same page, after a few second we can see in our graphs that 100 or more threads are connected to mysql and making it harder and harder for mysql to answer the queries, this race condition increases the CPU usage and system load and people start to get 504 errors as they reach the 30 second time out.
So what solution w3tc offers for such conditions?
I use page cache + object cache + database cache and all of them are stored in APC.
- The topic ‘race condition on cache expiration’ is closed to new replies.