Administration
Compact Collection
Compacts the data of a collection in order to reclaim disk space. The operation compacts the document and index data by rewriting the data while keeping the relevant entries. Under normal circumstances running a compact operation is not necessary, as the collection data eventually gets compacted anyway. However, in some situations, e.g. after running many update or remove operations, the data for a collection may contain a lot of outdated data for which the space shall be reclaimed. In this case, the compaction operation can be used.
put/_fabric/{fabric}/_api/collection/{collection-name}/compact
Request
- The document declares no server URL.
- Auth
- API key in header Authorization
- or HTTP bearer
- TypeScriptA function with typed inputs. Its response is checked against the schema.
Path parameters
fabricstring string required
The name of the fabric.
collection-namestring string required
The name of the collection.
Response
Successfully compacted the collection.
Example response
{
"code": 200,
"id": "89218",
"name": "colltest0127133421258ogefv",
"hasStream": true,
"globallyUniqueId": "h2C627F3DCC8E/89218"
}Changes
No recorded changes to this operation across all 1 revision of this API.