[rabbitmq-discuss] JRUBY java.nio.channels.UnresolvedAddressException:

Jerry Kuch jerryk at vmware.com
Mon Oct 31 18:38:41 GMT 2011


Hi, Paul...

Perhaps I misunderstand the snippet you've attached, but are you 
really trying to connect to "dev.rabbitmq.com?"  You might
want to try using your actual Rabbit broker, either by IP or 
by a name that actually resolves for you, in AMQP.start(...)...

Best regards,
Jerry


----- Original Message -----
From: "Paul Cowan" <dagda1 at scotalt.net>
To: rabbitmq-discuss at lists.rabbitmq.com
Sent: Friday, October 28, 2011 12:00:03 AM
Subject: [rabbitmq-discuss] JRUBY	java.nio.channels.UnresolvedAddressException:


Hi, 


I am trying to start a queue consumer from JRuby 1.6.5, I have the following thor task that I want to use to start the queue: 



desc "start_consumer", "start the test consumer" 
def start_consumer 
puts "Running #{AMQP::VERSION} version of the gem" 

AMQP.start(:host => " dev.rabbitmq.com ") do |connection| 

ch = AMQP::Channel.new(connection) 

ch.queue("one", :auto_delete => true).subscribe(&method(:handle_message)) 
end 
end 


I start the rabbitmq-server with the rabbitmq-server --detachced command. 


When I run the task, it cannot connect to the host and I get the following error: 



NativeException: java.nio.channels.UnresolvedAddressException: null 
bind_connect_server at /Users/paulcowan/.rvm/gems/jruby-1.6.5/gems/eventmachine-1.0.0.beta.4-java/lib/jeventmachine.rb:136 


I can't find anything on this in google. 


Can anyone see anything obvious that I am missing? 

Cheers 

Paul Cowan 

Cutting-Edge Solutions (Scotland) 

http://thesoftwaresimpleton.com/ 


_______________________________________________
rabbitmq-discuss mailing list
rabbitmq-discuss at lists.rabbitmq.com
https://lists.rabbitmq.com/cgi-bin/mailman/listinfo/rabbitmq-discuss


More information about the rabbitmq-discuss mailing list