diplomatic_bag 2.3.2 → 2.4.3

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 2a39a50e5f6743dcc7661d45a0f498d29336b428e6218005827e98059470e6cc
4
- data.tar.gz: 04e19d8f11f08506f734f6007b4ba3b4d1f845a13e2824e89f8ad572e9071690
3
+ metadata.gz: 3315d6dfa1622862e69fbc688992bda70b550077f2eb34ffcd5e70c62d148bb1
4
+ data.tar.gz: e42f79f57acf1f60477a8fdd803686f6eba5d62131f7eaeb65cad123190e5450
5
5
  SHA512:
6
- metadata.gz: 5fd4d452536a7d30fc7a2a6feb400b31989413a8950b2088f85e38f9fdfa41cb62f0c0e66181430590ede6a7493259b26f91ec880901d3f8dd27fdb2c3a2b56b
7
- data.tar.gz: 0ef2d6482509aebea32163ccbe77c56d486947aa21062498c6fa8d89db5e524b1b92808f8ba6ac983b676fa12e571bf322d38a584e927fc38c277bf0b6cd2f48
6
+ metadata.gz: e6e036a0b094e4e11429b363ff881e75583a0e47a494bcf13b7d9764f96beac016f2247033cf7bbfbd783b4731be5b9545de69f430d29315a10395a02d11b2f4
7
+ data.tar.gz: b503c622494eaef17a8ab461b6e2fd2c13871ff22f3e569e52e75fe84bd8148da2f4be4b0b95c8eb1eb3c20145cc91584a2b8536b456b81fb8cd4833f9748495
@@ -2,6 +2,8 @@
2
2
 
3
3
  # Usefull usage of Diplomat lib: Datacenter functions
4
4
  module DiplomaticBag
5
+ # Return the list of datacenters matching given regexp
6
+ # @return [Array[string]] an array of DC matching given regexp
5
7
  def self.get_datacenters_list(dc, options = {})
6
8
  dcs = []
7
9
  datacenters = Diplomat::Datacenter.get(nil, options)
@@ -2,6 +2,9 @@
2
2
 
3
3
  # Usefull usage of Diplomat lib: Nodes functions
4
4
  module DiplomaticBag
5
+ # Get the list of nodes having duplicate node ids
6
+ # @param options options to query with
7
+ # @return [Array[Object]] an array of objects with {name: node_name, status: status}
5
8
  def self.get_duplicate_node_id(options = {})
6
9
  status = {
7
10
  1 => 'Alive',
@@ -2,12 +2,18 @@
2
2
 
3
3
  # Usefull usage of Diplomat lib: Services functions
4
4
  module DiplomaticBag
5
+ # Get sevice name or empty string
6
+ # @param s service information
7
+ # @return [string] the name of service
5
8
  def self.compute_service_name(s)
6
9
  return '/node::health/' if s.nil? || s == ''
7
10
 
8
11
  s
9
12
  end
10
13
 
14
+ # Get the full list of services with their status
15
+ # @param options to query list
16
+ # @return #[Hash[string]] A hash of statuses (passing|warning|critical) per service
11
17
  def self.get_all_services_status(options = {})
12
18
  result = {}
13
19
  services = Diplomat::Health.state('any', options)
metadata CHANGED
@@ -1,15 +1,15 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: diplomatic_bag
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.3.2
4
+ version: 2.4.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Nicolas Benoit
8
8
  - Pierre Souchay
9
- autorequire:
9
+ autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2020-02-28 00:00:00.000000000 Z
12
+ date: 2021-01-27 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: diplomat
@@ -17,14 +17,14 @@ dependencies:
17
17
  requirements:
18
18
  - - '='
19
19
  - !ruby/object:Gem::Version
20
- version: 2.3.2
20
+ version: 2.4.3
21
21
  type: :runtime
22
22
  prerelease: false
23
23
  version_requirements: !ruby/object:Gem::Requirement
24
24
  requirements:
25
25
  - - '='
26
26
  - !ruby/object:Gem::Version
27
- version: 2.3.2
27
+ version: 2.4.3
28
28
  description: Toolbox for Consul
29
29
  email:
30
30
  - n.benoit@criteo.com
@@ -46,7 +46,7 @@ homepage: https://github.com/WeAreFarmGeek/diplomat
46
46
  licenses:
47
47
  - BSD-3-Clause
48
48
  metadata: {}
49
- post_install_message:
49
+ post_install_message:
50
50
  rdoc_options: []
51
51
  require_paths:
52
52
  - lib
@@ -61,9 +61,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
61
61
  - !ruby/object:Gem::Version
62
62
  version: '0'
63
63
  requirements: []
64
- rubyforge_project:
65
- rubygems_version: 2.7.7
66
- signing_key:
64
+ rubygems_version: 3.1.2
65
+ signing_key:
67
66
  specification_version: 4
68
67
  summary: Toolbox for Consul
69
68
  test_files: []