Created
December 8, 2012 17:12
-
-
Save celldee/4241063 to your computer and use it in GitHub Desktop.
Bunny - connect using SSL
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require 'bunny' | |
# Usual arguments | |
conn = Bunny.new(:host => 'myhost', :ssl => true) | |
conn.start | |
puts conn.status # :open | |
puts conn.ssl? # true | |
# URI | |
conn2 = Bunny.new("amqps://myhost/%2F") # %2F is '/' URL encoded | |
conn2.start | |
puts conn2.status # :open | |
puts conn.ssl? # true | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment