Golang Go - Exception (501) Reason: "EOF"

2,674 views
Skip to first unread message

cl...@catchandrelease.tv

unread,
Oct 12, 2018, 3:44:04 PM10/12/18
to rabbitmq-users
I get this exception when I make this call:

conn, err := amqp.Dial(amqpUrl)

RabbitMQ 3.7.8, on the latest AMQP library commit 70e15.

Two weird things:

1. It connects fine to the Heroku hosted CloudAMQP service on RabbitMQ 3.7.7

2. I can connect via the Ruby client just fine.

Thanks for any advice.

cl...@catchandrelease.tv

unread,
Oct 12, 2018, 3:49:12 PM10/12/18
to rabbitmq-users
Regarding the URL's, I've tried both:

conn, err := amqp.Dial("amqp://guest:guest@localhost:15672/")

I also made a second user, with no password, and gave access to a new virtual host, like

conn, err := amqp.Dial("amqp://dev@localhost:15672/flycaster")

Luke Bakken

unread,
Oct 12, 2018, 4:42:10 PM10/12/18
to rabbitmq-users
Hello,

What is logged by RabbitMQ?

Thanks,
Luke

cl...@catchandrelease.tv

unread,
Oct 12, 2018, 5:04:27 PM10/12/18
to rabbitmq-users
On Friday, October 12, 2018 at 1:42:10 PM UTC-7, Luke Bakken wrote:
Hello,

What is logged by RabbitMQ?

Thanks,
Luke

If I connect via Ruby, I get this:

==> /usr/local/var/log/rabbitmq/rab...@localhost.log <==
2018-10-12 13:55:51.072 [info] <0.15548.0> accepting AMQP connection <0.15548.0> (127.0.0.1:59413 -> 127.0.0.1:5672)
2018-10-12 13:55:51.115 [info] <0.15548.0> connection <0.15548.0> (127.0.0.1:59413 -> 127.0.0.1:5672): user 'guest' authenticated and granted access to vhost '/'
2018-10-12 13:55:51.283 [info] <0.15561.0> accepting AMQP connection <0.15561.0> (127.0.0.1:59414 -> 127.0.0.1:5672)
2018-10-12 13:55:51.283 [info] <0.15564.0> accepting AMQP connection <0.15564.0> (127.0.0.1:59415 -> 127.0.0.1:5672)
2018-10-12 13:55:51.288 [info] <0.15564.0> connection <0.15564.0> (127.0.0.1:59415 -> 127.0.0.1:5672): user 'guest' authenticated and granted access to vhost '/'
2018-10-12 13:55:51.288 [info] <0.15561.0> connection <0.15561.0> (127.0.0.1:59414 -> 127.0.0.1:5672): user 'guest' authenticated and granted access to vhost '/'
2018-10-12 13:55:51.486 [info] <0.15587.0> accepting AMQP connection <0.15587.0> (127.0.0.1:59416 -> 127.0.0.1:5672)
2018-10-12 13:55:51.491 [info] <0.15587.0> connection <0.15587.0> (127.0.0.1:59416 -> 127.0.0.1:5672): user 'guest' authenticated and granted access to vhost '/'

However if I try via Go, I get zilch. It's like RabbitMQ never sees any request. Again, it works totally fine if I fill in the CloudAMQP address.

cl...@catchandrelease.tv

unread,
Oct 12, 2018, 5:09:03 PM10/12/18
to rabbitmq-users
Well, hot damn, it works if I take out the port!

amqpUrl            = "amqp://guest:guest@localhost/

Results in:

2018-10-12 14:07:49.874 [info] <0.15612.0> accepting AMQP connection <0.15612.0> (127.0.0.1:59545 -> 127.0.0.1:5672)
2018-10-12 14:07:49.876 [info] <0.15612.0> connection <0.15612.0> (127.0.0.1:59545 -> 127.0.0.1:5672): user 'guest' authenticated and granted access to vhost '/'

Alright then... thanks!

cl...@catchandrelease.tv

unread,
Oct 12, 2018, 5:09:43 PM10/12/18
to rabbitmq-users
Oh, I was giving it the WEB port! I guess the Ruby client worked because it just disregarded the port I specified.

Michael Klishin

unread,
Oct 15, 2018, 4:58:28 AM10/15/18
to rabbitm...@googlegroups.com
15672 in amqp.Dial("amqp://guest:guest@localhost:15672/")

is the HTTP API port [1]. Server logs will contain protocol parser exceptions that will incude "GET /".


On Sat, Oct 13, 2018 at 12:09 AM <cl...@catchandrelease.tv> wrote:
Oh, I was giving it the WEB port! I guess the Ruby client worked because it just disregarded the port I specified.

--
You received this message because you are subscribed to the Google Groups "rabbitmq-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to rabbitmq-user...@googlegroups.com.
To post to this group, send email to rabbitm...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


--
MK

Staff Software Engineer, Pivotal/RabbitMQ
Reply all
Reply to author
Forward
0 new messages