Skip to content

Commit

Permalink
Update gem dependencies
Browse files Browse the repository at this point in the history
  • Loading branch information
grobie committed May 20, 2014
1 parent 5b429a7 commit a99a412
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 9 deletions.
3 changes: 1 addition & 2 deletions lib/prometheus/client/metric.rb
Original file line number Diff line number Diff line change
Expand Up @@ -36,9 +36,8 @@ def get(labels = {})

def values
synchronize do
@values.reduce({}) do |memo, (labels, value)|
@values.each_with_object({}) do |(labels, value), memo|
memo[labels] = value
memo
end
end
end
Expand Down
3 changes: 1 addition & 2 deletions lib/prometheus/client/rack/exporter.rb
Original file line number Diff line number Diff line change
Expand Up @@ -74,10 +74,9 @@ def not_acceptable(formats)
end

def build_dictionary(formats)
formats.reduce({}) do |memo, format|
formats.each_with_object({}) do |format, memo|
memo[format::CONTENT_TYPE] = format
memo[format::MEDIA_TYPE] = format
memo
end
end
end
Expand Down
6 changes: 2 additions & 4 deletions lib/prometheus/client/summary.rb
Original file line number Diff line number Diff line change
Expand Up @@ -28,9 +28,8 @@ def get(labels = {})
# Returns all label sets with their values
def values
synchronize do
@values.reduce({}) do |memo, (labels, value)|
@values.each_with_object({}) do |(labels, value), memo|
memo[labels] = transform(value)
memo
end
end
end
Expand All @@ -42,9 +41,8 @@ def default
end

def transform(estimator)
estimator.invariants.reduce({}) do |memo, invariant|
estimator.invariants.each_with_object({}) do |invariant, memo|
memo[invariant.quantile] = estimator.query(invariant.quantile)
memo
end
end
end
Expand Down
2 changes: 1 addition & 1 deletion prometheus-client.gemspec
Original file line number Diff line number Diff line change
Expand Up @@ -15,5 +15,5 @@ Gem::Specification.new do |s|
s.files = %w(README.md) + Dir.glob('{lib/**/*}')
s.require_paths = ['lib']

s.add_dependency 'quantile', '~> 0.1.0'
s.add_dependency 'quantile', '~> 0.2.0'
end

0 comments on commit a99a412

Please sign in to comment.