Skip to content
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

amqps in ConnectionHandler - createConnection() #33

Closed
ridnarong opened this issue Apr 10, 2014 · 1 comment
Closed

amqps in ConnectionHandler - createConnection() #33

ridnarong opened this issue Apr 10, 2014 · 1 comment

Comments

@ridnarong
Copy link

In line 235 of ConnectionHandler.java

          final String amqpAddress = String.format("amqp://%s:%s/%s", connection.getAddress()
              .getHostAddress(), connection.getPort(), "/".equals(cxnFactory.getVirtualHost()) ? ""
              : cxnFactory.getVirtualHost());

This will always make connection with amqp protocol. You may change to

          final String amqpAddress = String.format("%s://%s:%s/%s", cxnFactory.isSSL() ? "amqps" : "amqp", connection.getAddress()
              .getHostAddress(), connection.getPort(), "/".equals(cxnFactory.getVirtualHost()) ? ""
              : cxnFactory.getVirtualHost());

to check with cxnFactory.isSSL()

jhalterman added a commit that referenced this issue Apr 10, 2014
@jhalterman
Copy link
Owner

Thanks for this

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants