diff options
Diffstat (limited to 'qpid/python/hello-world')
| -rwxr-xr-x | qpid/python/hello-world | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/qpid/python/hello-world b/qpid/python/hello-world new file mode 100755 index 0000000000..b05873dff3 --- /dev/null +++ b/qpid/python/hello-world @@ -0,0 +1,11 @@ +#!/usr/bin/env python +import qpid +from qpid.client import Client +from qpid.content import Content + +client = Client("127.0.0.1", 5672, qpid.spec.load("../specs/amqp.0-9.xml")) +client.start({"LOGIN": "guest", "PASSWORD": "guest"}) +ch = client.channel(1) +ch.channel_open() +ch.message_transfer(destination="amq.direct", routing_key="asdf", + body="hello world") |
