1.8 Guide – Caching

Home / Blog / 1.8 Guide – Caching


Version 1.8 has received a major improvement in how database queries are handled and stored on your website, lowering the plugins footprint. Support has also been added for third-party caching plugins allowing you to cache history and leaderboard queries (the most expensive ones).

You can now select how long these queries are cached, being updated each time a use gains points, or if you have a large number of transactions per day, caching results for longer periods of time.

Deleting Log Entries

If your website has a lot of transactions, the log can quickly become very large. As of version 1.8, you can now select to delete these entries after x number of days. But before you do, you should be aware of the consequences of doing this!

The Log’s primary job is to provide you and your users with accountability for how their points were gained and what it was spent on (if points can be spent). But the log is also used for a vast range of features in myCRED:

  • Ensuring that hook limits you might have set is enforced. This means that if you delete log entries, we will going to be able to enforce these limits. So if you are using hook limits, note the longest a limit is set (e.g. monthly limits) and ensure that you delete log entires that are older than this limit!
  • Ensure that in certain situations, users only get points once. As an example, the buyCRED where we want to make sure purchases are only paid once. The same is applicable for the Content View hook where you can only get points once for each unique content. Removing these log entries will result in your users being able to gain points again for viewing the same content.
  • Compound Interest payouts rely heavily on the log so deleting them can cause your payouts to be lower than they should be since records would be missing.

So before you enable this feature, make sure you set the number of days that will work for your setup without giving your users the possibility to abuse it.

Last edited October 3, 2017

Leave a Reply