Sparta rabbit library
Project description
sparta-rabbit
Sparta rabbit library.
Usage
import sparta.rabbit
con_data = sparta.rabbit.RabbitMQConnectionData(
host="localhost",
username="guest",
password="guest",
)
publisher = sparta.rabbit.RabbitMQPublisher(con_data)
await publisher.create_queue("hello")
await publisher.publish_to_queue("hello", "hi there")
consumer = sparta.rabbit.RabbitMQConsumer(con_data)
await consumer.listen_to_queue("hello", lambda message: print(f"Received {message}"), timeout=10)
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
sparta-rabbit-0.0.2.tar.gz
(6.3 kB
view hashes)
Built Distribution
Close
Hashes for sparta_rabbit-0.0.2-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | fd4534bb6ba417edc806a5d95562f0eb2b1cbf90f0b9d1231f19853eb93a2076 |
|
MD5 | 19f439b90b1de4167b10c6a18166ea9c |
|
BLAKE2b-256 | 0d22768a5a1029a19ad3c779331903c03ca86b33d97777682eef1fee9822b6d9 |