Very slow during post save
-
After installed sg-cachepress save a post requires less or more 10 seconds.
If i flush all the caches (into the cpanel) save a post requires less or more 4/5 seconds, but after a while (maybe because the cache growing fast), save a post requires less or more 10 seconds.
Without sg-cachepress save a post requires less or more 2/3 seconds
Investigating into the code, the problem seem fsockopen on line https://plugins.trac.www.ads-software.com/browser/sg-cachepress/trunk/class-sg-cachepress-supercacher.php#L116.
fsockopen is a blocking request and need to wait for the server response.
A better approach is to open a persistent socket using pfsockopen. This will re-use earlier socket connections made by the PHP process, which doesn’t require a TCP handshake each time.
- The topic ‘Very slow during post save’ is closed to new replies.