Skip to content
Snippets Groups Projects
Verified Commit d826f754 authored by Antoine R. Dumont's avatar Antoine R. Dumont
Browse files

swh.storage.api.client: Permit to specify the query timeout option

Related T1061
parent 77e69ecf
No related branches found
Tags v0.0.101
No related merge requests found
......@@ -15,7 +15,7 @@ Build-Depends: debhelper (>= 9),
python3-requests,
python3-setuptools,
python3-sqlalchemy (>= 1.0),
python3-swh.core (>= 0.0.37~),
python3-swh.core (>= 0.0.40~),
python3-swh.model (>= 0.0.18~),
python3-swh.objstorage (>= 0.0.17~),
python3-swh.scheduler (>= 0.0.14~),
......@@ -25,7 +25,7 @@ Homepage: https://forge.softwareheritage.org/diffusion/DSTO/
Package: python3-swh.storage
Architecture: all
Depends: python3-swh.core (>= 0.0.28~),
Depends: python3-swh.core (>= 0.0.40~),
python3-swh.model (>= 0.0.18~),
python3-swh.objstorage (>= 0.0.17~),
${misc:Depends},
......
swh.core >= 0.0.37
swh.core >= 0.0.40
swh.model >= 0.0.18
swh.objstorage >= 0.0.17
swh.scheduler >= 0.0.14
......@@ -11,8 +11,9 @@ from ..exc import StorageAPIError
class RemoteStorage(SWHRemoteAPI):
"""Proxy to a remote storage API"""
def __init__(self, url):
super().__init__(api_exception=StorageAPIError, url=url)
def __init__(self, url, timeout=None):
super().__init__(
api_exception=StorageAPIError, url=url, timeout=timeout)
def check_config(self, *, check_write):
return self.post('check_config', {'check_write': check_write})
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment