Chasing the fabled 100% Insight score

This blog post isn't going to walk you through how to get your site's insight score up to 100%. The Acquia Cloud interface does pretty well at describing exactly which steps to take to get yourself there. However, I found it very frustrating that my insight score was only updating once per day if I was lucky. I had trouble finding some sort of explanation on what exactly makes the system update. But once I found the necessary documentation, setting up the Acquia Connector module to give me hourly updates on my Insight score was easy peasy!

Going forward I will assume you are using the Admin menu toolbar. If you don't have it already, do a quick 'drush en admin_menu -y', then do 'drush en admin_menu_toolbar -y', and finally 'drush dis toolbar -y'. This will enable admin menu, admin menu toolbar, and disable the standard toolbar that comes out of the box with Drupal. I will also assume that you're already using the Acquia connector module to manage your Acquia settings. (Sorry for all the assumptions)

Step 1: Go to Configuration > System > Acquia Subscription settings ( /admin/config/system/acquia-agent )
Step 2: Un-check "Send via Drupal Cron" and click "Save settings"

This default setting says that you want to send information to Acquia Insight every time the Drupal Cron gets run. Unfortunately it didn't seem to fire for me. I ran the cron multiple times, flushed my Drupal cache, cleared my Varnish cache, and slammed my head on the keyboard all to no avail.

After you save your settings without this option checked, some new text appears.

Enter the following URL in your servers crontab to send SPI data:
http://siteURL/system/acquia-spi-send?key=RANDOMKEY

Copy that URL and move onto your Acquia Cloud account. The next step is to enable a cron in the cloud that will fire off every hour.

Step 1: Log into insight.acquia.com/
Step 2: Click on "Cloud"
Step 3: In the sidebar menu, click "Cron"
Step 4: Depending on which environment you're working in, click the appropriate "Add cron job"
Step 5: Enter a name for your cron. (ex: Insight Score Update)
Step 6: Add the following code to your Cron command:

/usr/bin/wget -O - -q -t 1 http://siteURL/system/acquia-spi-send?key=RANDOMKEY

Step 7: Change the command frequency to "Every hour at 15 minutes past the hour" and save that.

That is all there is to it. Now the next time it is 15 past the hour, your cron will activate and update your insight score. Now get back to work optimizing your site for the Acquia Cloud!

Tags: 
Acquia Cloud
Insight
Drupal
Cron