You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@qpid.apache.org by "Rajkumar (JIRA)" <ji...@apache.org> on 2014/10/28 08:04:34 UTC
[jira] [Commented] (QPID-6191) Unable to communicate to Windows
Azure using qpid messaging
[ https://issues.apache.org/jira/browse/QPID-6191?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14186489#comment-14186489 ]
Rajkumar commented on QPID-6191:
--------------------------------
I am using Azure cloud service bus to send and receive messages using AMQP protocol. I have installed proton-c libraries in my debian-linux. I tried the below program to send and receive message from the queue. My requirement is instead of queue I have use topics. Please anyone give me a sample program to use topics in Azure cloud.
import sys, optparse
from proton import *
messenger = Messenger()
message = Message()
message.address = "amqps://owner:<<key>>@namespace.servicebus.windows.net/queuename"
message.body = "sending message to the queue"
messenger.put(message)
messenger.send()
Instead of queuename in above url if I give the topic name then the program running forever. I dont know what is happening in that process. I am new to python programming, please help me.
> Unable to communicate to Windows Azure using qpid messaging
> -----------------------------------------------------------
>
> Key: QPID-6191
> URL: https://issues.apache.org/jira/browse/QPID-6191
> Project: Qpid
> Issue Type: Bug
> Components: Qpid Examples
> Reporter: Rajkumar
>
> import sys
> from qpid.messaging import *
> if len(sys.argv)<2:
> broker = "***namespace***.servicebus.windows.net"
> else:
> broker = sys.argv[1]
> if len(sys.argv)<3:
> address = "**queuename**"
> else:
> address = sys.argv[2]
> connection = Connection(broker)
> connection.username = "owner"
> connection.password = "****passwordkey****"
> connection.protocol = "amqp1.0"
> try:
> connection.open()
> session = connection.session()
> sender = session.sender(address)
> receiver = session.receiver(address)
> sender.send(Message("Hello world!"));
> message = receiver.fetch()
> print message.content
> session.acknowledge()
> except MessagingError,m:
> print m
> connection.close()
> I have tried the above code to send message to Azure queue. But I got "client: 0-10, server: 0-0" when open a connection. Please anyone help me.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@qpid.apache.org
For additional commands, e-mail: dev-help@qpid.apache.org