[rabbitmq-discuss] Fwd: Problem with plugin development guide example

Jim Irrer irrer at umich.edu
Fri Mar 18 19:13:05 GMT 2011


With known problems in metronome this is probably obsolete, but
here goes anyway:

'make run' creates the following files in /tmp:

bunny-sasl.log shows:

=CRASH REPORT==== 18-Mar-2011::14:52:03 ===
  crasher:
    pid: <0.247.0>
    registered_name: []
    exception exit: {undef,[{amqp_connection,start_direct,[]},
                            {rabbit_metronome_worker,init,1},
                            {gen_server,init_it,6},
                            {proc_lib,init_p_do_apply,3}]}
      in function  gen_server:init_it/6
    initial call: rabbit_metronome_worker:init/1
    ancestors: [rabbit_metronome_sup,<0.245.0>]
    messages: []
    links: [<0.246.0>]
    dictionary: []
    trap_exit: false
    status: running
    heap_size: 233
    stack_size: 23
    reductions: 139
  neighbours:

=SUPERVISOR REPORT==== 18-Mar-2011::14:52:03 ===
     Supervisor: {local,rabbit_metronome_sup}
     Context:    start_error
     Reason:     {undef,[{amqp_connection,start_direct,[]},
                         {rabbit_metronome_worker,init,1},
                         {gen_server,init_it,6},
                         {proc_lib,init_p_do_apply,3}]}
     Offender:   [{pid,undefined},
                  {name,rabbit_metronome_worker},
                  {mfa,{rabbit_metronome_worker,start_link,[]}},
                  {restart_type,permanent},
                  {shutdown,10000},
                  {child_type,worker}]


=CRASH REPORT==== 18-Mar-2011::14:52:03 ===
  crasher:
    pid: <0.244.0>
    registered_name: []
    exception exit: {shutdown,{rabbit_metronome,start,[normal,[]]}}
      in function  application_master:init/4
    initial call: application_master:init/4
    ancestors: [<0.243.0>]
    messages: [{'EXIT',<0.245.0>,normal}]
    links: [<0.243.0>,<0.6.0>]
    dictionary: []
    trap_exit: true
    status: running
    heap_size: 233
    stack_size: 23
    reductions: 100
  neighbours:




bunny.log shows:

=INFO REPORT==== 18-Mar-2011::14:52:03 ===
Limiting to approx 924 file handles (829 sockets)

=INFO REPORT==== 18-Mar-2011::14:52:03 ===
    application: mnesia
    exited: stopped
    type: permanent

=INFO REPORT==== 18-Mar-2011::14:52:03 ===
Memory limit set to 1416MB.

=INFO REPORT==== 18-Mar-2011::14:52:03 ===
Added vhost <<"/">>

=INFO REPORT==== 18-Mar-2011::14:52:03 ===
Created user <<"guest">>

=INFO REPORT==== 18-Mar-2011::14:52:03 ===
Set user admin flag for user <<"guest">> to true

=INFO REPORT==== 18-Mar-2011::14:52:03 ===
msg_store_transient: using rabbit_msg_store_ets_index to provide index

=INFO REPORT==== 18-Mar-2011::14:52:03 ===
msg_store_persistent: using rabbit_msg_store_ets_index to provide index

=WARNING REPORT==== 18-Mar-2011::14:52:03 ===
msg_store_persistent: rebuilding indices from scratch

=INFO REPORT==== 18-Mar-2011::14:52:03 ===
started TCP Listener on [::]:5679

=INFO REPORT==== 18-Mar-2011::14:52:03 ===
    application: rabbit_metronome
    exited: {shutdown,{rabbit_metronome,start,[normal,[]]}}
    type: permanent

=INFO REPORT==== 18-Mar-2011::14:52:03 ===
stopped TCP Listener on [::]:5679

Thanks,

- Jim

Jim Irrer     irrer at umich.edu       (734) 647-4409
University of Michigan Hospital Radiation Oncology
519 W. William St.             Ann Arbor, MI 48103


On Fri, Mar 18, 2011 at 12:56 PM, Jerry Kuch <jerryk at vmware.com> wrote:

> Hi, Jim...
>
> Can you look in the directory Rabbit's dropping logs into (see
> RABBIT_LOG_BASE in the broker's startup preamble) and take a peek at the
> rabbit and SASL logs?  There may be a bit more information in there on what
> made the metronome application unhappy when it tried to start up...
>
> Best regards,
> Jerry
>
> ________________________________________
> From: rabbitmq-discuss-bounces at lists.rabbitmq.com [
> rabbitmq-discuss-bounces at lists.rabbitmq.com] On Behalf Of Jim Irrer [
> irrer at umich.edu]
> Sent: Friday, March 18, 2011 9:22 AM
> To: rabbitmq-discuss at lists.rabbitmq.com
> Cc: Jim Irrer
> Subject: Re: [rabbitmq-discuss] Fwd: Problem with plugin development guide
>      example
>
> That was helpful - I got farther - but not there yet.
>
> I did the checkout of the umbrella with the command above:
>
> hg clone http://hg.rabbitmq.com/rabbitmq-public-umbrella -r bug23568
>
> but I did the 'make co' without any special parameters, so I assumed
> that it did hg commands with respect to the bug23568 branch.
>
> I built the metronome project as outlined on the Rabbit site and added
> the rabbit_metronome-0.0.0.ez and amqp_client.ez files to the
> rabbitmq-public-umbrella/rabbitmq-server/plugins directory, but when I
> start it up I get:
>
> linus:make run
> RABBITMQ_NODE_IP_ADDRESS="" RABBITMQ_NODE_PORT="5679"
> RABBITMQ_LOG_BASE="/tmp" RABBITMQ_MNESIA_DIR="/tmp/rabbitmq-bunny-mnesia"
> RABBITMQ_PLUGINS_EXPAND_DIR="/tmp/rabbitmq-bunny-plugins-scratch" \
>                RABBITMQ_ALLOW_INPUT=true \
>                RABBITMQ_SERVER_START_ARGS="" \
>                ./scripts/rabbitmq-server
> Activating RabbitMQ plugins ...
> *WARNING* Undefined function amqp_connection:start_direct/0
> *WARNING* Undefined function gb_trees:map/2
> *WARNING* Undefined function os:timestamp/0
> *WARNING* Undefined function random:seed/1
> *WARNING* Undefined function ssl:ssl_accept/3
> 2 plugins activated:
> * amqp_client-0.0.0
> * rabbit_metronome-0.0.0
>
> Erlang (BEAM) emulator version 5.6.5 [source] [64-bit] [smp:2]
> [async-threads:30] [hipe] [kernel-poll:true]
>
>
> +---+   +---+
> |   |   |   |
> |   |   |   |
> |   |   |   |
> |   +---+   +-------+
> |                   |
> | RabbitMQ  +---+   |
> |           |   |   |
> | v%%VSN%%  +---+   |
> |                   |
> +-------------------+
> AMQP 0-9-1 / 0-9 / 0-8
> Copyright (C) 2007-2011 VMware, Inc.
> Licensed under the MPL.  See http://www.rabbitmq.com/
>
> node           : bunny at linus
> app descriptor :
> /devel/home/irrer/tmp/erl/r2/rabbitmq-public-umbrella/rabbitmq-server/scripts/../ebin/rabbit.app
> home dir       : /home/irrer
> config file(s) : (none)
> cookie hash    : JG6HnrDO2nMIVTU2s7iwoA==
> log            : /tmp/bunny.log
> sasl log       : /tmp/bunny-sasl.log
> database dir   : /tmp/rabbitmq-bunny-mnesia
> erlang version : 5.6.5
>
> starting file handle cache server
> ...done
> starting worker pool
>  ...done
> starting database
> ...done
> starting codec correctness check
>  ...done
> -- external infrastructure ready
> starting statistics event manager
> ...done
> starting logging server
> ...done
> starting plugin registry
>  ...done
> starting auth mechanism amqplain
>  ...done
> starting auth mechanism cr-demo
> ...done
> starting auth mechanism plain
> ...done
> starting exchange type direct
> ...done
> starting exchange type fanout
> ...done
> starting exchange type headers
>  ...done
> starting exchange type topic
>  ...done
> -- kernel ready
> starting node monitor
> ...done
> starting cluster delegate
> ...done
> starting guid generator
> ...done
> starting alarm handler
>  ...done
> starting memory monitor
> ...done
> -- core initialized
> starting empty DB check
> ...done
> starting exchange recovery
>  ...done
> starting queue supervisor and queue recovery
>  ...done
> -- message delivery logic ready
> starting error log relay
>  ...done
> starting networking
> ...done
> starting notify cluster nodes
> ...done
> starting direct_client
>  ...done
>
> broker running
> Eshell V5.6.5  (abort with ^G)
> (bunny at linus)1> Erlang has closed
>                                 {"Kernel pid
> terminated",application_controller,"{application_start_failure,rabbit_metronome,{shutdown,{rabbit_metronome,start,[normal,[]]}}}"}
>
> Crash dump was written to: erl_crash.dump
> Kernel pid terminated (application_controller)
> ({application_start_failure,rabbit_metronome,{shutdown,{rabbit_metronome,start,[normal,[]]}}})
>
> And as advertised it creates a big honkin' dump file.
>
> I also had to create symbolic links so that the code would build.  In my
> rabbitmq-public-umbrella/rabbit_metronome directory I created:
>
> amqp_client -> ../rabbitmq-erlang-client/dist/amqp_client
> rabbit_common -> ../rabbitmq-erlang-client/dist/rabbit_common
>
> The server works fine if run without adding plugins, but when I add them
> it bombs, so I know the plugins are the problem (Right?).
>
> I'm new to Erlang (interesting language), so all I did was cut and paste
> the example Erlang code, so if that code is out of date then it would be a
> problem.
>
> Also: I changed the port to 5679 so it would not interfere with the
> official
> installed RabbitMQ server on the same machine, and I set RABBITMQ_NODENAME
> to 'bunny'.
>
> Thanks,
>
> - Jim
>
> Jim Irrer     irrer at umich.edu<mailto:irrer at umich.edu>       (734) 647-4409
> <tel:%28734%29%20647-4409>
> University of Michigan Hospital Radiation Oncology
> 519 W. William St.             Ann Arbor, MI 48103
>
>
> On Thu, Mar 17, 2011 at 8:27 AM, Matthew Sackman <matthew at rabbitmq.com
> <mailto:matthew at rabbitmq.com>> wrote:
> On Tue, Mar 15, 2011 at 07:00:28PM -0400, Jim Irrer wrote:
> > If I checkout the latest server code, will I get the bug23274 fix?
>
> Nope. bug23274 has been abandoned. bug23568 replaces it, but is yet to
> go through QA. None of the documentation regarding writing plugins has
> been updated.
>
> > If not, what is the Mercurial command to get it?
>
> hg clone http://hg.rabbitmq.com/rabbitmq-public-umbrella -r bug23568
>
> But you'll need to make sure all the plugins are also on branch bug23568
> for them to work with the new build system.
>
> If you're writing plugins from scratch, be sure to read the
> rabbitmq-public-umbrella/README.makefiles file, which has a helpful
> section on "Creating a new package".
>
> Matthew
> _______________________________________________
> rabbitmq-discuss mailing list
> rabbitmq-discuss at lists.rabbitmq.com<mailto:
> rabbitmq-discuss at lists.rabbitmq.com>
> https://lists.rabbitmq.com/cgi-bin/mailman/listinfo/rabbitmq-discuss
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.rabbitmq.com/pipermail/rabbitmq-discuss/attachments/20110318/116870ca/attachment-0001.htm>


More information about the rabbitmq-discuss mailing list