Title: wp_cache_add_non_persistent_groups()
Last modified: August 22, 2016

---

# wp_cache_add_non_persistent_groups()

 *  [deltafactory](https://wordpress.org/support/users/deltafactory/)
 * (@deltafactory)
 * [11 years, 6 months ago](https://wordpress.org/support/topic/wp_cache_add_non_persistent_groups/)
 * This was asked once before, a long time ago, but there was no response.
 * Why are these groups set to be non-persistent in core? I would think that in 
   the interest of performance these values could benefit from a little bit of caching–
   even 60 seconds.
 * `wp_cache_add_non_persistent_groups( array( 'comment', 'counts', 'plugins' ) );`
 * [https://github.com/WordPress/WordPress/blob/master/wp-includes/load.php#L455](https://github.com/WordPress/WordPress/blob/master/wp-includes/load.php#L455)

Viewing 2 replies - 1 through 2 (of 2 total)

 *  Moderator [bcworkz](https://wordpress.org/support/users/bcworkz/)
 * (@bcworkz)
 * [11 years, 6 months ago](https://wordpress.org/support/topic/wp_cache_add_non_persistent_groups/#post-5717065)
 * The function call is only a hint for persistent caching plugins. It’s up to the
   plugin to make use of it or not. The default WP cache is not persistent, so the
   call has no bearing on default installations.
 * The default cache focuses on query results that are computationally expensive.
   As a guess, WP is suggesting to any potential caching plugins that these queries
   are not expensive?
 *  Thread Starter [deltafactory](https://wordpress.org/support/users/deltafactory/)
 * (@deltafactory)
 * [11 years, 6 months ago](https://wordpress.org/support/topic/wp_cache_add_non_persistent_groups/#post-5717068)
 * FYI I understand how object caching works. I’m working on query/object cache 
   optimizations for a site and I’m down to 3 queries per page load. This is causing
   at least 2 of the hold-outs. 🙂
 * While it’s technically a “hint”, a caching plugin attempting to follow the intent
   of the call wouldn’t cache those groups. I suppose my question can be rephrased,“
   Why does core hint to leave these uncached?”
 * There’s very little about this either in the code or online docs.
 * I’m not sure of how expensive these queries are. I’m attempting to find out how
   close I can get to zero queries without page caching.

Viewing 2 replies - 1 through 2 (of 2 total)

The topic ‘wp_cache_add_non_persistent_groups()’ is closed to new replies.

## Tags

 * [cache](https://wordpress.org/support/topic-tag/cache/)

 * In: [Hacks](https://wordpress.org/support/forum/plugins-and-hacks/hacks/)
 * 2 replies
 * 2 participants
 * Last reply from: [deltafactory](https://wordpress.org/support/users/deltafactory/)
 * Last activity: [11 years, 6 months ago](https://wordpress.org/support/topic/wp_cache_add_non_persistent_groups/#post-5717068)
 * Status: not resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
