Changeset View
Changeset View
Standalone View
Standalone View
swh/storage/interface.py
Show First 20 Lines • Show All 1,304 Lines • ▼ Show 20 Lines | def diff_revision(self, revision, track_renaming=False): | ||||
... | ... | ||||
@remote_api_endpoint("clear/buffer") | @remote_api_endpoint("clear/buffer") | ||||
def clear_buffers(self, object_types: Optional[Iterable[str]] = None) -> None: | def clear_buffers(self, object_types: Optional[Iterable[str]] = None) -> None: | ||||
"""For backend storages (pg, storage, in-memory), this is a noop operation. For proxy | """For backend storages (pg, storage, in-memory), this is a noop operation. For proxy | ||||
storages (especially filter, buffer), this is an operation which cleans internal | storages (especially filter, buffer), this is an operation which cleans internal | ||||
state. | state. | ||||
@remote_api_endpoint("flush") | |||||
def flush(self, object_types: Optional[Iterable[str]] = None) -> Dict: | |||||
"""For backend storages (pg, storage, in-memory), this is expected to be a noop | |||||
operation. For proxy storages (especially buffer), this is expected to trigger | |||||
actual writes to the backend. | |||||
""" | """ | ||||
... | ... |