diff --git a/docs/cli.rst b/docs/cli.rst --- a/docs/cli.rst +++ b/docs/cli.rst @@ -4,5 +4,5 @@ ====================== .. click:: swh.storage.cli:storage - :prog: swh storage - :nested: full + :prog: swh storage + :nested: full diff --git a/docs/extrinsic-metadata-specification.rst b/docs/extrinsic-metadata-specification.rst --- a/docs/extrinsic-metadata-specification.rst +++ b/docs/extrinsic-metadata-specification.rst @@ -31,13 +31,15 @@ An authority is uniquely defined by these properties: - * its type, representing the kind of authority, which is one of these values: - * `deposit_client`, for metadata pushed to Software Heritage at the same time - as a software artifact - * `forge`, for metadata pulled from the same source as the one hosting - the software artifacts (which includes package managers) - * `registry`, for metadata pulled from a third-party - * its URL, which unambiguously identifies an instance of the authority type. +* its type, representing the kind of authority, which is one of these values: + + * ``deposit_client``, for metadata pushed to Software Heritage at the same time + as a software artifact + * ``forge``, for metadata pulled from the same source as the one hosting + the software artifacts (which includes package managers) + * ``registry``, for metadata pulled from a third-party + +* its URL, which unambiguously identifies an instance of the authority type. Examples: diff --git a/swh/storage/__init__.py b/swh/storage/__init__.py --- a/swh/storage/__init__.py +++ b/swh/storage/__init__.py @@ -28,13 +28,14 @@ `storage_args`. Args: - cls (str): storage's class, can be: - - ``local`` to use a postgresql database - - ``cassandra`` to use a cassandra database - - ``remote`` to connect to a swh-storage server - - ``memory`` for an in-memory storage, useful for fast tests - - ``filter``, ``buffer``, ... to use specific storage "proxies", see their - respective documentations + cls (str): + storage's class, can be: + - ``local`` to use a postgresql database + - ``cassandra`` to use a cassandra database + - ``remote`` to connect to a swh-storage server + - ``memory`` for an in-memory storage, useful for fast tests + - ``filter``, ``buffer``, ... to use specific storage "proxies", see their + respective documentations args (dict): dictionary with keys Returns: diff --git a/swh/storage/buffer.py b/swh/storage/buffer.py --- a/swh/storage/buffer.py +++ b/swh/storage/buffer.py @@ -94,9 +94,10 @@ """Push contents to write to the storage in the buffer. Following policies apply: - - if the buffer's threshold is hit, flush content to the storage. - - otherwise, if the total size of buffered contents's threshold is hit, - flush content to the storage. + + - if the buffer's threshold is hit, flush content to the storage. + - otherwise, if the total size of buffered contents's threshold is hit, + flush content to the storage. """ stats = self.object_add( diff --git a/swh/storage/cli.py b/swh/storage/cli.py --- a/swh/storage/cli.py +++ b/swh/storage/cli.py @@ -114,8 +114,9 @@ journal (eg. due to a downtime of this later). The configuration file requires the following entries: + - brokers: a list of kafka endpoints (the journal) in which entries will be - added. + added. - storage_dbconn: URL to connect to the storage DB. - prefix: the prefix of the topics (topics will be .). - client_id: the kafka client ID.