summaryrefslogtreecommitdiff
path: root/python/examples/direct
diff options
context:
space:
mode:
Diffstat (limited to 'python/examples/direct')
-rw-r--r--python/examples/direct/declare_queues.py6
-rw-r--r--python/examples/direct/listener.py4
2 files changed, 4 insertions, 6 deletions
diff --git a/python/examples/direct/declare_queues.py b/python/examples/direct/declare_queues.py
index e64ad678b8..0160f66a1d 100644
--- a/python/examples/direct/declare_queues.py
+++ b/python/examples/direct/declare_queues.py
@@ -1,6 +1,6 @@
#!/usr/bin/env python
"""
- config_direct_exchange.py
+ declare_queues.py
Creates and binds a queue on an AMQP direct exchange.
@@ -33,9 +33,6 @@ session.session_open()
#----- Create a queue -------------------------------------
-# Create a queue named "listener" on channel 1, and bind it
-# to the "amq.direct" exchange.
-#
# queue_declare() creates an AMQP queue, which is held
# on the broker. Published messages are sent to the AMQP queue,
# from which messages are delivered to consumers.
@@ -51,3 +48,4 @@ session.queue_bind(exchange="amq.direct", queue="message_queue", routing_key="ro
session.session_close()
+
diff --git a/python/examples/direct/listener.py b/python/examples/direct/listener.py
index e5eee72637..8324cc76a6 100644
--- a/python/examples/direct/listener.py
+++ b/python/examples/direct/listener.py
@@ -64,9 +64,9 @@ session.session_open()
consumer_tag = "consumer1"
queue = client.queue(consumer_tag)
-# Call message_consume() to tell the broker to deliver messages
+# Call message_subscribe() to tell the broker to deliver messages
# from the AMQP queue to this local client queue. The broker will
-# start delivering messages as soon as message_consume() is called.
+# start delivering messages as soon as message_subscribe() is called.
session.message_subscribe(queue="message_queue", destination=consumer_tag)
session.message_flow(consumer_tag, 0, 0xFFFFFFFF) # Kill these?