This repository is private.
All pages are served over SSL and all pushing and pulling is done over SSH.
No one may fork, clone, or view it unless they are added as a member.
Every repository with this icon (
) is private.
Every repository with this icon (
This repository is public.
Anyone may fork, clone, or view it.
Every repository with this icon (
) is public.
Every repository with this icon (
flopsy /
| name | age | message | |
|---|---|---|---|
| |
AUTHORS | Fri Jun 26 15:09:52 -0700 2009 | |
| |
LICENSE | Thu Jun 25 09:36:36 -0700 2009 | |
| |
README | Fri Jun 26 15:09:52 -0700 2009 | |
| |
flopsy.py | Fri Jun 26 15:09:52 -0700 2009 |
README
Flopsy
======
A very simple way to interact with python AMQPlib. For my case I'm using
RabbitMQ as my implementation but it should work with others.
settings.py
-----------
AMQP_SERVER = '24.143.38.241'
AMQP_PORT = 5672
AMQP_USER = 'guest'
AMQP_PASSWORD = 'guest'
AMQP_VHOST = '/'
Consumer
--------
>>> import flopsy
>>> consumer = flopsy.Consumer()
>>> def message_callback(message):
... print 'Recieved: ' + message.body
... consumer.channel.basic_ack(message.delivery_tag)
...
>>> consumer.register('message_to_print', message_callback)
>>> consumer.wait()
Publisher
---------
>>> import flopsy
>>> publisher = flopsy.Publisher()
>>> publisher.publish('messages_to_print', 'Test message!')






