使用 rabbitmq-amqp1.0-client 连接到 Azure 服务总线时出现问题
Problem connecting to Azure Service Bus using rabbitmq-amqp1.0-client
我正在尝试使用此 erlang 客户端连接 Azure 服务总线 (AMQP 1.0):https://github.com/rabbitmq/rabbitmq-amqp1.0-client
长生不老药包装库 https://github.com/pma/amqp 似乎不使用 AMQP 1.0。所以我想直接使用erlang客户端。
我做了以下事情:
git clone https://github.com/rabbitmq/rabbitmq-amqp1.0-client.git
cd rabbitmq-amqp1.0-client
make
make shell
然后我根据 https://github.com/rabbitmq/rabbitmq-amqp1.0-client
中的自述文件创建了一个配置
OpnConf = #{address => Hostname,
port => Port,
hostname => <<"abc-shankardevy.servicebus.windows.net">>,
tls_opts => {secure_port, [{versions, ['tlsv1.1']}]},
container_id => <<"test-container">>,
transfer_limit_margin => 100,
sasl => {plain, User, Password}}.
当我尝试按照 README 中的方式打开连接时,出现以下错误。我无法遵循 erlang 错误消息。任何帮助表示赞赏。
{ok, Connection} = amqp10_client:open_connection(OpnConf).
** exception exit: {noproc,{gen_server,call,
[amqp10_client_sup,
{start_child,[#{address =>
'abc-shankardevy.servicebus.windows.net',
container_id => <<"test-container">>,
hostname => <<"abc-shankardevy.servicebus.windows.net">>,
notify => <0.111.0>,port => 5671,
sasl =>
{plain,'RootManageSharedAccessKey',
'mykey'},
tls_opts => {secure_port,[{versions,['tlsv1.1']}]},
transfer_limit_margin => 100}]},
infinity]}}
in function gen_server:call/3 (gen_server.erl, line 223)
in call from amqp10_client_connection:open/1 (src/amqp10_client_connection.erl, line 110)
首先尝试 "starting" 应用程序:
application:ensure_all_started(amqp10_client).
抱怨找不到某个进程(noproc
),也就是那个叫amqp10_client_sup
的进程。此过程在应用程序启动时启动,由 this piece of code:
-module(amqp10_client_app).
-behaviour(application).
-export([start/2,
stop/1]).
start(_Type, _Args) ->
amqp10_client_sup:start_link().
我正在尝试使用此 erlang 客户端连接 Azure 服务总线 (AMQP 1.0):https://github.com/rabbitmq/rabbitmq-amqp1.0-client
长生不老药包装库 https://github.com/pma/amqp 似乎不使用 AMQP 1.0。所以我想直接使用erlang客户端。
我做了以下事情:
git clone https://github.com/rabbitmq/rabbitmq-amqp1.0-client.git
cd rabbitmq-amqp1.0-client
make
make shell
然后我根据 https://github.com/rabbitmq/rabbitmq-amqp1.0-client
中的自述文件创建了一个配置OpnConf = #{address => Hostname,
port => Port,
hostname => <<"abc-shankardevy.servicebus.windows.net">>,
tls_opts => {secure_port, [{versions, ['tlsv1.1']}]},
container_id => <<"test-container">>,
transfer_limit_margin => 100,
sasl => {plain, User, Password}}.
当我尝试按照 README 中的方式打开连接时,出现以下错误。我无法遵循 erlang 错误消息。任何帮助表示赞赏。
{ok, Connection} = amqp10_client:open_connection(OpnConf).
** exception exit: {noproc,{gen_server,call,
[amqp10_client_sup,
{start_child,[#{address =>
'abc-shankardevy.servicebus.windows.net',
container_id => <<"test-container">>,
hostname => <<"abc-shankardevy.servicebus.windows.net">>,
notify => <0.111.0>,port => 5671,
sasl =>
{plain,'RootManageSharedAccessKey',
'mykey'},
tls_opts => {secure_port,[{versions,['tlsv1.1']}]},
transfer_limit_margin => 100}]},
infinity]}}
in function gen_server:call/3 (gen_server.erl, line 223)
in call from amqp10_client_connection:open/1 (src/amqp10_client_connection.erl, line 110)
首先尝试 "starting" 应用程序:
application:ensure_all_started(amqp10_client).
抱怨找不到某个进程(noproc
),也就是那个叫amqp10_client_sup
的进程。此过程在应用程序启动时启动,由 this piece of code:
-module(amqp10_client_app).
-behaviour(application).
-export([start/2,
stop/1]).
start(_Type, _Args) ->
amqp10_client_sup:start_link().