[rabbitmq-discuss] JSON-RPC API

Michael Bridgen mikeb at rabbitmq.com
Mon Apr 18 14:58:09 BST 2011


Marcus,

> When the server is runs it gives me the following warnings:
>
> - undefined function fdsrv: bind_socket/2
> - undefined function fdsrv: start/0
> - undefined functions fdsrv: stop/0
> - undefined functions webmachine_resource: start_link/2
>
> Then the server tells that the nine plugins were activated

That is all OK so far.

> Besides that the samples of json-rpc are not running correctly (I am
> running the samples in a IE8) . For instance when the Simple Test calls:
>
> var channelFactory = new JsonRpc.Service("/rpc/rabbitmq",
> handle_service_ready,
>
> {debug: true,
>
> debugLogger: log,
>
> timeout: 30000});
>
> The handle_service_ready is never called. I receive the following error:
>
> Webpage error details
>
> User Agent: Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 5.1;
> Trident/4.0; GTB6; .NET CLR 1.1.4322; .NET CLR 3.0.04506.648; .NET CLR
> 3.5.21022; .NET CLR 3.0.4506.2152; .NET CLR 3.5.30729; .NET CLR 2.0.50727)
>
> Timestamp: Fri, 15 Apr 2011 17:14:41 UTC
>
> Message: Exception thrown and not caught
>
> Line: 156
>
> Char: 13
>
> Code: 0
>
> URI:
> file:///C:/Download/Microsoft/RabbitMQ/JSON-RPC/rabbitmq-jsonrpc-channel/priv/www-examples/rabbitmq_lib/json.js
>
> What is wrong ???

It looks like you are looking at the examples via the file system. You 
need to run them as a plugin -- download the 
rabbit-jsonrpc-channel-examples ".ez" file from from 
http://www.rabbitmq.com/plugins.html#rabbitmq-jsonrpc-channel (it's 
mentioned in the paragraph following the list of files) and drop it into 
plugins/, then look at http://localhost:55672/.

> Where can I find the JSON-RPC API documentation ???

I don't think there is any, aside from the (quite instructive, to be 
fair) examples -- it's always been an experimental plugin.


Michael


More information about the rabbitmq-discuss mailing list