Redis Object Cache Pro By ObjectCache

Redis Object Cache Pro By ObjectCache v1.17.0 Nulled

No permission to download

danielli

Member
Mar 29, 2020
200
21
18
define( 'WP_REDIS_CONFIG', [ 'token' => '@Y:R;Vl^W9wCX[;,6s]aSF2XY-pyJaj%@7S9-kf@U)HZ^5Tr)A*F9hDjoFl5', 'host' => '127.0.0.1', 'port' => 6379, 'database' => 0, 'maxttl' => 3600 * 24 * 7, 'timeout' => 1.0, 'read_timeout' => 1.0, 'retry_interval' => 300, 'retries' => 5, 'split_alloptions' => true, 'debug' => false, ]); define('WP_REDIS_DISABLED', false);

Use this, so far running smoothly
By the way, we have Server resource as:

8 GB Memory / 4 AMD vCPUs / 160 GB Disk

so, any suggestion on setting tuning, please?

Thanks
 

Ighalo87

Active member
Jan 18, 2020
400
52
28
  • Object Cache Pro requires the `redis` PHP extension. The PhpRedis extension is not loaded in this environment (fpm-fcgi). If it was installed, be sure to load the extension in your php.ini and to restart your PHP and web server processes.
 

Ighalo87

Active member
Jan 18, 2020
400
52
28
the answer is a bit confusing, do you have hosting or do you have SSH access to your server? it looks like your configuration is not accepted by the server, likely the redis has been modified on the server end as your setup configuration is not being accepted
i used the plugin on a VPS hosting server with hestiaCP installed but still get some errors
 

umart

Member
May 18, 2022
52
15
8
i used the plugin on a VPS hosting server with hestiaCP installed but still get some errors
I also run my WordPress sites with HestiaCP. Here is how I fixed it.
After installing redis with;
sudo apt install redis-server

You need to install php-redis. In my HetiaCP, i use both PHP7.4 and PHP8.0 so i run;
sudo apt install php7.4-redis
sudo apt install php8.0-redis

Next, I edit my redis.conf;
sudo nano /etc/redis/redis.conf

For me I didn't change my maxmemory but I changed my;
maxmemory-policy allkeys-lru

Next you will need to decide whether or not you want to add password (in my case I added password) but If you don't know what you're doing just ignore the password and just update maxmemory-policy.
 
  • Like
Reactions: DATANET

umart

Member
May 18, 2022
52
15
8
It looks like this is the go-to plugin now. First it was Cloudways and now it GoDaddy. Am glad I got to use it myself. Am really happy about the results.
 

simplysexyboy

Well-known member
Trusted Uploader
Oct 24, 2020
552
623
93
U.S.A
Anything from Godaddy is for me 🤮
I don't use any hosting provider either. I have just seen some topics on Wordpress Redis Object Cache. I am thinking of making a benchmark test with both a pro and free plugin with my current setup, so I can see if there is a difference. My all sites are very fast and all of them use WooCommerce. My current setup is Nginx - Fastcgi Cache, Php 8.0 + Opcache, and Redis 7 + Redis Object Cache. If the benchmark is good, then I may no longer use Fastcgi Cache for page caching. Maybe I will move to Redis for both database and page caching, who knows
 
  • Like
Reactions: Lalo

simplysexyboy

Well-known member
Trusted Uploader
Oct 24, 2020
552
623
93
U.S.A
It looks like this is the go-to plugin now. First it was Cloudways and now it GoDaddy. Am glad I got to use it myself. Am really happy about the results.

Please put your benchmark results. If it's okay for everyone, please share your current setup and benchmarks.
 

Lalo

Well-known member
Trusted Seller
Aug 25, 2018
966
681
113
I don't use any hosting provider either. I have just seen some topics on Wordpress Redis Object Cache. I am thinking of making a benchmark test with both a pro and free plugin with my current setup, so I can see if there is a difference. My all sites are very fast and all of them use WooCommerce. My current setup is Nginx - Fastcgi Cache, Php 8.0 + Opcache, and Redis 7 + Redis Object Cache. If the benchmark is good, then I may no longer use Fastcgi Cache for page caching. Maybe I will move to Redis for both database and page caching, who knows
Nice.
At the current time, I use mostly lightspeed servers, but I have some with Nginx, like cloudways, using the free version of Redis and Vulture really gives extra speed.

The bottom line if you structure your website with bloated builders and code! damn none of these plugins cache, speed, or performance, will help you.
 

simplysexyboy

Well-known member
Trusted Uploader
Oct 24, 2020
552
623
93
U.S.A
Nice.
At the current time, I use mostly lightspeed servers, but I have some with Nginx, like cloudways, using the free version of Redis and Vulture really gives extra speed.

The bottom line if you structure your website with bloated builders and code! damn none of these plugins cache, speed, or performance, will help you.

You are correct. However, I can say that if using Nginx fastcgi page caching, there will not be much of a problem even when using Elementor (unless it's a checkout page, then it will start to become slow or a non-cached page).
 
  • Like
Reactions: Lalo

umart

Member
May 18, 2022
52
15
8
You are correct. However, I can say that if using Nginx fastcgi page caching, there will not be much of a problem even when using Elementor (unless it's a checkout page, then it will start to become slow or a non-cached page).
I run Ngnix + PHP-FPM with FastCGI and I use CloudFlare but strangely my fastCGI seems to be x-fastcgi-cahe: MISS everyday even after setting my Cache expiration to 30d. I also have a 24GB ram.

Whats the maximum Cache Expiration you would recommend? My pages barely update. They can be un-updated for months.
 

simplysexyboy

Well-known member
Trusted Uploader
Oct 24, 2020
552
623
93
U.S.A
I run Ngnix + PHP-FPM with FastCGI and I use CloudFlare but strangely my fastCGI seems to be Cache Status: Miss everyday even after setting my Cache expiration to 30d. I also have a 24GB ram.

Whats the maximum Cache Expiration you would recommend? My pages barely update. They can be un-updated for months.

If it's a blog, you can use a 30-day cache expiration. If it's a WooCommerce site, I use 1 hour cache expiration. The cache expiration could be something that triggers the fastcgi nginx configuration to not cache this time. It's recommended to add an expiration reason to help with debugging and understanding.

This is my custom Fastcgi cache exclusion code. I wrote it myself, not like the same generic config files found on the internet or on Github.

Attached is a screenshot of what it looks like on Chrome DevTools.

Code:
############################################
## NGINX FASTCGU CACGE EXCLUSION SETTINGS ##
############################################

###########
## IDK   ##
###########
set $cache_uri $request_uri;
set $cache_inc_uri $cache_uri;

##########################
## Set cache default NO ##
##########################
set $skip_cache 0;

######################################
## Set reason of the skipping cache ##
######################################
set $skip_cache_reason "";

########################################
## Default query should not be cached ##
########################################
if ($query_string != "") {
        set $skip_cache 1;
        set $skip_cache_reason "Query String Is Not Empty: $query_string";
}

##################################################################################################################################################################
## Ignore query string,Page cache will be served when all query strings on the current page are in the list of ignored query strings SPECIALIZED FOR PAID MEDIA ##
##################################################################################################################################################################
###################
#  UTM Tracking  ##
###################
if ($cache_uri ~ (.*)(&|\?)utm_id(?:=[^&]*&?|&|$)(.*)) {
      set $cache_uri $1$2$3;
}
if ($cache_uri ~ (.*)(&|\?)utm_term(?:=[^&]*&?|&|$)(.*)) {
      set $cache_uri $1$2$3;
}
if ($cache_uri ~ (.*)(&|\?)utm_content(?:=[^&]*&?|&|$)(.*)) {
      set $cache_uri $1$2$3;
}
if ($cache_uri ~ (.*)(&|\?)utm_source(?:=[^&]*&?|&|$)(.*)) {
      set $cache_uri $1$2$3;
}
if ($cache_uri ~ (.*)(&|\?)utm_medium(?:=[^&]*&?|&|$)(.*)) {
      set $cache_uri $1$2$3;
}
if ($cache_uri ~ (.*)(&|\?)utm_campaign(?:=[^&]*&?|&|$)(.*)) {
      set $cache_uri $1$2$3;
}
if ($cache_uri ~ (.*)(&|\?)utm_expid(?:=[^&]*&?|&|$)(.*)) {
      set $cache_uri $1$2$3;
}

#################
# FACEBOOK Paid #
#################
if ($cache_uri ~ (.*)(&|\?)fb_action_ids(?:=[^&]*&?|&|$)(.*)) {
      set $cache_uri $1$2$3;
}
if ($cache_uri ~ (.*)(&|\?)fb_action_types(?:=[^&]*&?|&|$)(.*)) {
      set $cache_uri $1$2$3;
}
if ($cache_uri ~ (.*)(&|\?)fb_source(?:=[^&]*&?|&|$)(.*)) {
      set $cache_uri $1$2$3;
}
if ($cache_uri ~ (.*)(&|\?)fbclid(?:=[^&]*&?|&|$)(.*)) {
      set $cache_uri $1$2$3;
}
if ($cache_uri ~ (.*)(&|\?)fbadid(?:=[^&]*&?|&|$)(.*)) {
      set $cache_uri $1$2$3;
}
if ($cache_uri ~ (.*)(&|\?)placement(?:=[^&]*&?|&|$)(.*)) {
      set $cache_uri $1$2$3;
}

###############
# GOOGLE Paid #
###############
if ($cache_uri ~ (.*)(&|\?)gclid(?:=[^&]*&?|&|$)(.*)) {
      set $cache_uri $1$2$3;
}
if ($cache_uri ~ (.*)(&|\?)_ga(?:=[^&]*&?|&|$)(.*)) {
      set $cache_uri $1$2$3;
}
if ($cache_uri ~ (.*)(&|\?)_gl(?:=[^&]*&?|&|$)(.*)) {
      set $cache_uri $1$2$3;
}
if ($cache_uri ~ (.*)(&|\?)campaignid(?:=[^&]*&?|&|$)(.*)) {
      set $cache_uri $1$2$3;
}
if ($cache_uri ~ (.*)(&|\?)gadid(?:=[^&]*&?|&|$)(.*)) {
      set $cache_uri $1$2$3;
}

##################
# MICROSOFT Paid #
##################
if ($cache_uri ~ (.*)(&|\?)msclkid(?:=[^&]*&?|&|$)(.*)) {
      set $cache_uri $1$2$3;
}
if ($cache_uri ~ (.*)(&|\?)bingid(?:=[^&]*&?|&|$)(.*)) {
      set $cache_uri $1$2$3;
}

###############
# TIKTOK Paid #
###############
if ($cache_uri ~ (.*)(&|\?)ttadid(?:=[^&]*&?|&|$)(.*)) {
      set $cache_uri $1$2$3;
}

##################
# PINTEREST Paid #
##################
if ($cache_uri ~ (.*)(&|\?)padid(?:=[^&]*&?|&|$)(.*)) {
      set $cache_uri $1$2$3;
}

##########
# OTHERS #
##########
if ($cache_uri ~ (.*)(&|\?)age-verified(?:=[^&]*&?|&|$)(.*)) {
      set $cache_uri $1$2$3;
}
if ($cache_uri ~ (.*)(&|\?)ao_noptimize(?:=[^&]*&?|&|$)(.*)) {
      set $cache_uri $1$2$3;
}
if ($cache_uri ~ (.*)(&|\?)usqp(?:=[^&]*&?|&|$)(.*)) {
      set $cache_uri $1$2$3;
}
if ($cache_uri ~ (.*)(&|\?)cn-reloaded(?:=[^&]*&?|&|$)(.*)) {
      set $cache_uri $1$2$3;
}
if ($cache_uri ~ (.*)(&|\?)adgroupid(?:=[^&]*&?|&|$)(.*)) {
      set $cache_uri $1$2$3;
}
if ($cache_uri ~ (.*)(&|\?)adid(?:=[^&]*&?|&|$)(.*)) {
      set $cache_uri $1$2$3;
}
if ($cache_uri ~ (.*)(&|\?)gbraid(?:=[^&]*&?|&|$)(.*)) {
      set $cache_uri $1$2$3;
}
if ($cache_uri ~ (.*)(&|\?)wbraid(?:=[^&]*&?|&|$)(.*)) {
      set $cache_uri $1$2$3;
}
if ($cache_uri ~ (.*)(&|\?)gclsrc(?:=[^&]*&?|&|$)(.*)) {
      set $cache_uri $1$2$3;
}
if ($cache_uri ~ (.*)(&|\?)epik(?:=[^&]*&?|&|$)(.*)) {
      set $cache_uri $1$2$3;
}
if ($cache_uri ~ (.*)(&|\?)pp(?:=[^&]*&?|&|$)(.*)) {
      set $cache_uri $1$2$3;
}
if ($cache_uri ~ (.*)&$) {
      set $cache_uri $1;
}
if ($cache_uri ~ (.*)\?$) {
       set $cache_uri $1;
}
if ($cache_uri !~ ([^\?]+)(\?.*)) {
      set $skip_cache 0;
      set $skip_cache_reason "NOT BYPASS";
}
#########################################     FINISHED     ############################################################################
## Ignore query string,Page cache will be served when all query strings on the current page are in the list of ignored query strings###
#########################################     FINISHED     ############################################################################

###############################################################################################################################################
## Allow cache based on matching query string.Page cached will be served with a separate cache file for each value of allowed query string.  ##
## Include Query String, where this means if your URL only contains include query strings, then it will create a separate cache for each URL ##
## for example, https://yourdomain and https://yourdomain?lang=MY will create different caches if "lang" is added to the query string        ##
###############################################################################################################################################
if ($cache_inc_uri ~ (.*)(&|\?)includethisquerytocache(?:=[^&]*&?|&|$)(.*)) {
  set $cache_inc_uri $1$2$3;
}
if ($cache_inc_uri ~ (.*)&$) {
  set $cache_inc_uri $1;
}
if ($cache_inc_uri ~ (.*)\?$) {
  set $cache_inc_uri $1;
}
if ($cache_inc_uri !~ ([^\?]+)(\?.*)) {
  set $skip_cache 0;
  set $bypass_reason "NOT BYPASS";
}

###########################################################
## Prevent page cache when matching query string exists. ##
###########################################################
if ($query_string ~ '\bdontcachethisquery[=&]?' ) {
      set $skip_cache 1;
        set $skip_cache_reason "Match rule EXCLUDE QUERY STRING with value $query_string";
}

####################################################
## Exclude page cache based on matching URL path. ##
####################################################
if ($request_uri ~* "/wp-.*.php/|/wp-locations.php/|/wp-links-opml.php/|/whislist.*/|/wp-comments-popup.php/|/cart.*/|/basket.*/|/checkout.*/|/my-account.*/|/offer.*/|/order-received.*/|/order-confirmed.*/|/.well-know/wp-admin/|/wp-json/|/xmlrpc.php|wp-.*.php|/wp-(app|cron|login|register|mail).php|/feed/|index.php|sitemap(_index)?.xml|/cart/|/basket/|/checkout/|/my-account/") {
        set $skip_cache 1;
        set $skip_cache_reason "Match Rule URL Path: $request_uri";
}

#######################################################
## Exclude page cache based on matching cookie name. ##
#######################################################
if ($http_cookie ~* "woocommerce_recently_viewed|woocommerce_cart_hash|wp_woocommerce_session|comment_author|wordpress_[a-f0-9]+|wp-postpass|wordpress_no_cache|wordpress_logged_in|woocommerce_items_in_cart") {
        set $skip_cache 1;
        set $skip_cache_reason "Match Rule COOKIE with value: $http_cookie";
}

###########################################################
## WooCommerce if has a item in the cart skip the cache. ##
###########################################################
if ( $cookie_woocommerce_items_in_cart = "1" ){
      set $skip_cache 1;
      set $skip_cache_reason "Match Rule of WooCommerce ITEMS IN THE CART";
}

##############################################################
## Exclude page cache based on matching visitor IP address. ##
##############################################################
if ($remote_addr ~* "127.0.0.5") {
        set $skip_cache 1;
        set $skip_cache_reason "Match rule IP ADDRESS with value $remote_addr";
}

##############################################################
## Exclude page cache based on matching browser user-agent. ##
##############################################################
if ($http_user_agent ~* "googlebot") {
        set $skip_cache 1;
        set $skip_cache_reason "Match rule USER AGENT with value $http_user_agent";
}

#######################################
## Post method should not be cached. ##
#######################################
if ($request_method = POST) {
        set $skip_cache 1;
        set $skip_cache_reason "POST Method Invoked";
}
 

Attachments

  • 1.png
    1.png
    28.4 KB · Views: 25

umart

Member
May 18, 2022
52
15
8
If it's a blog, you can use a 30-day cache expiration. If it's a WooCommerce site, I use 1 hour cache expiration. The cache expiration could be something that triggers the fastcgi nginx configuration to not cache this time. It's recommended to add an expiration reason to help with debugging and understanding.

This is my custom Fastcgi cache exclusion code. I wrote it myself, not like the same generic config files found on the internet or on Github.

Attached is a screenshot of what it looks like on Chrome DevTools.

Code:
############################################
## NGINX FASTCGU CACGE EXCLUSION SETTINGS ##
############################################

###########
## IDK   ##
###########
set $cache_uri $request_uri;
set $cache_inc_uri $cache_uri;

##########################
## Set cache default NO ##
##########################
set $skip_cache 0;

######################################
## Set reason of the skipping cache ##
######################################
set $skip_cache_reason "";

########################################
## Default query should not be cached ##
########################################
if ($query_string != "") {
        set $skip_cache 1;
        set $skip_cache_reason "Query String Is Not Empty: $query_string";
}

##################################################################################################################################################################
## Ignore query string,Page cache will be served when all query strings on the current page are in the list of ignored query strings SPECIALIZED FOR PAID MEDIA ##
##################################################################################################################################################################
###################
#  UTM Tracking  ##
###################
if ($cache_uri ~ (.*)(&|\?)utm_id(?:=[^&]*&?|&|$)(.*)) {
      set $cache_uri $1$2$3;
}
if ($cache_uri ~ (.*)(&|\?)utm_term(?:=[^&]*&?|&|$)(.*)) {
      set $cache_uri $1$2$3;
}
if ($cache_uri ~ (.*)(&|\?)utm_content(?:=[^&]*&?|&|$)(.*)) {
      set $cache_uri $1$2$3;
}
if ($cache_uri ~ (.*)(&|\?)utm_source(?:=[^&]*&?|&|$)(.*)) {
      set $cache_uri $1$2$3;
}
if ($cache_uri ~ (.*)(&|\?)utm_medium(?:=[^&]*&?|&|$)(.*)) {
      set $cache_uri $1$2$3;
}
if ($cache_uri ~ (.*)(&|\?)utm_campaign(?:=[^&]*&?|&|$)(.*)) {
      set $cache_uri $1$2$3;
}
if ($cache_uri ~ (.*)(&|\?)utm_expid(?:=[^&]*&?|&|$)(.*)) {
      set $cache_uri $1$2$3;
}

#################
# FACEBOOK Paid #
#################
if ($cache_uri ~ (.*)(&|\?)fb_action_ids(?:=[^&]*&?|&|$)(.*)) {
      set $cache_uri $1$2$3;
}
if ($cache_uri ~ (.*)(&|\?)fb_action_types(?:=[^&]*&?|&|$)(.*)) {
      set $cache_uri $1$2$3;
}
if ($cache_uri ~ (.*)(&|\?)fb_source(?:=[^&]*&?|&|$)(.*)) {
      set $cache_uri $1$2$3;
}
if ($cache_uri ~ (.*)(&|\?)fbclid(?:=[^&]*&?|&|$)(.*)) {
      set $cache_uri $1$2$3;
}
if ($cache_uri ~ (.*)(&|\?)fbadid(?:=[^&]*&?|&|$)(.*)) {
      set $cache_uri $1$2$3;
}
if ($cache_uri ~ (.*)(&|\?)placement(?:=[^&]*&?|&|$)(.*)) {
      set $cache_uri $1$2$3;
}

###############
# GOOGLE Paid #
###############
if ($cache_uri ~ (.*)(&|\?)gclid(?:=[^&]*&?|&|$)(.*)) {
      set $cache_uri $1$2$3;
}
if ($cache_uri ~ (.*)(&|\?)_ga(?:=[^&]*&?|&|$)(.*)) {
      set $cache_uri $1$2$3;
}
if ($cache_uri ~ (.*)(&|\?)_gl(?:=[^&]*&?|&|$)(.*)) {
      set $cache_uri $1$2$3;
}
if ($cache_uri ~ (.*)(&|\?)campaignid(?:=[^&]*&?|&|$)(.*)) {
      set $cache_uri $1$2$3;
}
if ($cache_uri ~ (.*)(&|\?)gadid(?:=[^&]*&?|&|$)(.*)) {
      set $cache_uri $1$2$3;
}

##################
# MICROSOFT Paid #
##################
if ($cache_uri ~ (.*)(&|\?)msclkid(?:=[^&]*&?|&|$)(.*)) {
      set $cache_uri $1$2$3;
}
if ($cache_uri ~ (.*)(&|\?)bingid(?:=[^&]*&?|&|$)(.*)) {
      set $cache_uri $1$2$3;
}

###############
# TIKTOK Paid #
###############
if ($cache_uri ~ (.*)(&|\?)ttadid(?:=[^&]*&?|&|$)(.*)) {
      set $cache_uri $1$2$3;
}

##################
# PINTEREST Paid #
##################
if ($cache_uri ~ (.*)(&|\?)padid(?:=[^&]*&?|&|$)(.*)) {
      set $cache_uri $1$2$3;
}

##########
# OTHERS #
##########
if ($cache_uri ~ (.*)(&|\?)age-verified(?:=[^&]*&?|&|$)(.*)) {
      set $cache_uri $1$2$3;
}
if ($cache_uri ~ (.*)(&|\?)ao_noptimize(?:=[^&]*&?|&|$)(.*)) {
      set $cache_uri $1$2$3;
}
if ($cache_uri ~ (.*)(&|\?)usqp(?:=[^&]*&?|&|$)(.*)) {
      set $cache_uri $1$2$3;
}
if ($cache_uri ~ (.*)(&|\?)cn-reloaded(?:=[^&]*&?|&|$)(.*)) {
      set $cache_uri $1$2$3;
}
if ($cache_uri ~ (.*)(&|\?)adgroupid(?:=[^&]*&?|&|$)(.*)) {
      set $cache_uri $1$2$3;
}
if ($cache_uri ~ (.*)(&|\?)adid(?:=[^&]*&?|&|$)(.*)) {
      set $cache_uri $1$2$3;
}
if ($cache_uri ~ (.*)(&|\?)gbraid(?:=[^&]*&?|&|$)(.*)) {
      set $cache_uri $1$2$3;
}
if ($cache_uri ~ (.*)(&|\?)wbraid(?:=[^&]*&?|&|$)(.*)) {
      set $cache_uri $1$2$3;
}
if ($cache_uri ~ (.*)(&|\?)gclsrc(?:=[^&]*&?|&|$)(.*)) {
      set $cache_uri $1$2$3;
}
if ($cache_uri ~ (.*)(&|\?)epik(?:=[^&]*&?|&|$)(.*)) {
      set $cache_uri $1$2$3;
}
if ($cache_uri ~ (.*)(&|\?)pp(?:=[^&]*&?|&|$)(.*)) {
      set $cache_uri $1$2$3;
}
if ($cache_uri ~ (.*)&$) {
      set $cache_uri $1;
}
if ($cache_uri ~ (.*)\?$) {
       set $cache_uri $1;
}
if ($cache_uri !~ ([^\?]+)(\?.*)) {
      set $skip_cache 0;
      set $skip_cache_reason "NOT BYPASS";
}
#########################################     FINISHED     ############################################################################
## Ignore query string,Page cache will be served when all query strings on the current page are in the list of ignored query strings###
#########################################     FINISHED     ############################################################################

###############################################################################################################################################
## Allow cache based on matching query string.Page cached will be served with a separate cache file for each value of allowed query string.  ##
## Include Query String, where this means if your URL only contains include query strings, then it will create a separate cache for each URL ##
## for example, https://yourdomain and https://yourdomain?lang=MY will create different caches if "lang" is added to the query string        ##
###############################################################################################################################################
if ($cache_inc_uri ~ (.*)(&|\?)includethisquerytocache(?:=[^&]*&?|&|$)(.*)) {
  set $cache_inc_uri $1$2$3;
}
if ($cache_inc_uri ~ (.*)&$) {
  set $cache_inc_uri $1;
}
if ($cache_inc_uri ~ (.*)\?$) {
  set $cache_inc_uri $1;
}
if ($cache_inc_uri !~ ([^\?]+)(\?.*)) {
  set $skip_cache 0;
  set $bypass_reason "NOT BYPASS";
}

###########################################################
## Prevent page cache when matching query string exists. ##
###########################################################
if ($query_string ~ '\bdontcachethisquery[=&]?' ) {
      set $skip_cache 1;
        set $skip_cache_reason "Match rule EXCLUDE QUERY STRING with value $query_string";
}

####################################################
## Exclude page cache based on matching URL path. ##
####################################################
if ($request_uri ~* "/wp-.*.php/|/wp-locations.php/|/wp-links-opml.php/|/whislist.*/|/wp-comments-popup.php/|/cart.*/|/basket.*/|/checkout.*/|/my-account.*/|/offer.*/|/order-received.*/|/order-confirmed.*/|/.well-know/wp-admin/|/wp-json/|/xmlrpc.php|wp-.*.php|/wp-(app|cron|login|register|mail).php|/feed/|index.php|sitemap(_index)?.xml|/cart/|/basket/|/checkout/|/my-account/") {
        set $skip_cache 1;
        set $skip_cache_reason "Match Rule URL Path: $request_uri";
}

#######################################################
## Exclude page cache based on matching cookie name. ##
#######################################################
if ($http_cookie ~* "woocommerce_recently_viewed|woocommerce_cart_hash|wp_woocommerce_session|comment_author|wordpress_[a-f0-9]+|wp-postpass|wordpress_no_cache|wordpress_logged_in|woocommerce_items_in_cart") {
        set $skip_cache 1;
        set $skip_cache_reason "Match Rule COOKIE with value: $http_cookie";
}

###########################################################
## WooCommerce if has a item in the cart skip the cache. ##
###########################################################
if ( $cookie_woocommerce_items_in_cart = "1" ){
      set $skip_cache 1;
      set $skip_cache_reason "Match Rule of WooCommerce ITEMS IN THE CART";
}

##############################################################
## Exclude page cache based on matching visitor IP address. ##
##############################################################
if ($remote_addr ~* "127.0.0.5") {
        set $skip_cache 1;
        set $skip_cache_reason "Match rule IP ADDRESS with value $remote_addr";
}

##############################################################
## Exclude page cache based on matching browser user-agent. ##
##############################################################
if ($http_user_agent ~* "googlebot") {
        set $skip_cache 1;
        set $skip_cache_reason "Match rule USER AGENT with value $http_user_agent";
}

#######################################
## Post method should not be cached. ##
#######################################
if ($request_method = POST) {
        set $skip_cache 1;
        set $skip_cache_reason "POST Method Invoked";
}
Very detailed. Thanks for sharing.
 

danielli

Member
Mar 29, 2020
200
21
18
You are correct. However, I can say that if using Nginx fastcgi page caching, there will not be much of a problem even when using Elementor (unless it's a checkout page, then it will start to become slow or a non-cached page).
So, do you mean Redis cach pro is not needed if Nginx Fastcig Cache was already used on site please?

Thanks
 

cesareborgia

Member
Babiato Fan
Oct 19, 2020
61
12
8
So much hype around this, I would rather have Varnish with the free version of this plugin.
And yes, i've tested both settings.
 

About us

  • Our community has been around for many years and pride ourselves on offering unbiased, critical discussion among people of all different backgrounds. We are working every day to make sure our community is one of the best.

Quick Navigation

User Menu