Make WordPress Core

Changes between Initial Version and Version 1 of Ticket #54221


Ignore:
Timestamp:
10/05/2021 01:13:40 AM (4 years ago)
Author:
SergeyBiryukov
Comment:

Legend:

Unmodified
Added
Removed
Modified
  • Ticket #54221 – Description

    initial v1  
    11Hi there, folks. After months of perf issues on a fairly large site (10s of millions of monthly PVs), I finally dug in properly and discovered an absolutely massive `_transient_dirsize_cache` option which was set to autoload=yes... currently sitting at 207221 entries worth 20MB of data. That's 20MB every
    22
    3 ```
     3{{{
    44SELECT option_name, option_value FROM wp_options WHERE autoload = 'yes'
    5 ```
     5}}}
    66
    77loads each time. The query takes 1s+ on 32GB RAM 8-CPU db servers.
     
    1515I'm also wondering if shortcircuitting it with
    1616
    17 ```
     17{{{
    1818add_filter( "transient_dirsize_cache", function() {return; } );
    19 ```
     19}}}
    2020
    2121and deleting the transient to avoid such a huge 20MB db entry would have any side effects. Or if it'd be a better idea to disable the cache altogether?