gpt4 book ai didi

erlang - 使用 RabbitMQ 延迟消息交换插件时出现“函数未导出”错误

转载 作者:行者123 更新时间:2023-12-01 01:56:59 25 4
gpt4 key购买 nike

我正在尝试获取 rabbitmq-delayed-message-exchange插件在 centos 7 上工作,但当我尝试发布延迟消息时遇到错误“函数未导出”。尝试运行 erlang:system_time(milli_seconds) 时,错误似乎是 erlang 问题.我根本不了解 erlang,但据我所知,似乎 erlang 模块要么未导入,要么未安装。任何帮助都会很棒! :D

版本

  • rabbitmq: 3.6.5
  • rabbitmq_delayed_message_exchange:0.0.1
  • 二郎:R16B03-1

  • RabbitMQ 日志
    =ERROR REPORT==== 28-Sep-2016::15:51:59 ===
    ** Generic server rabbit_delayed_message terminating
    ** Last message in was {delay_message,
    {exchange,
    {resource,<<"/">>,exchange,
    <<"papyrus.hopeline.staging.requeue">>},
    'x-delayed-message',true,false,false,
    [{<<"x-delayed-type">>,longstr,<<"direct">>}],
    undefined,undefined,
    {[],[]}},
    {delivery,false,false,<0.4340.2>,
    {basic_message,
    {resource,<<"/">>,exchange,
    <<"papyrus.hopeline.staging.requeue">>},
    [<<"papyrus.hopeline.staging.requeue">>],
    {content,60,
    {'P_basic',undefined,undefined,
    [{<<"x-delay">>,signedint,600000}],
    undefined,undefined,undefined,undefined,undefined,
    undefined,undefined,undefined,undefined,undefined,
    undefined},
    <<32,0,0,0,0,13,7,120,45,100,101,108,97,121,73,0,9,
    39,192>>,
    rabbit_framing_amqp_0_9_1,
    [<<"{\"_id\":\"579f380d9f3a78d60cb2063d\",\"__v\":2,\"created\":\"2016-08-01T11:52:45.346Z\",\"client\":{\"_id\":\"579f380d9f3a78d60cb2063b\"},\"assignedTo\":[{\"_id\":\"57ebd50f9e4a04b45444a639\",\"user\":{\"_id\":\"571e37f0cbd7a8ae2b73e925\",\"name\":\"Jason Royle\"},\"created\":\"2016-09-28T14:34:55.441Z\"},{\"_id\":\"57ebd52b9e4a04b45444a63b\",\"user\":{\"_id\":\"571e37f0cbd7a8ae2b73e925\",\"name\":\"Jason Royle\"},\"created\":\"2016-09-28T14:35:23.292Z\"}],\"assigned\":false}">>]},
    <<85,201,10,44,175,144,74,190,136,41,55,79,176,130,
    253,85>>,
    false},
    undefined,noflow},
    600000}
    ** When Server state == {state,not_set}
    ** Reason for termination ==
    ** {'function not exported',
    [{erlang,system_time,[milli_seconds],[]},
    {rabbit_delayed_message,internal_delay_message,4,
    [{file,"src/rabbit_delayed_message.erl"},{line,179}]},
    {rabbit_delayed_message,handle_call,3,
    [{file,"src/rabbit_delayed_message.erl"},{line,122}]},
    {gen_server,handle_msg,5,[{file,"gen_server.erl"},{line,585}]},
    {proc_lib,init_p_do_apply,3,[{file,"proc_lib.erl"},{line,239}]}]}

    =ERROR REPORT==== 28-Sep-2016::15:51:59 ===
    ** Generic server <0.4340.2> terminating
    ** Last message in was {'$gen_cast',
    {method,
    {'basic.publish',0,
    <<"papyrus.hopeline.staging.requeue">>,
    <<"papyrus.hopeline.staging.requeue">>,
    false,false},
    {content,60,none,
    <<32,0,0,0,0,13,7,120,45,100,101,108,97,121,
    73,0,9,39,192>>,
    rabbit_framing_amqp_0_9_1,
    [<<"{\"_id\":\"579f380d9f3a78d60cb2063d\",\"__v\":2,\"created\":\"2016-08-01T11:52:45.346Z\",\"client\":{\"_id\":\"579f380d9f3a78d60cb2063b\"},\"assignedTo\":[{\"_id\":\"57ebd50f9e4a04b45444a639\",\"user\":{\"_id\":\"571e37f0cbd7a8ae2b73e925\",\"name\":\"Jason Royle\"},\"created\":\"2016-09-28T14:34:55.441Z\"},{\"_id\":\"57ebd52b9e4a04b45444a63b\",\"user\":{\"_id\":\"571e37f0cbd7a8ae2b73e925\",\"name\":\"Jason Royle\"},\"created\":\"2016-09-28T14:35:23.292Z\"}],\"assigned\":false}">>]},
    flow}}
    ** When Server state == {ch,running,rabbit_framing_amqp_0_9_1,2,<0.4153.2>,
    <0.4338.2>,<0.4153.2>,
    <<"172.30.0.13:41896 -> 172.30.0.11:5672">>,
    {lstate,<0.4339.2>,false},
    none,1,
    {[],[]},
    {user,<<"developers">>,
    [administrator],
    [{rabbit_auth_backend_internal,none}]},
    <<"/">>,<<>>,
    {dict,0,16,16,8,80,48,
    {[],[],[],[],[],[],[],[],[],[],[],[],[],[],[],
    []},
    {{[],[],[],[],[],[],[],[],[],[],[],[],[],[],
    [],[]}}},
    {state,
    {dict,0,16,16,8,80,48,
    {[],[],[],[],[],[],[],[],[],[],[],[],[],
    [],[],[]},
    {{[],[],[],[],[],[],[],[],[],[],[],[],[],
    [],[],[]}}},
    erlang},
    {dict,0,16,16,8,80,48,
    {[],[],[],[],[],[],[],[],[],[],[],[],[],[],[],
    []},
    {{[],[],[],[],[],[],[],[],[],[],[],[],[],[],
    [],[]}}},
    {dict,0,16,16,8,80,48,
    {[],[],[],[],[],[],[],[],[],[],[],[],[],[],[],
    []},
    {{[],[],[],[],[],[],[],[],[],[],[],[],[],[],
    [],[]}}},
    {set,0,16,16,8,80,48,
    {[],[],[],[],[],[],[],[],[],[],[],[],[],[],[],
    []},
    {{[],[],[],[],[],[],[],[],[],[],[],[],[],[],
    [],[]}}},
    <0.4154.2>,
    {state,fine,5000,#Ref<0.0.0.136584>},
    false,1,
    {{0,nil},{0,nil}},
    [],
    {{0,nil},{0,nil}},
    [{<<"publisher_confirms">>,bool,true},
    {<<"exchange_exchange_bindings">>,bool,true},
    {<<"basic.nack">>,bool,true},
    {<<"consumer_cancel_notify">>,bool,true},
    {<<"connection.blocked">>,bool,true},
    {<<"authentication_failure_close">>,bool,true}],
    none,0,none,flow,[]}
    ** Reason for termination ==
    ** {{{undef,
    [{erlang,system_time,[milli_seconds],[]},
    {rabbit_delayed_message,internal_delay_message,4,
    [{file,"src/rabbit_delayed_message.erl"},{line,179}]},
    {rabbit_delayed_message,handle_call,3,
    [{file,"src/rabbit_delayed_message.erl"},{line,122}]},
    {gen_server,handle_msg,5,[{file,"gen_server.erl"},{line,585}]},
    {proc_lib,init_p_do_apply,3,[{file,"proc_lib.erl"},{line,239}]}]},
    {gen_server,call,
    [rabbit_delayed_message,
    {delay_message,
    {exchange,
    {resource,<<"/">>,exchange,
    <<"papyrus.hopeline.staging.requeue">>},
    'x-delayed-message',true,false,false,
    [{<<"x-delayed-type">>,longstr,<<"direct">>}],
    undefined,undefined,
    {[],[]}},
    {delivery,false,false,<0.4340.2>,
    {basic_message,
    {resource,<<"/">>,exchange,
    <<"papyrus.hopeline.staging.requeue">>},
    [<<"papyrus.hopeline.staging.requeue">>],
    {content,60,
    {'P_basic',undefined,undefined,
    [{<<"x-delay">>,signedint,600000}],
    undefined,undefined,undefined,undefined,
    undefined,undefined,undefined,undefined,
    undefined,undefined,undefined},
    <<32,0,0,0,0,13,7,120,45,100,101,108,97,121,73,0,9,
    39,192>>,
    rabbit_framing_amqp_0_9_1,
    [<<"{\"_id\":\"579f380d9f3a78d60cb2063d\",\"__v\":2,\"created\":\"2016-08-01T11:52:45.346Z\",\"client\":{\"_id\":\"579f380d9f3a78d60cb2063b\"},\"assignedTo\":[{\"_id\":\"57ebd50f9e4a04b45444a639\",\"user\":{\"_id\":\"571e37f0cbd7a8ae2b73e925\",\"name\":\"Jason Royle\"},\"created\":\"2016-09-28T14:34:55.441Z\"},{\"_id\":\"57ebd52b9e4a04b45444a63b\",\"user\":{\"_id\":\"571e37f0cbd7a8ae2b73e925\",\"name\":\"Jason Royle\"},\"created\":\"2016-09-28T14:35:23.292Z\"}],\"assigned\":false}">>]},
    <<85,201,10,44,175,144,74,190,136,41,55,79,176,130,253,85>>,
    false},
    undefined,noflow},
    600000},
    infinity]}},
    [{gen_server,call,3,[{file,"gen_server.erl"},{line,188}]},
    {rabbit_exchange_type_delayed_message,route,2,
    [{file,"src/rabbit_exchange_type_delayed_message.erl"},{line,53}]},
    {rabbit_exchange,route1,3,[{file,"src/rabbit_exchange.erl"},{line,381}]},
    {rabbit_exchange,route,2,[{file,"src/rabbit_exchange.erl"},{line,371}]},
    {rabbit_channel,handle_method,3,
    [{file,"src/rabbit_channel.erl"},{line,943}]},
    {rabbit_channel,handle_cast,2,
    [{file,"src/rabbit_channel.erl"},{line,457}]},
    {gen_server2,handle_msg,2,[{file,"src/gen_server2.erl"},{line,1032}]},
    {proc_lib,init_p_do_apply,3,[{file,"proc_lib.erl"},{line,239}]}]}

    =ERROR REPORT==== 28-Sep-2016::15:51:59 ===
    Error on AMQP connection <0.4153.2> (172.30.0.13:41896 -> 172.30.0.11:5672, vhost: '/', user: 'developers', state: running), channel 2:
    {{{undef,
    [{erlang,system_time,[milli_seconds],[]},
    {rabbit_delayed_message,internal_delay_message,4,
    [{file,"src/rabbit_delayed_message.erl"},{line,179}]},
    {rabbit_delayed_message,handle_call,3,
    [{file,"src/rabbit_delayed_message.erl"},{line,122}]},
    {gen_server,handle_msg,5,[{file,"gen_server.erl"},{line,585}]},
    {proc_lib,init_p_do_apply,3,[{file,"proc_lib.erl"},{line,239}]}]},
    {gen_server,call,
    [rabbit_delayed_message,
    {delay_message,
    {exchange,
    {resource,<<"/">>,exchange,
    <<"papyrus.hopeline.staging.requeue">>},
    'x-delayed-message',true,false,false,
    [{<<"x-delayed-type">>,longstr,<<"direct">>}],
    undefined,undefined,
    {[],[]}},
    {delivery,false,false,<0.4340.2>,
    {basic_message,
    {resource,<<"/">>,exchange,
    <<"papyrus.hopeline.staging.requeue">>},
    [<<"papyrus.hopeline.staging.requeue">>],
    {content,60,
    {'P_basic',undefined,undefined,
    [{<<"x-delay">>,signedint,600000}],
    undefined,undefined,undefined,undefined,undefined,
    undefined,undefined,undefined,undefined,undefined,
    undefined},
    <<32,0,0,0,0,13,7,120,45,100,101,108,97,121,73,0,9,39,
    192>>,
    rabbit_framing_amqp_0_9_1,
    [<<"{\"_id\":\"579f380d9f3a78d60cb2063d\",\"__v\":2,\"created\":\"2016-08-01T11:52:45.346Z\",\"client\":{\"_id\":\"579f380d9f3a78d60cb2063b\"},\"assignedTo\":[{\"_id\":\"57ebd50f9e4a04b45444a639\",\"user\":{\"_id\":\"571e37f0cbd7a8ae2b73e925\",\"name\":\"Jason Royle\"},\"created\":\"2016-09-28T14:34:55.441Z\"},{\"_id\":\"57ebd52b9e4a04b45444a63b\",\"user\":{\"_id\":\"571e37f0cbd7a8ae2b73e925\",\"name\":\"Jason Royle\"},\"created\":\"2016-09-28T14:35:23.292Z\"}],\"assigned\":false}">>]},
    <<85,201,10,44,175,144,74,190,136,41,55,79,176,130,253,85>>,
    false},
    undefined,noflow},
    600000},
    infinity]}},
    [{gen_server,call,3,[{file,"gen_server.erl"},{line,188}]},
    {rabbit_exchange_type_delayed_message,route,2,
    [{file,"src/rabbit_exchange_type_delayed_message.erl"},{line,53}]},
    {rabbit_exchange,route1,3,[{file,"src/rabbit_exchange.erl"},{line,381}]},
    {rabbit_exchange,route,2,[{file,"src/rabbit_exchange.erl"},{line,371}]},
    {rabbit_channel,handle_method,3,
    [{file,"src/rabbit_channel.erl"},{line,943}]},
    {rabbit_channel,handle_cast,2,[{file,"src/rabbit_channel.erl"},{line,457}]},
    {gen_server2,handle_msg,2,[{file,"src/gen_server2.erl"},{line,1032}]},
    {proc_lib,init_p_do_apply,3,[{file,"proc_lib.erl"},{line,239}]}]}

    =WARNING REPORT==== 28-Sep-2016::15:51:59 ===
    Non-AMQP exit reason '{{{undef,
    [{erlang,system_time,[milli_seconds],[]},
    {rabbit_delayed_message,internal_delay_message,4,
    [{file,"src/rabbit_delayed_message.erl"},
    {line,179}]},
    {rabbit_delayed_message,handle_call,3,
    [{file,"src/rabbit_delayed_message.erl"},
    {line,122}]},
    {gen_server,handle_msg,5,
    [{file,"gen_server.erl"},{line,585}]},
    {proc_lib,init_p_do_apply,3,
    [{file,"proc_lib.erl"},{line,239}]}]},
    {gen_server,call,
    [rabbit_delayed_message,
    {delay_message,
    {exchange,
    {resource,<<"/">>,exchange,
    <<"papyrus.hopeline.staging.requeue">>},
    'x-delayed-message',true,false,false,
    [{<<"x-delayed-type">>,longstr,<<"direct">>}],
    undefined,undefined,
    {[],[]}},
    {delivery,false,false,<0.4340.2>,
    {basic_message,
    {resource,<<"/">>,exchange,
    <<"papyrus.hopeline.staging.requeue">>},
    [<<"papyrus.hopeline.staging.requeue">>],
    {content,60,
    {'P_basic',undefined,undefined,
    [{<<"x-delay">>,signedint,600000}],
    undefined,undefined,undefined,undefined,
    undefined,undefined,undefined,undefined,
    undefined,undefined,undefined},
    <<32,0,0,0,0,13,7,120,45,100,101,108,97,121,73,0,
    9,39,192>>,
    rabbit_framing_amqp_0_9_1,
    [<<"{\"_id\":\"579f380d9f3a78d60cb2063d\",\"__v\":2,\"created\":\"2016-08-01T11:52:45.346Z\",\"client\":{\"_id\":\"579f380d9f3a78d60cb2063b\"},\"assignedTo\":[{\"_id\":\"57ebd50f9e4a04b45444a639\",\"user\":{\"_id\":\"571e37f0cbd7a8ae2b73e925\",\"name\":\"Jason Royle\"},\"created\":\"2016-09-28T14:34:55.441Z\"},{\"_id\":\"57ebd52b9e4a04b45444a63b\",\"user\":{\"_id\":\"571e37f0cbd7a8ae2b73e925\",\"name\":\"Jason Royle\"},\"created\":\"2016-09-28T14:35:23.292Z\"}],\"assigned\":false}">>]},
    <<85,201,10,44,175,144,74,190,136,41,55,79,176,
    130,253,85>>,
    false},
    undefined,noflow},
    600000},
    infinity]}},
    [{gen_server,call,3,
    [{file,"gen_server.erl"},{line,188}]},
    {rabbit_exchange_type_delayed_message,route,2,
    [{file,
    "src/rabbit_exchange_type_delayed_message.erl"},
    {line,53}]},
    {rabbit_exchange,route1,3,
    [{file,"src/rabbit_exchange.erl"},{line,381}]},
    {rabbit_exchange,route,2,
    [{file,"src/rabbit_exchange.erl"},{line,371}]},
    {rabbit_channel,handle_method,3,
    [{file,"src/rabbit_channel.erl"},{line,943}]},
    {rabbit_channel,handle_cast,2,
    [{file,"src/rabbit_channel.erl"},{line,457}]},
    {gen_server2,handle_msg,2,
    [{file,"src/gen_server2.erl"},{line,1032}]},
    {proc_lib,init_p_do_apply,3,
    [{file,"proc_lib.erl"},{line,239}]}]}'

    最佳答案

    解决这个问题的方法是升级 erlang 的版本,因为 erlang 模块的 system_time 功能只存在于版本 18。为了在 centos 上安装最新版本,我使用了 this rpm package升级到 19.1 版。

    关于erlang - 使用 RabbitMQ 延迟消息交换插件时出现“函数未导出”错误,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/39753415/

    25 4 0
    Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
    广告合作:1813099741@qq.com 6ren.com