尝试运行 hello world 示例以将某些内容放在队列中,创建一个队列......每当我调用 azure 时,我都会收到错误消息。
这是代码:
from azure.servicebus import *
bus_service = ServiceBusService(service_namespace='testtest', account_key='my_access_token', issuer='my_issuer')
bus_service.create_topic('mytopic')
这是我回来的错误:
$ /c/Python27/python pythontest.py
Traceback (most recent call last):
File "pythontest.py", line 4, in <module>
bus_service.create_topic('mytopic')
File "c:\Python27\lib\site-packages\azure\servicebus\servicebusservice.py", line 1
42, in create_topic
request.headers = _update_service_bus_header(request, self.account_key, self.iss
uer)
File "c:\Python27\lib\site-packages\azure\servicebus\__init__.py", line 185, in _u
pdate_service_bus_header
request.headers.append(('Authorization', _sign_service_bus_request(request, acco
unt_key, issuer)))
File "c:\Python27\lib\site-packages\azure\servicebus\__init__.py", line 192, in _s
ign_service_bus_request
return 'WRAP access_token="' + _get_token(request, account_key, issuer) + '"'
File "c:\Python27\lib\site-packages\azure\servicebus\__init__.py", line 233, in _g
et_token
connection.send(request_body)
File "c:\Python27\lib\site-packages\azure\http\winhttp.py", line 313, in send
self._httprequest.send(request_body)
File "c:\Python27\lib\site-packages\azure\http\winhttp.py", line 198, in send
ctypes.memmove(safearray.pvdata, request, len(request))
WindowsError: exception: access violation writing 0x0000000000000000
无论我将某些内容放在队列上还是创建队列、创建主题、向主题发送消息等,它总是给我同样的错误。
有任何想法吗?