Storage API
editStorage API
editUse the Storage API to get information about internal indices created and managed by Enterprise Search, and how much space they occupy. You can also list or remove stale indices, which were left behind by older versions of Enterprise Search during upgrades.
Get storage API
editGet storage information for a deployment.
GET <enterprise-search-base-url>/api/ent/v1/internal/storage
Path parameters
edit-
enterprise-search-base-url
(required) - The Enterprise Search base URL for the deployment.
Response body
editEach response includes indices
and summary
.
Each index in the list of indices
has the following fields:
-
name
(required) - The index name.
-
size_in_bytes
(required) - Size of the index, in bytes.
The summary contains the following elements:
-
index_count
(required) - Total number of indices.
-
size_in_bytes
(required) - Total number of indices.
Examples
editList all Enterprise Search indices:
curl \ --request "GET" \ --url "${ENTERPRISE_SEARCH_BASE_URL}/api/ent/v1/internal/storage" \ --header "Authorization: Bearer ${API_KEY}"
Response:
{ "indices": [ { "name": ".ent-search-actastic-app_search_accounts_v10", "size_in_bytes": 5362 }, { "name": ".ent-search-actastic-app_search_accounts_v11", "size_in_bytes": 12317 }, { "name": ".ent-search-actastic-app_search_api_token_engines", "size_in_bytes": 226 }, ... ], "summary": { "index_count": 109, "size_in_bytes": 6572252 } }
Get stale storage API
editGet the list of outdated indices, left behind by older versions of Enterprise Search.
GET <enterprise-search-base-url>/api/ent/v1/internal/storage/stale
Path parameters
edit-
enterprise-search-base-url
(required) - The Enterprise Search base URL for the deployment.
Response body
editEach response includes indices
and summary
.
Each index in the list of indices
has the following fields:
-
name
(required) - The index name.
-
size_in_bytes
(required) - Size of the index, in bytes.
The summary contains the following elements:
-
index_count
(required) - Total number of indices.
-
size_in_bytes
(required) - Total number of indices.
Examples
editList outdated Enterprise Search indices:
curl \ --request "GET" \ --url "${ENTERPRISE_SEARCH_BASE_URL}/api/ent/v1/internal/storage/stale" \ --header "Authorization: Bearer ${API_KEY}"
Response:
{ "indices": [ { "name": ".ent-search-actastic-app_search_accounts_v10", "size_in_bytes": 5362 }, { "name": ".ent-search-actastic-app_search_role_engines_v3", "size_in_bytes": 226 }, { "name": ".ent-search-actastic-app_search_role_mapping_engines_v3", "size_in_bytes": 226 }, ... ], "summary": { "index_count": 40, "size_in_bytes": 379439 } }
Delete stale storage API
editDelete outdated indices, left behind by older versions of Enterprise Search.
DELETE <enterprise-search-base-url>/api/ent/v1/internal/storage/stale
Path parameters
edit-
enterprise-search-base-url
(required) - The Enterprise Search base URL for the deployment.
Query string parameters
edit-
force
(optional) -
If this flag is set to
true
, Enterprise Search will attempt to delete the outdated indices, even if the deployment indices are found to be in an inconsistent state. The default isfalse
.
Response body
editEach response includes indices
and index_count
.
-
indices
(required) - The list of deleted index names.
-
index_count
(required) - Total number of deleted indices.
Examples
editDelete outdated Enterprise Search indices:
curl \ --request "DELETE" \ --url "${ENTERPRISE_SEARCH_BASE_URL}/api/ent/v1/internal/storage/stale" \ --header "Authorization: Bearer ${API_KEY}"
Response:
{ "indices": [ ".ent-search-actastic-app_search_accounts_v10", ".ent-search-actastic-app_search_role_engines_v3", ".ent-search-actastic-app_search_role_mapping_engines_v3", ... ], "index_count": 40 }