protoboard 0.1.3 → 0.1.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/Gemfile.lock +1 -1
- data/README.md +4 -5
- data/lib/protoboard/circuit_breaker.rb +3 -2
- data/lib/protoboard/helpers/services_healthcheck_generator.rb +10 -8
- data/lib/protoboard/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 25a45012618f03a8e53549822a78acaaa9459beb
|
4
|
+
data.tar.gz: 6bfb8b60a987715d6d9d81336375cd86f23b0c82
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: ef9621414c1bcf91a36bb9cdc491fd324b453410d3d8c6f9dd9fc31361e4f17294b77ea1c1b103e5998378e6bd59f36f929288849a78973b8f9498577c37cc58
|
7
|
+
data.tar.gz: fd93416742ece1862979cbff05b5b39f65d6e06c1049034beb5ffc5d84429974c2219b4430df6b761b53f62ded29f00abe92f7a3dc121d91d226c947fa7c0798
|
data/Gemfile.lock
CHANGED
data/README.md
CHANGED
@@ -102,13 +102,12 @@ If you want to check the services and circuits registered in Protoboard you can
|
|
102
102
|
'services' => {
|
103
103
|
'my_service_name' => {
|
104
104
|
'circuits' => {
|
105
|
-
'
|
106
|
-
'
|
105
|
+
'some_namespace/my_service_name/SomeClass#some_method' => 'OK',
|
106
|
+
'my_custom_name' => 'NOT_OK'
|
107
107
|
}
|
108
|
-
|
109
|
-
|
108
|
+
}
|
109
|
+
}
|
110
110
|
}
|
111
|
-
|
112
111
|
```
|
113
112
|
|
114
113
|
|
@@ -34,6 +34,7 @@ module Protoboard
|
|
34
34
|
|
35
35
|
circuits = Protoboard::CircuitBreaker.create_circuits(
|
36
36
|
circuit_methods,
|
37
|
+
name,
|
37
38
|
options.merge(
|
38
39
|
fallback: fallback,
|
39
40
|
on_before: on_before,
|
@@ -83,11 +84,11 @@ module Protoboard
|
|
83
84
|
|
84
85
|
##
|
85
86
|
# Creates a new +circuit+.
|
86
|
-
def create_circuits(circuit_methods, options)
|
87
|
+
def create_circuits(circuit_methods,class_name, options)
|
87
88
|
circuit_hash = case circuit_methods
|
88
89
|
when Array
|
89
90
|
circuit_methods.reduce({}) do |memo, value|
|
90
|
-
memo.merge(value.to_sym => "#{formatted_namespace}#{options[:service]}\##{value}")
|
91
|
+
memo.merge(value.to_sym => "#{formatted_namespace}#{options[:service]}/#{class_name}\##{value}")
|
91
92
|
end
|
92
93
|
when Hash
|
93
94
|
circuit_methods
|
@@ -10,14 +10,16 @@ module Protoboard
|
|
10
10
|
# Verifies the list of +circuits+ added and returns a hash with the +circuits names+ and its states.
|
11
11
|
#
|
12
12
|
# ==== Examples
|
13
|
-
#
|
14
|
-
# '
|
15
|
-
#
|
16
|
-
#
|
17
|
-
#
|
18
|
-
#
|
19
|
-
#
|
20
|
-
#
|
13
|
+
# {
|
14
|
+
# 'services' => {
|
15
|
+
# 'my_service_name' => {
|
16
|
+
# 'circuits' => {
|
17
|
+
# 'some_namespace/my_service_name/SomeClass#some_method' => 'OK',
|
18
|
+
# 'my_custom_name' => 'NOT_OK'
|
19
|
+
# }
|
20
|
+
# }
|
21
|
+
# }
|
22
|
+
# }
|
21
23
|
# ====
|
22
24
|
#
|
23
25
|
def call
|
data/lib/protoboard/version.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: protoboard
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.4
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Carlos Atkinson
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: exe
|
11
11
|
cert_chain: []
|
12
|
-
date: 2018-06-
|
12
|
+
date: 2018-06-08 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: dry-configurable
|