New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix issues with using the RABBITMQ_URL environment variable #403

merged 1 commit into from May 13, 2016


None yet
2 participants

jipe commented May 13, 2016

I experienced some issues when trying to have two Bunny instances at the same time, where one would be instantiated using (with a connection string set in the RABBITMQ_URL environment variable) and the other would be instantiated using Apparently both instances would then use the connection string from the RABBITMQ_URL environment variable.

This PR is a fix to that issue, so when a Bunny is instantiated given a specific connection string (or hash), it will disregard the RABBITMQ_URL environment variable and when Bunny is instantiated without a connection argument, it will default to use value of a look-up of the RABBITMQ_URL environment variable.

Default to ENV['RABBITMQ_URL'] when no connection argument is given
- and now defaults to ENV['RABBITMQ_URL'] for connection
- now only uses ENV['RABBITMQ_URL'] for connection argument
  when no other argument is given.

@michaelklishin michaelklishin self-assigned this May 13, 2016

@michaelklishin michaelklishin merged commit a41ef1b into ruby-amqp:master May 13, 2016

1 check passed

continuous-integration/travis-ci/pr The Travis CI build passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment