prometheus-client 0.4.0 → 0.4.1

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,15 +1,15 @@
1
1
  ---
2
2
  !binary "U0hBMQ==":
3
3
  metadata.gz: !binary |-
4
- YWQ3NGY0YTg3OGJjMzdlNGQ2YjczNDcxNjdiZTQ1MDMxYzg2YzE5Yw==
4
+ NzhlZTZiM2NkOGU1ZDUzZWRlMDBkMmQyY2EwMDIxMTg5MjJkZDVhMQ==
5
5
  data.tar.gz: !binary |-
6
- NzNiODVjNWMwMzRhOTJhYzljNmFiMGI2YzQ5ZWZmODI0MWUxZWYyYw==
6
+ ZmZkZjY1YWM0YjM1MThiOTlhODZiZDAyNDE2MjRjZDQ5YmQ1YzAxNQ==
7
7
  SHA512:
8
8
  metadata.gz: !binary |-
9
- NWE1YTIxZjliZTZmZTI5ZmJmM2QyNDQyYmE0OWIyNzg3MTZhNGE3YzI4ZTA4
10
- M2IyOTAxNDUwZDU5NWI0MjczYzUyNTI2YjQzZWExNThjNTU5MzM4ZDQ2MjBj
11
- NWM2OGY5YjNhZDZhMjgzYTZlYzVmYTAyNWU5ODdmZmRiZTQwZjM=
9
+ Yjk5ODdiMjg2N2JjYWY0YmI0OTYwODg2M2I5ZDRjMWFjOGZmYmMxY2MyM2Q4
10
+ YjZkODNmNzI3NzUzNWUxOTRkZGNkYWFkM2VmNzdmMjlmMjFlNjNhODMwNjky
11
+ MjNhNmYzNzMwMDZjMWJkMTFlMTQzNzg0NDZmZGQ0ZTQ4ZmE1YWM=
12
12
  data.tar.gz: !binary |-
13
- MTYxMGE5ZGNkYWNlYWNhNDU4YmY4ODIxYzVjZGM1NmVkMTUxZDBjZGYzOTA1
14
- YzNmMzkxMTM2Zjc1ZTgzYTIzNjY1N2NkZDgxNzhjZjljMzQwZWJmZTM4ODAw
15
- Njc1M2M0NWZiMGMwYTkyZmYzOGNmZjY0YWYyMGMwOGZmNGY1Yzk=
13
+ NWVhZDQ0ZDdjMTZiNzc4MDAyNWUzMTU5MzJmYzUyMjBlZDBhMzVlODZhMmY4
14
+ OTE4ZDc2YTliNjU2YzVkZmI1NzA5YmZjNjA3OTZiMGEwMzBjNTVjNmU2YTJi
15
+ YmZiMTFjNmYyNGEwNDhlOTljMDZiZTU4ZmFjMzUzMjY2YjMzNjI=
@@ -28,15 +28,11 @@ module Prometheus
28
28
  end
29
29
 
30
30
  def add(registry)
31
- data = Formats::Text.marshal(registry)
32
-
33
- @http.send_request('PUT', path, data, HEADER)
31
+ request('POST', registry)
34
32
  end
35
33
 
36
34
  def replace(registry)
37
- @http.send_request('DELETE', path)
38
-
39
- add(registry)
35
+ request('PUT', registry)
40
36
  end
41
37
 
42
38
  private
@@ -60,6 +56,12 @@ module Prometheus
60
56
  format(PATH, URI.escape(job))
61
57
  end
62
58
  end
59
+
60
+ def request(method, registry)
61
+ data = Formats::Text.marshal(registry)
62
+
63
+ @http.send_request(method, path, data, HEADER)
64
+ end
63
65
  end
64
66
  end
65
67
  end
@@ -2,6 +2,6 @@
2
2
 
3
3
  module Prometheus
4
4
  module Client
5
- VERSION = '0.4.0'
5
+ VERSION = '0.4.1'
6
6
  end
7
7
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: prometheus-client
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.4.0
4
+ version: 0.4.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Tobias Schmidt
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2014-06-19 00:00:00.000000000 Z
11
+ date: 2014-06-23 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: quantile