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

Connecting to RabbitMQ via Java #161

Closed
Ramani21 opened this issue Aug 1, 2016 · 2 comments
Closed

Connecting to RabbitMQ via Java #161

Ramani21 opened this issue Aug 1, 2016 · 2 comments

Comments

@Ramani21
Copy link

Ramani21 commented Aug 1, 2016

Trying to connect to Rabbit MQ to fetch some queue properties but unable to get the connection established (RabbitMQ 3.3.5, Erlang R16B03-1).
String uri = "amqp://USER_ID:PWD@HOST:PORTNO/";
factory.setUri(uri);
Connection conn = factory.newConnection();
Channel channel = conn.createChannel();
channel.close();
conn.close();

Error:

java.net.UnknownHostException: monitor
at java.net.AbstractPlainSocketImpl.connect(Unknown Source)
at java.net.PlainSocketImpl.connect(Unknown Source)
at java.net.SocksSocketImpl.connect(Unknown Source)
at java.net.Socket.connect(Unknown Source)
at com.rabbitmq.client.impl.FrameHandlerFactory.create(FrameHandlerFactory.java:32)
at com.rabbitmq.client.ConnectionFactory.newConnection(ConnectionFactory.java:811)
at com.rabbitmq.client.ConnectionFactory.newConnection(ConnectionFactory.java:767)
at com.rabbitmq.client.ConnectionFactory.newConnection(ConnectionFactory.java:857)
at com.ConnectrabbitMQ.main(ConnectrabbitMQ.java:29)

@michaelklishin
Copy link
Member

Please post questions to rabbitmq-users or Stack Overflow. RabbitMQ uses GitHub issues for specific actionable items engineers can work on, not questions. Thank you.

@michaelklishin
Copy link
Member

Client's TCP connection fails with java.net.UnknownHostException, which is fairly self-explanatory.

stream-iori pushed a commit to stream-iori/rabbitmq-java-client that referenced this issue Mar 20, 2022
Bumps log4j-core from 2.17.0 to 2.17.1.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants