Skip to main content

Redis async client.

Project description

Installation

pip install redis-async-client

Usage Async

from redis_async_client import AsyncRedisClient, RedisSettings

redis_settings = RedisSettings()
pool: redis_async.ConnectionPool = redis_settings.make_pool()
async with redis_async.Redis(connection_pool=pool) as conn:
    async_client = AsyncRedisClient(conn)
    data = await async_client.health_check()
    assert data == {'test': 'test'}

or

from redis_async_client import RedisSettings, get_redis_connection

redis_settings = RedisSettings()
async for client in get_redis_connection(redis_settings):
    data = await client.health_check()
    assert data == {'test': 'test'}

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

redis_async_client-0.1.0.tar.gz (4.5 kB view hashes)

Uploaded Source

Built Distribution

redis_async_client-0.1.0-py3-none-any.whl (5.7 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