Observed since 21 Oct, 11:41 UTC
No superseded metadata states collected. Unchanged observations do not create new revisions.
Python implementation of the Circuit Breaker pattern.
aiobreaker is a Python implementation of the Circuit Breaker pattern,
described in Michael T. Nygard's book Release It!_.
Circuit breakers exist to allow one subsystem to fail without destroying the entire system. This is done by wrapping dangerous operations (typically integration points) with a component that can circumvent calls when the system is not healthy.
This project is a fork of pybreaker_ by Daniel Fernandes Martins that
replaces tornado with native asyncio, originally so I could practice
packaging and learn about that shiny new typing package.
.. _Release It!: https://pragprog.com/titles/mnee2/release-it-second-edition/
.. _pybreaker: https://github.com/danielfm/pybreaker
asyncio supportAll you need is python 3.6 or higher.
To install, simply download from pypi:
.. code:: bash
pip install aiobreaker
The first step is to create an instance of CircuitBreaker for each
integration point you want to protect against.
.. code:: python
from aiobreaker import CircuitBreaker
# Used in database integration points
db_breaker = CircuitBreaker(fail_max=5, reset_timeout=timedelta(seconds=60))
@db_breaker
async def outside_integration():
"""Hits the api"""
...
At that point, go ahead and get familiar with the documentation.
Download counts and popularity will appear here as the collector receives them.
| Version | Published | Direct dependencies | Open version |
|---|---|---|---|
| 1.2.0 | 17 May 2021 | 14 |
This describes our collected data; it is not a security assessment.
Observed since 21 Oct, 11:41 UTC
No superseded metadata states collected. Unchanged observations do not create new revisions.
package:1d83dd20409716c0c6f3958563fb10229bba6202dfe591fa5773a90e80dbeaba