Title: Does This Custom Caching Code Interfere with Jetpack ?
Last modified: August 2, 2024

---

# Does This Custom Caching Code Interfere with Jetpack ?

 *  Resolved [hassantafreshi](https://wordpress.org/support/users/hassantafreshi/)
 * (@hassantafreshi)
 * [1 year, 10 months ago](https://wordpress.org/support/topic/does-this-custom-caching-code-interfere-with-jetpack/)
 * As the developer of the[ Easy Form Builder plugin](https://wordpress.org/plugins/easy-form-builder/),
   I’m seeking some advice about potential conflicts with Jetpack .
 * Here is the function I am currently using for internal caching:
 *     ```wp-block-code
       public function get_efbFunction($state) {    if (isset($this->efbFunction)) return $this->efbFunction;    $efbFunctionInstance;    if (false === ($efbFunctionInstance = wp_cache_get('efbFunctionInstance', 'emsfb'))) {        if (!class_exists('Emsfb\efbFunction')) {            require_once(EMSFB_PLUGIN_DIRECTORY . 'includes/functions.php');        }        $efbFunctionInstance = new \Emsfb\efbFunction();        wp_cache_set('efbFunctionInstance', $efbFunctionInstance, 'emsfb', 3600); // 1 hour cache    }    $this->efbFunction = $efbFunctionInstance;    if ($state == 1) return $this->efbFunction;}
       ```
   
 * My concern is whether using `wp_cache_get` and `wp_cache_set` for internal caching
   might cause any conflicts with Jetpack. Has anyone had similar experiences or
   know of best practices to ensure they work together smoothly?
 * Any guidance or insights would be greatly appreciated.
 * Thank you for your help!
 * Best regards,
 * The page I need help with: _[[log in](https://login.wordpress.org/?redirect_to=https%3A%2F%2Fwordpress.org%2Fsupport%2Ftopic%2Fdoes-this-custom-caching-code-interfere-with-jetpack%2F%3Foutput_format%3Dmd&locale=en_US)
   to see the link]_

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

 *  [Emily A. (a11n)](https://wordpress.org/support/users/happyaxident/)
 * (@happyaxident)
 * [1 year, 10 months ago](https://wordpress.org/support/topic/does-this-custom-caching-code-interfere-with-jetpack/#post-17933826)
 * Hi [@hassantafreshi](https://wordpress.org/support/users/hassantafreshi/),
 * Thanks for your question!
 * There should be no conflict with Jetpack. `wp_cache_get` and `wp_cache_set` are
   standard functions made available by WordPress itself, and used by lots of plugins,
   including Jetpack. As long as the cache key is unique (`efbFunctionInstance` 
   in this case, a key that is not used by the Jetpack plugin), it is not expected
   to conflict with other plugins.
 * Let us know if you have any other questions!
 *  Thread Starter [hassantafreshi](https://wordpress.org/support/users/hassantafreshi/)
 * (@hassantafreshi)
 * [1 year, 10 months ago](https://wordpress.org/support/topic/does-this-custom-caching-code-interfere-with-jetpack/#post-17933949)
 * [@happyaxident](https://wordpress.org/support/users/happyaxident/) Thank you 
   for comprehensive response.
 *  [Emily A. (a11n)](https://wordpress.org/support/users/happyaxident/)
 * (@happyaxident)
 * [1 year, 10 months ago](https://wordpress.org/support/topic/does-this-custom-caching-code-interfere-with-jetpack/#post-17934298)
 * You’re welcome! Have a great day!

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

The topic ‘Does This Custom Caching Code Interfere with Jetpack ?’ is closed to 
new replies.

 * ![](https://ps.w.org/jetpack/assets/icon.svg?rev=2819237)
 * [Jetpack - WP Security, Backup, Speed, & Growth](https://wordpress.org/plugins/jetpack/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/jetpack/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/jetpack/)
 * [Active Topics](https://wordpress.org/support/plugin/jetpack/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/jetpack/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/jetpack/reviews/)

## Tags

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

 * 3 replies
 * 2 participants
 * Last reply from: [Emily A. (a11n)](https://wordpress.org/support/users/happyaxident/)
 * Last activity: [1 year, 10 months ago](https://wordpress.org/support/topic/does-this-custom-caching-code-interfere-with-jetpack/#post-17934298)
 * Status: resolved