>PROBLEM
Attempt to connect to RabbitMQ returns the following:
java.io.IOException
at com.rabbitmq.client.impl.AMQChannel.wrap(AMQChannel.java:129)
at com.rabbitmq.client.impl.AMQChannel.wrap(AMQChannel.java:125)
at com.rabbitmq.client.impl.AMQConnection.start(AMQConnection.java:396)
...
Caused by: com.rabbitmq.client.ShutdownSignalException: connection error
...
Caused by: java.io.EOFException
at java.io.DataInputStream.readUnsignedByte(DataInputStream.java:290)
...
Caused by: com.rabbitmq.client.ShutdownSignalException: connection error
...
Caused by: java.io.EOFException
at java.io.DataInputStream.readUnsignedByte(DataInputStream.java:290)
...
java.io.IOException
at com.rabbitmq.client.impl.AMQChannel.wrap(AMQChannel.java:129)
at com.rabbitmq.client.impl.AMQChannel.wrap(AMQChannel.java:125)
at com.rabbitmq.client.impl.AMQConnection.start(AMQConnection.java:396)
...
Caused by: com.rabbitmq.client.ShutdownSignalException: connection error
Caused by: java.io.EOFException
at java.io.DataInputStream.readUnsignedByte(DataInputStream.java:290)
...
>SOLUTION
Check the following:
1.Usually, the console management uses 15672 port.
2. Usually, the HTTP request via app (web service/microserve) uses 5672
3. Make sure to enable these ports when working with container (docker).
4. Avoid using /api on a RESTful web service because "/api" is already used by the native rabbitmq's ws,
An example of the properties file (application.yml):
rabbit-host: mydomain.com
rabbit-port: 5672
rabbit-ssl: false
rabbit-user: john doe
rabbit-pass: secret
No comments:
Post a Comment