summaryrefslogtreecommitdiff
path: root/qpid/python/examples/request-response
diff options
context:
space:
mode:
authorRafael H. Schloming <rhs@apache.org>2008-06-11 21:31:12 +0000
committerRafael H. Schloming <rhs@apache.org>2008-06-11 21:31:12 +0000
commit2becbf6ae901b1c7aecebe95087fd308fc611627 (patch)
treee3d3cef115a248b2d6ccfe84e69ee348a12e9702 /qpid/python/examples/request-response
parent38ac6f27ea2cb49b0161202e13f222875e5e2b44 (diff)
downloadqpid-python-2becbf6ae901b1c7aecebe95087fd308fc611627.tar.gz
replaced example usages of message_flow with the start() method
git-svn-id: https://svn.apache.org/repos/asf/incubator/qpid/trunk@666850 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'qpid/python/examples/request-response')
-rwxr-xr-xqpid/python/examples/request-response/client.py3
-rwxr-xr-xqpid/python/examples/request-response/server.py6
2 files changed, 3 insertions, 6 deletions
diff --git a/qpid/python/examples/request-response/client.py b/qpid/python/examples/request-response/client.py
index 8d40aca5bb..a9ecd5c78f 100755
--- a/qpid/python/examples/request-response/client.py
+++ b/qpid/python/examples/request-response/client.py
@@ -81,8 +81,7 @@ queue = session.incoming(local_queue_name)
# available.
session.message_subscribe(queue=reply_to, destination=local_queue_name)
-session.message_flow(local_queue_name, session.credit_unit.message, 0xFFFFFFFF)
-session.message_flow(local_queue_name, session.credit_unit.byte, 0xFFFFFFFF)
+queue.start()
# Send some messages to the server's request queue
diff --git a/qpid/python/examples/request-response/server.py b/qpid/python/examples/request-response/server.py
index 99b1431509..05ee051c57 100755
--- a/qpid/python/examples/request-response/server.py
+++ b/qpid/python/examples/request-response/server.py
@@ -60,9 +60,9 @@ session.exchange_bind(exchange="amq.direct", queue="request", binding_key="reque
local_queue_name = "local_queue"
session.message_subscribe(queue="request", destination=local_queue_name)
-session.message_flow(local_queue_name, session.credit_unit.message, 0xFFFFFFFF)
-session.message_flow(local_queue_name, session.credit_unit.byte, 0xFFFFFFFF)
+queue = session.incoming(local_queue_name)
+queue.start()
# Remind the user to start the client program
@@ -72,8 +72,6 @@ sys.stdout.flush()
# Respond to each request
-queue = session.incoming(local_queue_name)
-
# If we get a message, send it back to the user (as indicated in the
# ReplyTo property)