SocketError when using http_response_code

36 views
Skip to first unread message

Bryan Ricker

unread,
Oct 5, 2012, 2:26:31 AM10/5/12
to god...@googlegroups.com
I'm trying to monitor nginx, partly by checking for 502, 503, and 504 errors, with this bit of code:

    on.condition(:http_response_code) do |c|
      c.host     = "website.org"
      c.path     = "/"
      c.code_is  = [502, 503, 504]
      c.times    = [2, 5]
    end

However, I'm getting this in the output every time it checks:

http response nominal [SocketError, SocketError, SocketError, SocketError, SocketError] (HttpResponseCode)

I understand that this probably means that the server can't make outgoing requests. Is there a way to fix or get around this?

-Bryan

Reply all
Reply to author
Forward
0 new messages