Skip to main content

Library for using RabbitMQ with python (async/sync).

Project description

EasyMQ

Library for using RabbitMQ with python.

This library was made to create a unified interface for async and sync message queues in Python. This project was made to manage queues between an async server and a sync server.

To be implemented:

  • Message class
  • More advanced features (these will be implemented as needed)

Sync

from easy_mq.queue import Queue

Queue.connect('url')

q = Queue('queue_name')
q.put('message') 

for message in q.revivaid():
    print(message)

Async

from easy_mq.queue import AsyncQueue

AsyncQueue.connect('url')

async def main():

    q = AsyncQueue('queue_name')
    q.put('message') 

    async for message in q.revivaid():
        print(message)

import asyncio 
asyncio.run(main())

To run tests

source scripts/test.sh

Project details


Download files

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

Files for easy-mq, version 0.1.2
Filename, size File type Python version Upload date Hashes
Filename, size easy_mq-0.1.2-py3-none-any.whl (3.8 kB) File type Wheel Python version py3 Upload date Hashes View hashes
Filename, size easy_mq-0.1.2.tar.gz (2.8 kB) File type Source Python version None Upload date Hashes View hashes

Supported by

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