Skip to:
Content
Pages
Categories
Search
Top
Bottom

The Best Cache'ing solution for BP?

  • Avatar of carmeetsroad
    carmeetsroad
    Participant

    @carmeetsroad

    Hey Guys,

    Im trying to figure out the best cache’ing solution for BP. My site has reached popularity that I need it now.

    Im looking for cache thats BP friendly that works with common plugins such as Facebook, RTmedia

Viewing 8 replies - 1 through 8 (of 8 total)
  • Avatar of carmeetsroad
    carmeetsroad
    Participant

    @carmeetsroad

    any recommendations?

    If you’re not already using one, set up an object cache. It’s relatively simple and will be a big improvement for all WordPress things, not just BuddyPress.

    Avatar of hughshields
    hughshields
    Participant

    @hughshields

    Hi Paul,
    Can you explain what you mean by setting up an object cache?
    1. Should we still add: define( ‘WP_CACHE’, true );into the wp-config.php file above the “stop editing” line?
    2. Is one of the caching plugins sufficient (Quick Cache, W3 Total Cache, or WP Super Cache) and if so which one is best for BP?

    Thanks in advance for the details!

    Those two questions aren’t really relevant here. A quick Google search will suggest object caching solutions for WordPress:

    http://wordpress.org/plugins/apc/ is one of them, if your web host is using APC. You’ll have to ask them to find this out.

    Avatar of hughshields
    hughshields
    Participant

    @hughshields

    Hi Paul,
    In the Buddypress Codex there is information last updated 2 years ago by Sarah Gooding that recommends the two above points that I mentioned for caching. Is this information out of date?
    Also the codex points to a support thread:

    http://buddypress.org/support/topic/configuring-w3-total-cache-with-buddypress/

    This support thread is also a couple of years old and ends with no solution or resolution to BP caching and a lot of frustrated people.

    Is it safe to say that the caching plugins do not provide a good solution for Buddypress? And that a server side caching solution is the best option?

    I am self hosted on a VPN so for me this is not good news.

    Avatar of evanvolgas
    evanvolgas
    Participant

    @evanvolgas

    I’ve had a lot of luck with the W3TC plugin. I set object caching to Disk, Page caching to APC, and minification with CloudFlare (I’d use APC otherwise). If you have a lot of memory to work with, by all means use APC on the disk too…. the VPS’s I’ve worked on lately had only a gig and object cache with that had a tendency to crash under moderate traffic.

    “Is it safe to say that the caching plugins do not provide a good solution for Buddypress? And that a server side caching solution is the best option?”

    This question doesn’t quite make a lot of sense. APC, memcache… hell even disk is server side. And the plugins available are doing that. The question is what’s right for your site… and that really depends on what you’re starting with on your server (which I presume is a VPS not a VPN)

    Anyway, W3TC works for me…but you’re gonna get a lot of answers cause it really just depends.

    Key thing to note: “My site has reached popularity that I need it now.”

    If you didn’t already know, play with caching on a test server. It’s useful stuff, but you can crash the site very easily if you make a mistake. This is not a toy to play with on a live website.

    Avatar of Asynaptic
    Asynaptic
    Participant

    @synaptic

    because of its nature (membership site where content differs depending on being logged in vs. logged out content) the best caching solution for buddypress is partial page caching (aka fragment cache), something that sort of exists and sorta doesn’t.

    my suggestion is to take the BP survey and to add your voice for it so the developers know there is real demand:

    http://buddypress.org/2014/01/2014-buddypress-survey/

    more info:

    http://chrislema.com/high-performance-wordpress-membership-site/

    http://exygy.com/fragment-caching-wordpress-optimize-site-speed-logged-users/

    https://bitbucket.org/Rarst/fragment-cache

    http://wordpress.org/plugins/fragmentcache/

    Avatar of BuddyBoss
    BuddyBoss
    Participant

    @buddyboss

    Fragment caching would be ideal, but that really needs to be built into BP core. You can do it on your own but you’ll be hacking up template files right and left and it will be hard to update later. A lot of effort if you don’t NEED it. I would suggest Object Caching as Paul Gibbs said.

    Ideally you will use APC object caching as it’s really fast (stores cached values in RAM). If you use W3TC with file caching (default) it will not be as fast as it has to read from files.

    Here’s a tutorial I wrote about how to enable Object Caching on BuddyPress:

    http://www.buddyboss.com/tutorials/caching-buddypress/

    Briefly:

    If you are hosting with a VPS or other setup where you have server admin access, you can contact your web host and request that they install APC on your server (it’s free) and then it will be available to you as a very fast method for Object Caching. Generally you cannot install APC on a shared hosting environment. APC stores the cached values in RAM, which is why I recommend at least 2GB of RAM for ideal server performance.

    Once your web host has confirmed that APC is installed and working, you will then need to enable it for WordPress with a plugin. My recommended method is with the APC Object Cache Backend plugin (as Paul Gibbs suggested). This is not a true plugin, but rather a “drop-in” file. As such, you do not actually activate the plugin. You just need to copy the object-cache.php file into your /wp-content/ directory. You don’t even need to upload the actual plugin. That’s it! As long as you have APC installed on your server and have placed the file correctly, APC-powered Object Caching should now be enabled and you should begin seeing performance improvements. To confirm that it’s working, you can type this into your browser while logged in as an admin: http://www.yourdomain.com/wp-admin/plugins.php?plugin_status=dropins (change yourdomain.com!). It should show APC Object Cache as a drop-in, and if so, you now have a good caching method enabled.

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

You must be logged in to reply to this topic.