pantheon-systems / wp-redis

WordPress Object Cache using Redis.
https://wordpress.org/plugins/wp-redis/
GNU General Public License v2.0
226 stars 68 forks source link

Performance Issue... #362

Open erikdemarco opened 2 years ago

erikdemarco commented 2 years ago

Comparing this plugin with other abandoned wp redis plugin here: https://github.com/pressjitsu/pj-object-cache-red

Profiler: xhprof

Tested data:

$args = array(
    'orderby' => 'rand',
    'return' => 'ids',
    'status' => 'publish',
    'visibility' => 'visible',
    'stock_status' => 'instock',
    'limit' => 100,
);
$data = wc_get_products($args);
Average time for [WP_Object_Cache::get]

Pantheon
403,407 ms

Pressjitsu
163,472 ms (2.5x faster)

The most heavy functions for Pantheon's version is this 2 taking almost 50% of the time: WP_Object_Cache::_isset_internal WP_Object_Cache::_get_internal

Is there anyway we apply similar strategy like Pressjitsu does? Here's the in depth strategy they use: https://web.archive.org/web/20201108140712/https://pressjitsu.com/blog/redis-object-cache-wordpress/

The reason I dont use it anymore is because the project seems abandoned even the main site already down for several weeks

soulseekah commented 2 years ago

Ping pong. Don't forget to credit us once you do this :)

hj-collab commented 1 year ago

Hi @erikdemarco,

Are you still experiencing differential performance? I understand that even the WordPress core has undergone many improvements that should enhance the object caching performance.

Best regards,

batonac commented 2 weeks ago

@hj-collab are you insinuating that the @pressjitsu approach is now irrelevant?