As we have seen earlier the catalog supports transactions, this means all changes are done in memory first, and then they can be either saved or discarded.
The operations that modify the catalog are just two:
index_document(document)
Index the given document, which must be an instance of the base class CatalogAware.
If it is the later the method get_catalog_indexes() must be implemented, it will return a dictionary with the values to be indexed.
unindex_document(id)
Unindex the document identified by the given external id (see Section 14.4.2).
The API to save or discard the changes is made by these two operations:
save_changes()
Save the changes done so far to the catalog.
abort_changes()
Discard the changes done so far to the catalog.