# -*- coding: utf-8 -*-
from setuptools import setup

packages = \
['hyx',
 'hyx.bulkhead',
 'hyx.circuitbreaker',
 'hyx.common',
 'hyx.fallback',
 'hyx.ratelimit',
 'hyx.retry',
 'hyx.timeout']

package_data = \
{'': ['*']}

setup_kwargs = {
    'name': 'hyx',
    'version': '0.0.2',
    'description': 'Lightweight fault tolerance primitives for your modern Python microservices',
    'long_description': '<p align="center">\n  <img loading="lazy" src="https://raw.githubusercontent.com/roma-glushko/hyx/main/img/hyx-logo.png" alt="Hyx">\n</p>\n<p align="center">\n    <em>🧘\u200d♂️️Lightweight fault tolerance primitives for your resilient and modern Python microservices</em>\n</p>\n<p align="center">\n<a href="https://pypi.org/project/hyx" target="_blank">\n    <img loading="lazy" src="https://img.shields.io/pypi/v/hyx?color=%2318afba&label=pypi%20package" alt="Package Version">\n</a>\n<a href="https://pypi.org/project/hyx" target="_blank">\n    <img loading="lazy" src="https://img.shields.io/pypi/dm/hyx?color=%2318afba" alt="Downloads">\n</a>\n<a href="https://pypi.org/project/hyx" target="_blank">\n  <img loading="lazy" src="https://img.shields.io/pypi/pyversions/hyx.svg?color=%2318afba" alt="Supported Python Versions">\n</a>\n\n<br/>\n\n<a href="https://hyx.readthedocs.io/en/latest/?badge=latest">\n    <img loading="lazy" src="https://readthedocs.org/projects/hyx/badge/?version=latest&color=%2318afba" alt=\'Documentation Status\' />\n</a>\n  \n<a href="https://github.com/roma-glushko/hyx/actions/workflows/tests.yml">\n    <img loading="lazy" src="https://github.com/roma-glushko/hyx/actions/workflows/tests.yml/badge.svg?branch=main" alt=\'Test Status\' />\n</a>\n\n<a href="https://app.codecov.io/github/roma-glushko/hyx">\n    <img loading="lazy" src="https://img.shields.io/codecov/c/gh/roma-glushko/hyx" alt="Coverage" />\n</a>\n\n</p>\n\n---\n\n**Hyx** (/ˈhʌɪx/) is a set of well-known stability patterns that are commonly needed\nwhen you build [microservice-based](https://en.wikipedia.org/wiki/Microservices) applications.\nHyx is meant to be [Hystrix (Java)](https://github.com/Netflix/Hystrix), [resilience4j (Java)](https://github.com/resilience4j/resilience4j) or [Polly (C#)](https://github.com/App-vNext/Polly) but for the Python world.\n\n## Key Features\n\n- Implements five commonly used resiliency patterns with various configurations based on advice and experience of industry leaders (e.g. AWS, Google, Netflix)\n- Idiomatic Pythonic implementation based on [decorators](https://realpython.com/primer-on-python-decorators) and [context managers](https://realpython.com/python-with-statement)\n- [AsyncIO](https://docs.python.org/3/library/asyncio.html) Native Implementation\n- Lightweight. Readable Codebase. High Test Coverage\n\n## Requirements\n\n- Python 3.9+\n- AsyncIO-powered applications ([no sync support?](./faq.md))\n\n## Installation\n\nHyx can be installed from [PyPi](https://pypi.org/project/hyx):\n\n``` sh\npip install hyx\n\n# or via poetry\npoetry add hyx\n```\n\n## Component Map\n| Component         | Problem                                                                                                                                                                            | Solution                                                                                                                                                                      | Implemented? |\n|-------------------|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|--------------|\n| 🔁 Retry           | The failures happen sometimes, but they self-recover after a short time                                                                                                            | Automatically retry operation on temporary failures                                                                                                                           | ✅            |\n| 💾 Cache           |                                                                                                                                                                                    |                                                                                                                                                                               |              |\n| ⚡️ Circuit Breaker | When downstream microservices have got overloaded, sending even more load can make the situation only worse.                                                                       | Stop doing requests to your failing microservice temporarily if amount of errors exceeded expected thresholds. Then see if the given time helped the microservice to recover  | ✅            |\n| ⏱ Timeout         | Sometimes operations may take too much time. We cannot wait that long or after that time the success is unlikely                                                                   | Bound waiting to a reasonable amount of time                                                                                                                                  | ✅            |\n| 🚰 Bulkhead        | If executed without control, some code can take too much resources and put down the whole application (and upstream services) or cause slowness of other places of the application | Fix the amount of calls to the code, queue other calls and fail calls that goes beyond your capacity                                                                          | ✅            |\n| 🏃\u200d♂️ Rate Limiter   | The microservice can be requested with any rate even one that can put it down if happens by accident                                                                               | Limit the rate your system can be accessed by                                                                                                                                 | ✅            |\n| 🤝 Fallback        | Nothing can guarantee you that your dependencies will work. What would you do when it\'s failing?                                                                                   | Degrade gracefully by defining some default values or placeholders if your dependencies are down                                                                              | ✅            |\n\n<p align="right">\nInspired by <a href="https://github.com/App-vNext/Polly#resilience-policies" target="_blank">Polly\'s Resiliency Policies</a>\n</p>\n\n## Acknowledgements\n\n- [resilience4j/resilience4j](https://github.com/resilience4j/resilience4j)\n- [Netflix/Hystrix](https://github.com/Netflix/Hystrix)\n- [slok/goresilience](https://github.com/slok/goresilience)\n- [App-vNext/Polly](https://github.com/App-vNext/Polly)\n- [Diplomatiq/resily](https://github.com/Diplomatiq/resily)\n',
    'author': 'Roman Glushko',
    'author_email': 'roman.glushko.m@gmail.com',
    'maintainer': 'None',
    'maintainer_email': 'None',
    'url': 'None',
    'packages': packages,
    'package_data': package_data,
    'python_requires': '>=3.9,<4.0',
}


setup(**setup_kwargs)
