function hook_acquia_search_get_list_of_possible_cores_alter in Acquia Connector 8
Alter the possible cores list.
$possible_core_ids = [
'WXYZ-12345.prod.default',
'WXYZ-12345.dev.mysitedev_folder1',
'WXYZ-12345.dev.mysitedev_db',
];
$context = [
'ah_env' => 'dev', // string|null
'ah_db_role' => 'SomeDb1, // string
'identifier' => 'WXYZ-12345', // string, may be empty
'sites_foldername' => 'default', // string
];
Parameters
array $possible_core_ids: The predefined list of possible cores.
array $context: Context.
1 invocation of hook_acquia_search_get_list_of_possible_cores_alter()
- PreferredSearchCoreService::getListOfPossibleCores in acquia_search/
src/ PreferredSearchCoreService.php - Returns a list of all possible search core IDs.
File
- acquia_search/
acquia_search.api.php, line 35 - Hooks specific to the acquia_search module.
Code
function hook_acquia_search_get_list_of_possible_cores_alter(array &$possible_core_ids, array $context) {
if (empty($context['ah_env'])) {
$possible_core_ids[] = 'WXYZ-12345.dev.mysitedev_db';
}
}