Skip to content
Abstracted messaging layer
Python
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
docs
pyapp_ext/messaging
sample
tests
.gitignore
.pre-commit-config.yaml
LICENSE
README.rst
docker-compose.yaml
setup.cfg
setup.py

README.rst

pyApp - Messaging

Let use handle the boring stuff!

The messaging extension provides an abstract interface to various messaging implementations. This lets your application seamlessly migrate from AMQP to SQS without any changes to your main application code.

Note

The primary focus of work is on asyncio based queues.

Installation

Install using pip or pipenv:

# Using pip
pip install pyapp-Messaging

# Using pipenv
pipenv install pyapp-Messaging

Usage

This library is easiest used with the injection framework eg:

from pyapp.injection import inject, Args
from pyapp_ext.messaging import MessageReceiver

@inject
def my_function(queue: MessageReceiver = Args(name="job_queue")):
    queue.send_message("Do job A")

or using asyncio:

from pyapp.injection import inject, Args
from pyapp_ext.messaging.asyncio import MessageSender

@inject
async def my_function(sender: MessageSender = Args(name="job_queue")):
    await sender.send("Do job A")

API

You can’t perform that action at this time.