Skip to main content
Help us improve PyPI by participating in user testing. All experience levels needed!

UNKNOWN

Project description

Implements nsq client for asyncio with async/await feature.

Documentation is available at http://aio.errorist.io/aionsq.

Installation

python -m pip install aionsq

Usage

Publish message to a nsq:

from aionsq.http import NSQWriter
writer = NSQWriter('http://120.0.0.1:4567')
await writer.publish('test', 'hello world 2')

Connect directly to a nsq daemon:

from aionsq.tcp import NSQReader
reader = NSQReader('http://120.0.0.1:4567', 'topic1', 'chan1')

@reader.subscribe('test')
async def consumer(msg):
    msg.success()

await reader.start()

Request nsq lookup:

from aionsq import NSQLookup
lookup = NSQLookup('http://120.0.0.1:4567')
info = await lookup.info()

Start an authd:

python -m aionsq.authd

Project details


Release history Release notifications

This version
History Node

0.1.0a0

History Node

0.1a0

Download files

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

Filename, size & hash SHA256 hash help File type Python version Upload date
aionsq-0.1.0a0-py2.py3-none-any.whl (16.5 kB) Copy SHA256 hash SHA256 Wheel py2.py3 May 26, 2016
aionsq-0.1.0a0.tar.gz (26.1 kB) Copy SHA256 hash SHA256 Source None May 26, 2016

Supported by

Elastic Elastic Search Pingdom Pingdom Monitoring Google Google BigQuery Sentry Sentry Error logging CloudAMQP CloudAMQP RabbitMQ AWS AWS Cloud computing Fastly Fastly CDN DigiCert DigiCert EV certificate StatusPage StatusPage Status page