You are here

function acquia_spi_send_full_spi in Acquia Connector 7.3

Same name and namespace in other branches
  1. 6.2 acquia_spi/acquia_spi.module \acquia_spi_send_full_spi()
  2. 7.2 acquia_spi/acquia_spi.module \acquia_spi_send_full_spi()

Gather full SPI data and send to Acquia Insight.

Parameters

string $method: Optional identifier for the method initiating request. Values could be 'cron' or 'menu callback' or 'drush'.

Return value

mixed FALSE if data not sent else NSPI result array

5 calls to acquia_spi_send_full_spi()
acquia_agent_spi_set_submit in acquia_spi/acquia_spi.module
Save the results of NSPI form and submit to server if machine name changed.
acquia_spi_agent_settings_submit in acquia_spi/acquia_spi.module
Added submit function for acquia_agent_settings form.
acquia_spi_cron in acquia_spi/acquia_spi.module
Implements hook_cron().
acquia_spi_environment_change_form_submit in acquia_spi/acquia_spi.pages.inc
Save environment change form submissions.
_acquia_spi_send in acquia_spi/acquia_spi.module
Callback for sending SPI data.

File

acquia_spi/acquia_spi.module, line 430
Send site profile information (NSPI) and system data to Acquia Insight.

Code

function acquia_spi_send_full_spi($method = '') {
  $spi = acquia_spi_get();
  if (!empty($method)) {
    $spi['send_method'] = $method;
  }
  $result = acquia_spi_send_data($spi);
  if ($result === FALSE) {
    return FALSE;
  }
  acquia_spi_handle_server_response($result);
  variable_set('acquia_spi_cron_last', REQUEST_TIME);
  return $result;
}