[rabbitmq-discuss] Question about RabbitMQ "Presence Exchange" Plugin

Oldrich olda.esner at gmail.com
Wed Oct 31 22:37:36 GMT 2012


Creating ez plugin with 'make BRANCH=rabbitmq_v2_8_7 up_c'. And then 
'make'. works.

Some exceptions have disappered but this sentences of steps causes the 
following exception (on clean rabbitmq_2.8.7 installation with 
presence-exchange plugin):

- load rabbitmq management plugin (web based interface)
- create exchange "xpresence" with exchange type "x-presence" - OK
- create queue "qpresence" with binding to exchange "xpresence" and empty 
routing key - OK 
- create queue "client.test5" with binding to exchange "xpresence" and 
routing key "test5" - ERROR

{error,
    {exit,
        {{undef,
             [{rabbit_basic,delivery,
                  [false,
                   {basic_message,
                       {resource,<<"/">>,exchange,<<"xpresence">>},
                       [<<>>],
                       {content,60,
                           {'P_basic',undefined,undefined,
                               [{<<"action">>,longstr,"bind"},
                                {<<"exchange">>,longstr,<<"xpresence">>},
                                {<<"queue">>,longstr,<<"client.test5">>},
                                {<<"key">>,longstr,<<"test5">>}],
                               undefined,undefined,undefined,undefined,
                               undefined,undefined,undefined,undefined,
                               undefined,undefined,undefined},
                           none,none,
                           [<<>>]},
                       <<11,29,48,224,182,246,62,8,151,38,183,173,140,42,185,
                         231>>,
                       false},
                   undefined],
                  []},
              {presence_exchange,add_binding,3,[]},
              {rabbit_binding,'-add/3-fun-0-',3,[]},
              {rabbit_channel,binding_action,9,[]},
              {rabbit_channel,handle_cast,2,[]},
              {gen_server2,handle_msg,2,[]},
              {proc_lib,init_p_do_apply,3,
                  [{file,"proc_lib.erl"},{line,227}]}]},
         {gen_server,call,
             [<0.375.0>,
              {call,
                  {'queue.bind',0,<<"client.test5">>,<<"xpresence">>,
                      <<"test5">>,false,[]},
                  none,<0.243.0>},
              infinity]}},
        [{gen_server,call,3,[{file,"gen_server.erl"},{line,188}]},
         {rabbit_mgmt_util,'-amqp_request/5-fun-0-',4,[]},
         {rabbit_mgmt_util,with_channel,5,[]},
         {rabbit_mgmt_wm_bindings,accept_content,2,[]},
         {webmachine_resource,resource_call,3,[]},
         {webmachine_resource,do,3,[]},
         {webmachine_decision_core,resource_call,1,[]},
         {webmachine_decision_core,accept_helper,0,[]}]}}


Which type of error is it in this case?

Thank you,

Oldrich Esner.

Dne středa, 31. října 2012 14:25:01 UTC-7 Oldrich napsal(a):
>
> I tried following:
> - cloned rabbitmq-public-umbrella
> - inside rabbitmq-public-umbrella directory I created presence-exchange 
> folder with current GIT presence-exchange plugin
> - build "make VERSION=2.8.7" inside presence-exchange folder, everything 
> was successful
> - after copying rabbit-presence-exchange-0.0.0.ez into rabbitmq-2.8.7 
> plugin folder and restarting rabbit server still the same error appears
>
> Have any of you tried whether presence-exchange plugin is really 
> compatible with the latest rabbitmq stable version (2.8.7)?
>
> Thank you very much for any help.
>
> Oldrich
>
> Dne úterý, 30. října 2012 18:35:02 UTC-7 Olda Ešner napsal(a):
>>
>> Bad news, plugins seems to work in management console (x-presence 
>> exchange isn't in "red" state) but after binding x-presence exchange to 
>> queue, rabbit server log writes the following:
>>
>> =ERROR REPORT==== 31-Oct-2012::02:22:37 ===
>> ** Generic server <0.131.0> terminating
>> ** Last message in was {'$gen_cast',
>>                            {submit_async,#Fun<rabbit_binding.3.58413561>}}
>> ** When Server state == 2
>> ** Reason for termination == 
>> ** {function_clause,
>>        [{presence_exchange,add_binding,
>>             [none,
>>              {exchange,
>>                  {resource,<<"/">>,exchange,<<"xpresence">>},
>>                  'x-presence',true,false,false,[],undefined},
>>              {binding,
>>                  {resource,<<"/">>,exchange,<<"xpresence">>},
>>                  <<>>,
>>                  {resource,<<"/">>,queue,<<"qpresence">>},
>>                  []}],
>>             []},
>>         {rabbit_binding,x_callback,4,[]},
>>         {rabbit_binding,'-recover_semi_durable_route/3-fun-0-',3,[]},
>>         {worker_pool_worker,handle_cast,2,[]},
>>         {gen_server2,handle_msg,2,[]},
>>         {proc_lib,init_p_do_apply,3,[{file,"proc_lib.erl"},{line,227}]}]} 
>>
>> =ERROR REPORT==== 31-Oct-2012::02:19:08 ===
>> ** Generic server <0.1023.0> terminating
>> ** Last message in was {'$gen_cast',
>>                            {method,
>>                                {'queue.bind',0,
>>                                    
>> <<"1ae1453a-5218-467d-9f10-b4cd10014d2a">>,
>>                                    <<"xpresence">>,<<>>,false,[]},
>>                                none,noflow}}
>> ** When Server state == 
>> {ch,running,rabbit_framing_amqp_0_9_1,1,<0.1019.0>,
>>                             <0.1021.0>,<0.1019.0>,
>>                             "127.0.0.1:54877 -> 127.0.0.1:5672",
>>                             {token,<0.1022.0>,false},
>>                             none,1,
>>                             {[],[]},
>>                             {[],[]},
>>                             [],[],
>>                             {user,<<"guest">>,
>>                                 [administrator],
>>                                 rabbit_auth_backend_internal,
>>                                 {internal_user,<<"guest">>,
>>                                     
>> <<238,155,95,210,98,65,149,74,208,144,18,
>>                                       
>> 191,58,228,155,137,230,224,252,199>>,
>>                                     [administrator]}},
>>                             <<"/">>,
>>                             <<"1ae1453a-5218-467d-9f10-b4cd10014d2a">>,
>>                             {dict,0,16,16,8,80,48,
>>                                 
>> {[],[],[],[],[],[],[],[],[],[],[],[],[],[],[],
>>                                  []},
>>                                 
>> {{[],[],[],[],[],[],[],[],[],[],[],[],[],[],
>>                                   [],[]}}},
>>                             {dict,0,16,16,8,80,48,
>>                                 
>> {[],[],[],[],[],[],[],[],[],[],[],[],[],[],[],
>>                                  []},
>>                                 
>> {{[],[],[],[],[],[],[],[],[],[],[],[],[],[],
>>                                   [],[]}}},
>>                             {set,0,16,16,8,80,48,
>>                                 
>> {[],[],[],[],[],[],[],[],[],[],[],[],[],[],[],
>>                                  []},
>>                                 
>> {{[],[],[],[],[],[],[],[],[],[],[],[],[],[],
>>                                   [],[]}}},
>>                             {dict,0,16,16,8,80,48,
>>                                 
>> {[],[],[],[],[],[],[],[],[],[],[],[],[],[],[],
>>                                  []},
>>                                 
>> {{[],[],[],[],[],[],[],[],[],[],[],[],[],[],
>>                                   [],[]}}},
>>                             {set,0,16,16,8,80,48,
>>                                 
>> {[],[],[],[],[],[],[],[],[],[],[],[],[],[],[],
>>                                  []},
>>                                 
>> {{[],[],[],[],[],[],[],[],[],[],[],[],[],[],
>>                                   [],[]}}},
>>                             <0.1017.0>,
>>                             {state,fine,5000,#Ref<0.0.0.8440>},
>>                             false,1,
>>                             {{0,nil},{0,nil}},
>>                             [],
>>                             [{<<"exchange_exchange_bindings">>,bool,true},
>>                              {<<"consumer_cancel_notify">>,bool,true},
>>                              {<<"basic.nack">>,bool,true},
>>                              {<<"publisher_confirms">>,bool,true}],
>>                             none}
>> ** Reason for termination == 
>> ** {function_clause,
>>        [{presence_exchange,add_binding,
>>             [none,
>>              {exchange,
>>                  {resource,<<"/">>,exchange,<<"xpresence">>},
>>                  'x-presence',true,false,false,[],undefined},
>>              {binding,
>>                  {resource,<<"/">>,exchange,<<"xpresence">>},
>>                  <<>>,
>>                  {resource,<<"/">>,queue,
>>                      <<"1ae1453a-5218-467d-9f10-b4cd10014d2a">>},
>>                  []}],
>>             []},
>>         {rabbit_binding,'-add/3-fun-0-',3,[]},
>>         {rabbit_channel,binding_action,9,[]},
>>         {rabbit_channel,handle_cast,2,[]},
>>         {gen_server2,handle_msg,2,[]},
>>         {proc_lib,init_p_do_apply,3,[{file,"proc_lib.erl"},{line,227}]}]}
>>
>> =ERROR REPORT==== 31-Oct-2012::02:19:08 ===
>> AMQP connection <0.1019.0>, channel 1 - error:
>> {function_clause,
>>     [{presence_exchange,add_binding,
>>          [none,
>>           {exchange,
>>               {resource,<<"/">>,exchange,<<"xpresence">>},
>>               'x-presence',true,false,false,[],undefined},
>>           {binding,
>>               {resource,<<"/">>,exchange,<<"xpresence">>},
>>               <<>>,
>>               {resource,<<"/">>,queue,
>>                   <<"1ae1453a-5218-467d-9f10-b4cd10014d2a">>},
>>               []}],
>>          []},
>>      {rabbit_binding,'-add/3-fun-0-',3,[]},
>>      {rabbit_channel,binding_action,9,[]},
>>      {rabbit_channel,handle_cast,2,[]},
>>      {gen_server2,handle_msg,2,[]},
>>      {proc_lib,init_p_do_apply,3,[{file,"proc_lib.erl"},{line,227}]}]}
>>
>> =WARNING REPORT==== 31-Oct-2012::02:19:08 ===
>> Non-AMQP exit reason '{function_clause,
>>                        [{presence_exchange,add_binding,
>>                          [none,
>>                           {exchange,
>>                            {resource,<<"/">>,exchange,<<"xpresence">>},
>>                            'x-presence',true,false,false,[],undefined},
>>                           {binding,
>>                            {resource,<<"/">>,exchange,<<"xpresence">>},
>>                            <<>>,
>>                            {resource,<<"/">>,queue,
>>                             <<"1ae1453a-5218-467d-9f10-b4cd10014d2a">>},
>>                            []}],
>>                          []},
>>                         {rabbit_binding,'-add/3-fun-0-',3,[]},
>>                         {rabbit_channel,binding_action,9,[]},
>>                         {rabbit_channel,handle_cast,2,[]},
>>                         {gen_server2,handle_msg,2,[]},
>>                         {proc_lib,init_p_do_apply,3,
>>                          [{file,"proc_lib.erl"},{line,227}]}]}' 
>>
>> Is any of you able to find a source of problem? We are using Java EE 
>> application with spring-rabbit and spring-amqp libraries.
>>
>> Thank you.
>>
>> Oldrich
>>
>> 2012/10/30 Oldřich Ešner <olda.esner at gmail.com>
>>
>>> Thank you very much for the fastest fix I have ever seen :)
>>>
>>> If you want to update downloads section, I'm including current ez build 
>>> of presence plugin.
>>>
>>> Regards,
>>>
>>> Oldrich
>>>
>>>
>>> 2012/10/30 Simon MacMullen <simon at rabbitmq.com>
>>>
>>>> On 30/10/12 14:18, Tony Garnock-Jones wrote:
>>>>
>>>>> On 30 October 2012 00:27, Olda Ešner <olda.esner at gmail.com
>>>>> <mailto:olda.esner at gmail.com>> wrote:
>>>>>
>>>>>     after upgrading to RabbitMQ 2.8.6 from 2.8.5, presence-exchange
>>>>>     plugin doesn't work. Is there any chance to fix it?
>>>>>
>>>>>
>>>>> It's a consequence of the removal from the server's core of support for
>>>>> "immediate" publication. At least rabbithub and the udp-exchange will
>>>>> also have to be updated. The fix should be straightforward.
>>>>>
>>>>
>>>> ...although that's happened on default, not 2.8.6.
>>>>
>>>> To the OP: you might need to get the un-updated version of the plugin 
>>>> source, and then build that against the 2.8.6 source download.
>>>>
>>>> Alternatively, whatever plugin binary you created for 2.8.5 should 
>>>> still work, I don't think any APIs changed?
>>>>
>>>>
>>>>  I'll email again when I'm done. Shouldn't be long.
>>>>>
>>>>
>>>> *clicks stopwatch* Six minutes, not bad :-)
>>>>
>>>> Cheers, Simon
>>>>
>>>>
>>>> -- 
>>>> Simon MacMullen
>>>> RabbitMQ, VMware
>>>>
>>>
>>>
>>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.rabbitmq.com/pipermail/rabbitmq-discuss/attachments/20121031/759b447f/attachment-0001.htm>


More information about the rabbitmq-discuss mailing list