Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP

Loading…

Close the tcp socket on Errno::EPIPE #30

Merged
merged 1 commit into from

2 participants

@bernd

This helps the graphite reporter to recover from an unavailable graphite carbon daemon. Without this it keeps spitting out EPIPEs even if the carbon daemon got back online.

@bernd

Should I report this in the metriks-graphite gem?

@eric
Owner

Sorry about that, I'll merge this.

@eric eric merged commit b735c44 into eric:master
@bernd

Awesome, thank you!

@bernd bernd deleted the bernd:tcpsocket-epipe-fix branch
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Commits on Jan 22, 2013
  1. @bernd
This page is out of date. Refresh to see the latest.
Showing with 2 additions and 0 deletions.
  1. +2 −0  lib/metriks/reporter/graphite.rb
View
2  lib/metriks/reporter/graphite.rb
@@ -108,6 +108,8 @@ def write_metric(base_name, metric, keys, snapshot_keys = [])
socket.write("#{base_name}.#{name} #{value} #{time}\n")
end
end
+ rescue Errno::EPIPE
+ socket.close
end
end
end
Something went wrong with that request. Please try again.