Have A Hummingbird Question

Can you guys tell me where this value is stored in the database when I enable/disable the "Allow subsite admins to disable page caching" toggle in Network Admin > Hummingbird > Dashboard > Caching section?

Also, where are the "Asset Optimization" option values (Network Admin > Hummingbird > Dashboard > Asset Optimization section) are stored in the database?

  • Adam Czajczyk

    Hello cbenson583,

    I hope you're well today and thank you for your question!

    Can you guys tell me where this value is stored in the database when I enable/disable the "Allow subsite admins to disable page caching" toggle in Network Admin > Hummingbird > Dashboard > Caching section?

    This is stored in wp_sitemeta table. The meta_key is wphb_settings and the meta_value is a serialized array. The part responsible for this setting is:

    s:10:"page_cache";a:4:{s:7:"enabled";s:11:"blog-admins";s:7:"control";b:0;s:9:"detection";s:6:"manual";s:12:"pages_cached";i:0;}

    The above data is for this option enabled, the "blog-admin" parts indicates it.

    Also, where are the "Asset Optimization" option values (Network Admin > Hummingbird > Dashboard > Asset Optimization section) are stored in the database?

    That's a bit more complex. There are "wphb_scripts_collection" and "wphb_styles_collection" options in wp_options table of the main site and each of the sub-sites. Those options' values are serialized arrays of resources identified on the given site with URLs, handles etc.

    There's also wphb_settings option with additional settings for HB, including a "minify" section.

    Then, in wp_posts you'll find a set of posts of a wphb_minify_group post type along with relevant meta in wp_postmeta table which hold actual state of the Asset Optimization options for the assets.

    So, while setting the caching option directly via database is relatively simple, this can be more difficult because the data is "spread" across multiple tables and their columns/rows and there are dependencies that must be maintained/handled.

    If you got any follow up questions, let me know please.

    Kind regards,
    Adam

  • cbenson583

    Thanks Adam for the insight,

    I am happy to know it's in the DB. We only have one and all of our web servers obviously are configured to use it. This does remove my theory that we have an apache file sync issue causing the state of that setting not to remain on after the page responds that it has been updated.

    Have you all seen or heard of that issue? As you know caching can make or break most sites in regard to their operation and I like knowing the ins/outs of this stuff.

    Thanks,

    Cody

  • Adam Czajczyk

    Hello Cody!

    Yeah, cache can affect site's performance not only by speeding it up but sometimes also by triggering some unexpected issues.

    But in this case, I'm not quite sure what could be the reason for this. It seems that you have quite a nice but not very common setup so I'd like to understand it better.

    Is it that you got a grid of servers where the entire Multisite is replicated (mirrored) into multiple instances of very same separate setup (including files and database) - sync'd of course - and then there's some load balancer in front of those?

    Or do you have e.g. just a common db (single instance) with a set of Multisite copies all using the very same single db (again, with load balancing) or maybe just some "content files" (e.g. uploads, or theme assets) are "multiplied and balanced"? There's many options and I just want to get a better picture.

    Also, problems with caches (page cache and actually asset optimization cache) in such an environment can be that the Hummingbird (or any other site-side caching plugin) can be generating/updating/purging caches differently on different copies of the site behind the load balancer. Adding a sync to this might, theoretically, mess that up a bit. Just a thought: did you try to actually exclude folders like

    /wp-content/wphb-cache
    /wp-content/wphb-logs
    /wp-content/uploads/wp-hummingbird-cache

    from synchronization?

    Are there any additional server-side caching tools implemented?

    Best regards,
    Adam

Thank NAME, for their help.

Let NAME know exactly why they deserved these points.

Gift a custom amount of points.