Sha256: 861f941ecbff03fee9cd853a95bcb65e53caef5ac81db3f6f91b5398b9e698c4
Contents?: true
Size: 469 Bytes
Versions: 95
Compression:
Stored size: 469 Bytes
Contents
require "statsd" require "forwardable" module GovukStatsd extend SingleForwardable def_delegators :client, :increment, :decrement, :count, :time, :timing, :gauge, :set, :batch def self.client @client ||= begin statsd_client = ::Statsd.new(ENV["GOVUK_STATSD_HOST"] || "localhost", 8125, ENV["GOVUK_STATSD_PROTOCOL"]&.to_sym || :udp) statsd_client.namespace = ENV["GOVUK_STATSD_PREFIX"].to_s statsd_client end end end
Version data entries
95 entries across 95 versions & 1 rubygems