swh.counters.history module

class swh.counters.history.History(prometheus_host: str, prometheus_port: int, live_data_start: int, cache_base_directory: str, interval: str = '12h', prometheus_collection: str = 'swh_archive_object_total', query_range_uri='/api/v1/query_range', labels: Dict[str, str] = {})[source]

Bases: object

Manage the historical data of the counters

get_history(cache_file: str) Dict[source]
refresh_history(cache_file: str, objects: List[str], static_file: Optional[str] = None)[source]