Skip to main content
https://travis-ci.org/asahaf/rabbitleap.svg?branch=master

RabbitLeap

RabbitLeap is a simple RabbitMQ consuming framework. It’s built on top of Pika, a RabbitMQ client library for Python.

Features

  • Automatically recovers from connection failures

  • Configurable retry policy for handing failures

  • Automatically route messages to handlers, based on custom logic and different message properties

Installation

$ pip install rabbitleap

Hello, world

from rabbitleap.consumer import Consumer
from rabbitleap.handling import MessageHandler


class RabbitEatHandler(MessageHandler):

    def handle(self):
        print('rabbit eat: {}'.format(self.envelope.payload.decode('utf-8')))

consumer_queue_name = 'consumer_queue'
amqp_url = r'amqp://guest:guest@localhost:5672/%2f'

consumer = Consumer(amqp_url=amqp_url, queue_name=consumer_queue_name)
# route message of type `rabbit.eat` to RabbitEatHandler
consumer.add_handler(r'rabbit\.eat', RabbitEatHandler)

try:
    consumer.start()
except KeyboardInterrupt:
    consumer.stop()

Documentation

Documentation and resources are available at https://rabbitleap.readthedocs.io

Metadata

Release files for rabbitleap 0.1.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for rabbitleap 0.1.1
File Size Uploaded
rabbitleap-0.1.1.tar.gz 28.3 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for rabbitleap 0.1.1
File Interpreter ABI Platform
rabbitleap-0.1.1-py2.py3-none-any.whl Python 3, Python 2 none any Details

Total release size: 47.6 kB

Release files / rabbitleap-0.1.1.tar.gz

Download URL rabbitleap-0.1.1.tar.gz
Size 28.3 kB
Tags Source
SHA-256 checksum
How to use checksums
1537fb7a9ebaa50f578336f533bab455c26e2beb6a9ea733badc2593c93d47bc
BLAKE2b-256 checksum
How to use checksums
41801e39cf4422885d0c6ea93f4791f05e3b38b19d48d60636335240b3b0f13d
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/1.11.0 pkginfo/1.4.2 requests/2.19.1 setuptools/40.3.0 requests-toolbelt/0.8.0 tqdm/4.26.0 CPython/3.7.0

Release files / rabbitleap-0.1.1-py2.py3-none-any.whl

Download URL rabbitleap-0.1.1-py2.py3-none-any.whl
Size 19.3 kB
Tags Python 2 Python 3
SHA-256 checksum
How to use checksums
39b0177c8a3c81768098fd62e66bcc1577434a2536e5ef0271565475167c5874
BLAKE2b-256 checksum
How to use checksums
80a06c24fdb17c9aebac71efe54eea8616f985bec5ca35d050f958ade4213aa0
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/1.11.0 pkginfo/1.4.2 requests/2.19.1 setuptools/40.3.0 requests-toolbelt/0.8.0 tqdm/4.26.0 CPython/3.7.0

Release history Release notifications | RSS feed

This release

0.1.1 This release

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page