Understanding the Cache

The default cache setting is 1 day, this should be fine for most uses but there are circumstance when you may want to change the settings.

The cache impacts view new or modified events and also if you are showing attendee data the counts.

Events that were live but ended are not displayed by the front end ( even though they may still be in cache )

The cache does two things,
1. protects your end users from a slow experience
2. protects you from exceeding Eventbrite API hourly / daily limits

If you exceed the Eventbrite API limits you may find some data is missing or out of date.

If you want to use a shorter cache time than one day, you can but you need to do some calculations to check you won’t exceed the limits.

First you need to know how many events are being queried. The query is based on status not what is being displayed. If you have 20 live events and only displaying limit=3 that is still 20.

If you have two shortcodes one for future and one for past, the number of queries include all your past events. So if you have 20 future and 300 past events that is 320. Even if you only display 1 event or each.

Once you know how many events the formulae is

Minimum cache minutes = 0.06 * Queried Events

Our first example of 20 queries would be a minimum cache of 1.2 minutes, so you can use 5 minutes – but this is not recommended as many of your visitors will wait while cache is being rebuilt

Our second example of 320 queries would be a minimum cache time of 19.2 minutes, so you can use 30 minutes as a minimum.

Was this helpful?

Next Article

Shortcode Builder