You are here

function acquia_search_get_environment in Acquia Connector 7

Same name and namespace in other branches
  1. 7.3 acquia_search/acquia_search.module \acquia_search_get_environment()
  2. 7.2 acquia_search/acquia_search.module \acquia_search_get_environment()

Predefined Acquia Search network environment

2 calls to acquia_search_get_environment()
acquia_search_enable_acquia_solr_environment in acquia_search/acquia_search.module
Create a new record pointing to the Acquia apachesolr search server and set it as the default
acquia_search_environment_edit_form_validate in acquia_search/acquia_search.module

File

acquia_search/acquia_search.module, line 13
Integration between Acquia Drupal and Acquia's hosted solr search service.

Code

function acquia_search_get_environment($conf = array()) {
  if (!empty($conf['acquia_subscription_id'])) {
    $identifier = $conf['acquia_subscription_id'];
  }
  else {
    $identifier = acquia_agent_settings('acquia_identifier');
  }
  $environment = array(
    // @todo - server URL may depend on region info.
    'url' => variable_get('acquia_search_url', 'http://search.acquia.com/solr/' . $identifier),
    'service_class' => 'AcquiaSearchService',
  );
  return $environment;
}