function drush_search_api_set_index_server in Search API 8
Same name and namespace in other branches
- 7 search_api.drush.inc \drush_search_api_set_index_server()
Sets the server for a given index.
Parameters
string $index_id: The ID of the index whose server should be changed.
string $server_id: The ID of the new server for the index.
File
- ./
search_api.drush.inc, line 429 - Drush commands for Search API.
Code
function drush_search_api_set_index_server($index_id = NULL, $server_id = NULL) {
$command_helper = _search_api_drush_command_helper();
try {
$command_helper
->setIndexServerCommand($index_id, $server_id);
} catch (ConsoleException $exception) {
drush_print($exception
->getMessage());
}
}