Skip to main content

upy-rabbitmq

GitHub Org's stars PyPI - Python Version PyPI - License PyPI GitHub last commit



How to install?

pip install upy-rabbitmq

Config

Add an environment variation called RABBITMQ_URL in your project's .env file.

RABBITMQ_URL=amqp://user:password@remote.server.com:port//vhost

Callback Class

callback.py

import time
from upy_rabbitmq.callback import CallbackProcess

class MyCallBack(CallbackProcess):

    def process(self):
        time.sleep(5)
        print(self.body.decode())

Start Queue

worker.py

from upy_rabbitmq.worker import UpyMQWorker

worker = UpyMQWorker()
worker.start_queue(
    key="key",
    callback=MyCallBack
)

New Task

client.py

from upy_rabbitmq.client import UpyMQClient

client = UpyMQClient()
client.new_task(
    key="key",
    message="Hello"
)

Contributing

Contributions are what make the open source community such an amazing place to learn, inspire, and create. Any contributions you make are greatly appreciated.

  1. Fork the Project
  2. Create your Feature Branch (git checkout -b feature/AmazingFeature)
  3. Commit your Changes (git commit -m 'Add some AmazingFeature')
  4. Push to the Branch (git push origin feature/AmazingFeature)
  5. Open a Pull Request

Commit Style

  • ⚙️ FEATURE
  • 📝 PEP8
  • 📌 ISSUE
  • 🪲 BUG
  • 📘 DOCS
  • 📦 PyPI
  • ❤️️ TEST
  • ⬆️ CI/CD
  • ⚠️ SECURITY

License

Distributed under the MIT License. See LICENSE for more information.

Metadata

Release files for upy-rabbitmq 0.0.6

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

Source distribution (sdist)

Source distribution for upy-rabbitmq 0.0.6
File Size Uploaded
upy-rabbitmq-0.0.6.tar.gz 3.7 kB Details

Built distribution (wheel)

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

Total release size: 8.2 kB

Release files / upy-rabbitmq-0.0.6.tar.gz

Download URL upy-rabbitmq-0.0.6.tar.gz
Size 3.7 kB
Tags Source
SHA-256 checksum
How to use checksums
b06d69e28eec6bfa71017337e66b4482dbbe9804aac4ca2015c1c4ea2adcff4d
BLAKE2b-256 checksum
How to use checksums
d8970e5f234698f5cd57c8f09478b031a9141bb5f0b65f59f2b44315e309f43a
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.2 CPython/3.9.16

Release files / upy_rabbitmq-0.0.6-py2.py3-none-any.whl

Download URL upy_rabbitmq-0.0.6-py2.py3-none-any.whl
Size 4.6 kB
Tags Python 2 Python 3
SHA-256 checksum
How to use checksums
7498b03a7e0cf87fef8f06af745a27bc8a1a721fca155cc8cb99a87ea3cb4c79
BLAKE2b-256 checksum
How to use checksums
14bda4a89bbe8174e595f14e8cb621ff1f3eea0d7b2d709f6e54390225fc5123
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.2 CPython/3.9.16

Release history Release notifications | RSS feed

This release

0.0.6 This release

2 release files

0.0.5

2 release files

0.0.4

2 release files

0.0.3

2 release files

0.0.2

2 release files

0.0.1

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