Skip to main content

Enable zlib_ng on aiohttp

Project description

aiohttp-zlib-ng

CI Status Test coverage percentage

Poetry black pre-commit

PyPI Version Supported Python versions License


Source Code: https://github.com/bdraco/aiohttp-zlib-ng


Enable zlib_ng on aiohttp

zlib is be a bottleneck for aiohttp, especially for websocket connections. aiohttp-zlib-ng replaces usage of zlib in aiohttp with zlib-ng which is a drop-in faster replacement.

If isal is available, this library will try to use isal, and will fallback to the slower zlib_ng if it is not available.

Installation

Install this via pip (or your favorite package manager):

pip install aiohttp-zlib-ng

To install the optional isal speed up:

pip install aiohttp-zlib-ng[isal]

Usage

Enable zlib-ng support in aiohttp by calling enable_zlib_ng

import aiohttp_zlib_ng

aiohttp_zlib_ng.enable_zlib_ng()
aiohttp_zlib_ng.disable_zlib_ng()

Contributors ✨

Thanks goes to these wonderful people (emoji key):

This project follows the all-contributors specification. Contributions of any kind welcome!

Credits

This package was created with Copier and the browniebroke/pypackage-template project template.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

aiohttp_zlib_ng-0.3.1.tar.gz (8.4 kB view hashes)

Uploaded Source

Built Distribution

aiohttp_zlib_ng-0.3.1-py3-none-any.whl (8.1 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page