Skip to content

Operation $compact

NOTE

The system level $compact operation is only activated if the Admin API is activated.

The system level $compact operation is used to compact column families of RocksDB databases. RockDB compaction is done automatically but in certain situations manual compaction can be useful.

POST [base]/$compact

In Parameters

NameCardinalityTypeDocumentation
database1..1codeOne of three possible databases: index, transaction and resource
column-family1..1codeName of the column family depending on the database. See below.

Column Families

DatabaseColumn Family
indexsearch-param-value-index
indexresource-value-index
indexcompartment-search-param-value-index
indexcompartment-resource-type-index
indexactive-search-params
indextx-success-index
indextx-error-index
indext-by-instant-index
indexresource-as-of-index
indextype-as-of-index
indexsystem-as-of-index
indexpatient-last-change-index
indextype-stats-index
indexsystem-stats-index
indexcql-bloom-filter
indexcql-bloom-filter-by-t
transactiondefault
resourcedefault

Response

The response will be always async according the Asynchronous Interaction Request Pattern from FHIR R5.

Using blazectl

The $compact operation can be executed using blazectl.

Example

sh
blazectl --server http://localhost:8080/fhir compact index resource-as-of-index