Closed rajkumarkandasami closed 4 years ago
I am not sure about this, the buffer will just keep on growing and growing and nobody will know a problem is going on.
Hi Sam, I will explain the PR, My setup has two containers
both containers sharing network namespace, so the app container can talk with collector process through 9394 port.
Case 1 :
Let's say the collector container not running, It tries to create a socket,
@socket = TCPSocket.new @host, @port
Which It cannot.
irb(main):001:0> Prometheus Exporter, failed to send message Connection timed out - connect(2) for "localhost" port 9394
Case 2:
If 9394 port is not exposed in collector host/container,
irb(main):001:0> Prometheus Exporter, failed to send message Cannot assign requested address - connect(2) for "localhost" port 9394
In both the cases client sends error message in rails console.
which should be rescued.
when no prometheus exporter collector running (in rails environment), exception got thrown in rails console. Which is caught and handled.