Skip to content

Latest commit

 

History

History
executable file
·
67 lines (35 loc) · 1.2 KB

examples.rst

File metadata and controls

executable file
·
67 lines (35 loc) · 1.2 KB

Examples

Generic showcase examples

.. literalinclude:: ../examples/showcase.py


Usage as decorator

.. literalinclude:: ../examples/decorator.py


Usage as context manager

.. literalinclude:: ../examples/context_manager.py


Timeout retry cycle limit

.. literalinclude:: ../examples/timeout_limit.py


Retry failed HTTP requests

.. literalinclude:: ../examples/http_request.py


Retry failed HTTP requests using asyncio + aiohttp

.. literalinclude:: ../examples/http_asyncio.py


Whitelisting custom errors

.. literalinclude:: ../examples/whitelisting_errors.py


Blacklisting custom errors

.. literalinclude:: ../examples/blacklisting_errors.py


Constant backoff strategy

.. literalinclude:: ../examples/constant_backoff.py


Fibonacci backoff strategy

.. literalinclude:: ../examples/fibonacci_backoff.py


Exponential backoff strategy

.. literalinclude:: ../examples/exponential_backoff.py