mirror of
https://github.com/internetarchive/warcprox.git
synced 2025-01-18 13:22:09 +01:00
Document compressed_blocks
in api.rst
This was introduced in #177 for brozzler, but isn't documented anywhere.
This commit is contained in:
parent
fbed60ff38
commit
66ad775188
16
api.rst
16
api.rst
@ -186,6 +186,22 @@ to evaluate the block rules. In particular, this circumstance prevails when the
|
|||||||
browser controlled by brozzler is requesting images, javascript, css, and so
|
browser controlled by brozzler is requesting images, javascript, css, and so
|
||||||
on, embedded in a page.
|
on, embedded in a page.
|
||||||
|
|
||||||
|
``compressed_blocks`` (string)
|
||||||
|
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||||
|
If the ``blocks`` header is large, it may be useful or necessary to compress it.
|
||||||
|
``compressed_blocks`` is a string containing a zlib and base64-encoded
|
||||||
|
``blocks`` list. If both ``blocks`` and ``compressed_blocks`` are provided,
|
||||||
|
warcprox will use the value of ``compressed_blocks``, however this behavior
|
||||||
|
is not guaranteed.
|
||||||
|
|
||||||
|
Example::
|
||||||
|
|
||||||
|
Warcprox-Meta: {"compressed_blocks": "eJwVykEKgCAQQNGryKwt90F0kGgxlZSgzuCMFIR3r7b//fkBkVoUBgMbJetvTBy9de5U5cFBs+aBnRKG/D8J44XF91XAGpC6ipaQj58u7iIdIfd88oSbBsrjF6gqtOUFJ5YjwQ=="}
|
||||||
|
|
||||||
|
Is equivalent to::
|
||||||
|
|
||||||
|
{"blocks": [{"ssurt": "com,example,//http:/"}, {"domain": "malware.us", "substring": "wp-login.php?action=logout"}]}
|
||||||
|
|
||||||
``stats`` (dictionary)
|
``stats`` (dictionary)
|
||||||
~~~~~~~~~~~~~~~~~~~~~~
|
~~~~~~~~~~~~~~~~~~~~~~
|
||||||
``stats`` is a dictionary with only one field understood by warcprox,
|
``stats`` is a dictionary with only one field understood by warcprox,
|
||||||
|
Loading…
x
Reference in New Issue
Block a user