One of my client’s site was slowed down too much and its waiting time was 6 to 7 seconds. I found the root cause which was because the wp_options table
was filled with a lot of customer sessions data that increased table size to 1.7 GB. It took 6-7 hours to delete 2 million rows. I know I can now delete sessions and transients manually by going to Woocomerce > System Status > Tools > Clear all
sessions & Clear transients but I want it to be done automatically after one or two days. Is there anything could be done like creating cron job
etc?
Thanks
2 comments
Comments are closed.
Maybe you should try this plugin:
Delete Expired Transients
long time later but that awnser will can help someone
below the code will execute every day (from your current time), the clean session/cart Woocommerce.
for transients, its that function in wc: