• Resolved dberdal

    (@dberdal)


    I’m using wordpress multisite, and this may be default wordpress behavior but it’s causing problems for CDN usage.

    A blog with the URL rootsite.com/blog1 has the static resources linked like
    cdn1.rootsite.com/blog1/wp-content/themes/childtheme/style.css

    When the same resource is available at cdn1.rootsite.com/wp-content/themes/childtheme/style.css

    By including the blog slug in the url, it means that the CDN is storing unique copies of all of those static resources for EVERY SINGLE blog. Not only does it cost more, but it’s a big drag on performance.

    For example, on a multisite network with 1000 blogs, there is a slow load cdn priming for each site. Whereas if the blog slug wasn’t in the url the first load of a resource on the network would be slow, but every other page load on the network would have a primed CDN to pull from.

    Not sure if this is something that W3TC can address, but I’m open to any help or suggestions.

Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Contributor Marko Vasiljevic

    (@vmarko)

    Hello @dberdal,

    Sorry for the late reply.

    Yes, it’s default behavior that works well for all possible cases, while it can be less efficient if you expect the same visitors to visit multiple blogs and you have a big number of blogs.

    In that case, behavior can be changed by hooking ‘w3tc_cdn_url’ hook.
    I can also offer you Professional support for this.

    Thread Starter dberdal

    (@dberdal)

    Hi Marko,

    Thanks for the reply. I’ll check out the w3tc_cdn_url hook, that might be the solution for me.

    The default behavior is inefficient just if you have a lot of sites… In my case the CDN is storing thousands of duplicate copies, and is having thousands of slow page loads as the CDN is re-primed over and over for each of those individual sites.

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘WordPress Multisite CDN Links for static resources shouldn’t be unique per blog’ is closed to new replies.