GithubHelp home page GithubHelp logo

Comments (11)

danielbachhuber avatar danielbachhuber commented on August 16, 2024

Compatible in what sense? It should be fine to run the two side by side.

from wp-redis.

szepeviktor avatar szepeviktor commented on August 16, 2024

Maybe: Will Batcache put pages in wpcache thus in redis?

+36204242498
Ezen a készüléken nehéz gépelni.
Elnézést!

On April 7, 2016 1:35:46 PM CEST, Daniel Bachhuber [email protected] wrote:

Compatible in what sense? It should be fine to run the two side by
side.


You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
#80 (comment)

from wp-redis.

tlovett1 avatar tlovett1 commented on August 16, 2024

Here is the error I'm getting:

Fatal error: Call to undefined function add_action() in /srv/www/trunk/wp-content/object-cache.php on line 1087

Clearly, Batcache is instantiating WP_Object_Cache before add_action is available. I can fix if you guys want.

from wp-redis.

danielbachhuber avatar danielbachhuber commented on August 16, 2024

Clearly, Batcache is instantiating WP_Object_Cache before add_action is available.

Huh.

I can fix if you guys want.

What do you think the fix should be?

from wp-redis.

tlovett1 avatar tlovett1 commented on August 16, 2024

https://github.com/WordPress/WordPress/blob/master/wp-settings.php#L74

advanced-cache.php is included before things like $wpdb or add_action() are defined.

from wp-redis.

tlovett1 avatar tlovett1 commented on August 16, 2024

The fix is getting rid of the "failback" flush as well as the admin notice error. If you guys are interested, I can create a PR.

from wp-redis.

danielbachhuber avatar danielbachhuber commented on August 16, 2024

The fix is getting rid of the "failback" flush as well as the admin notice error.

Er, removing a feature isn't really a fix. We'll need to find some other workaround.

from wp-redis.

danielbachhuber avatar danielbachhuber commented on August 16, 2024

Similar to how Batcache does it, we can inject our action instead on the $wp_filter global: https://github.com/Automattic/batcache/blob/master/advanced-cache.php#L540

Alternatively, because the object cache is always re-initialized after advanced-cache.php runs, we could just have safety checks for add_action() and $wpdb being defined.

from wp-redis.

danielbachhuber avatar danielbachhuber commented on August 16, 2024

@tlovett1 Can you see if #81 works for your needs?

from wp-redis.

josephabrahams avatar josephabrahams commented on August 16, 2024

Works like a charm!

from wp-redis.

danielbachhuber avatar danielbachhuber commented on August 16, 2024

🔨

from wp-redis.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.