Support » Plugin: CloudSearch » What headers must be allowed for plugin to work on site served through CDN?

  • Resolved seanhelmes

    (@seanhelmes)


    We have our wordpress site powered by an AWS EC2 instance which serves our entire site through the cloudfront CDN. The EC2 instance is the origin for the cloudfront distribution. With our set up and site serving through cloudfront CDN, we need to set in our cloudfront settings which headers to allow through to our origin EC2 server. Which specific headers and their values do we need to enable/whitelist to make your cloudsearch plugin work on this setup? Please also see the error screenshot here: https://app.box.com/s/lnmq16lycoxmffiq0utaidhkp6trmvef

    I have gotten your cloudsearch plugin working fine (and it works great!) with our cloudsearch instance on our sandbox website which runs on an EC2 server. The only difference is our sandbox site doesn’t get served out through the cloudfront CDN. The only other thing I can think of is we have another wordpress plugin running on our production server that connects to AWS services specifically for clearing cloudfront caches when we update content on our site, so maybe that is not allowing your plugin or the AWS plugin to talk to AWS at the same time? Any help or insight would be greatly appreciated as I really want to get your great plugin working on our production website.

Viewing 9 replies - 1 through 9 (of 9 total)
  • The issue is actually a conflict with the c3 cloudfront cache controller plugin which also uses the AWS PHP SDK in that plugin itself. Can you make your plugin not conflict with that plugin? https://wordpress.org/plugins/c3-cloudfront-clear-cache/

    Plugin Author Andrea Landonio

    (@lando1982)

    Hi Sean, I’m late, sorry.. 🙁
    Have you some notice/error in your logs to better explain me the conflict? My plugin doesn’t provide any AWS PHP SDK but works on top of the SDK provided by the AWS WordPress plugin.. it shouldn’t create a conflict.. mmm..
    Let me know.. I’m ready to make my plugin working with others..
    Bye

    Hi Andrea,

    No worries, thanks for your reply. The issue of potential conflict that I am experiencing is noted by the developer of the Amazon Web Services plugin at https://wordpress.org/plugins/amazon-web-services/ where they link to a post here: https://deliciousbrains.com/wp-offload-s3-1-6-released which explains “By far the biggest reason is to eliminate conflicts with other plugins that also include a version of the AWS PHP SDK. It seems to be quite common for backup or sharing plugins to bundle v3 of the AWS PHP SDK for example. This can cause failures in WP Offload S3 or failures in the other plugin that is loading the SDK. WP Offload S3 now includes a uniquely namespaced AWS PHP SDK v2 that eliminates this problem.”

    The problem is that apparently we can’t have two plugins using the AWS PHP SDK at the same time, unless they are uniquely namespaced by the plugin using the AWS PHP SDK, like what Delicious Brains did for their plugin that used to rely on their AWS plugin.

    Plugin Author Andrea Landonio

    (@lando1982)

    Hi Sean, reading the post of DeliciousBrains now it’s clear.. now I’m very busy with my job but I’ll work on your problems as soon as possible.. if I’m lucky I’ll give you a new release for the next week 😉
    Keep in touch..
    Bye

    Sounds good, thanks Andrea!

    Plugin Author Andrea Landonio

    (@lando1982)

    Hi Sean,
    I’ve uploaded a new version of my plugin with the dependency of the AWS plugin removed. The version still remain the 2.4.0 but the source is different.. could you download again the plugin and try if your problem is solved? If my fix works properly I can update version and deploy an official release..
    Let me know when you could have a test 😉
    Bye

    I will test this today and will let you know.

    It works! Very nice work, and thank you! Now your plugin shouldn’t have any conflicts with other plugins that use the AWS PHP SDK, and it is good to not have to have the plugin rely on the AWS plugin which is no longer technically supported by Delicious Brains.

    Plugin Author Andrea Landonio

    (@lando1982)

    Thanks to you Sean! In the next week you should see a new release of the plugin.. including your fix and some other little issues.. 😉

Viewing 9 replies - 1 through 9 (of 9 total)
  • The topic ‘What headers must be allowed for plugin to work on site served through CDN?’ is closed to new replies.