This is about NATS messaging
- /
- /
One NATS instance was deployed on our docker server. For testing purposes I try to connect to it via terminal/bash.
- The server is reachable:
ping hostname
NATS-tools is installed locally on my machine.
- Choosing the wrong port to connect to:
nats --server hostname:5333 rtt
nats: error: nats: no servers available for connection
Thats fine & just as expected
- Choosing assumed (default) port to connect to:
nats --server hostname:4222 rtt
nats: error: nats: protocol exception, INFO not received
This leaves me questinong what went wrong. It feels like NATS was reached and thereafter something went wrong, which ends in an 'unfinished' state for the local NATS tools.
The / search help tries to "AI-hallucinate" its way out of the situation.
The error message nats: error: nats: protocol exception, INFO not received indicates that the NATS client expected to receive an INFO message from the server upon connection, but did not. In the NATS cluster protocol, when a server accepts a connection from another server, it sends an INFO message containing its configuration and security details. Not receiving this message can signal a protocol exception, causing the error - This error might occur if there is a misconfiguration, network issue, or the server is not sending the expected INFO message immediately as per the protocol requirements.
We haven't had time to dig deeper into the topic. Still, if there is any explanation beyond the AI-generated network explanation, please feel free to answer.
You may wonder: Why do I write this before checking the network?
- We already had a NATS instance at the same spot up and running - connection was established seamlessly. Although not assuming to have changed the network configuration, the upper error (now) exists.
Best wishes and keep coding :)