swh.storage.proxies.blocking package#
Submodules#
- swh.storage.proxies.blocking.cli module
- swh.storage.proxies.blocking.db module
BlockingState
BlockingStatus
BlockingRequest
RequestHistory
BlockingLogEntry
BlockedOrigin
BlockingDb
get_urls_to_check()
BlockingAdmin
BlockingAdmin.create_request()
BlockingAdmin.find_request()
BlockingAdmin.find_request_by_id()
BlockingAdmin.get_requests()
BlockingAdmin.set_origins_state()
BlockingAdmin.get_states_for_request()
BlockingAdmin.find_blocking_states()
BlockingAdmin.delete_blocking_states()
BlockingAdmin.record_history()
BlockingAdmin.get_history()
BlockingAdmin.get_log()
BlockingQuery
Module contents#
- swh.storage.proxies.blocking.blocking_overhead_timer(method_name: str) DifferentialTimer [source]#
Return a properly setup DifferentialTimer for
method_name
of the storage
- class swh.storage.proxies.blocking.BlockingProxyStorage(storage: Dict | StorageInterface, db: str | None = None, blocking_db: str | None = None, min_pool_conns: int = 1, max_pool_conns: int = 5)[source]#
Bases:
object
Blocking storage proxy
This proxy prevents visits from a known list of origins to be performed at all.
It uses a specific PostgreSQL database (which for now is colocated with the swh.storage PostgreSQL database), the access to which is implemented in the
db
submodule.Sample configuration
- origin_visit_add(visits: List[OriginVisit]) Iterable[OriginVisit] [source]#