protoboard 0.1.3 → 0.1.4

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
  SHA1:
3
- metadata.gz: e01a1ea9dda4c4cb8c9b89cfef74bb3d00431dad
4
- data.tar.gz: d92e50f697b6a174de88956170951bbf7627a79a
3
+ metadata.gz: 25a45012618f03a8e53549822a78acaaa9459beb
4
+ data.tar.gz: 6bfb8b60a987715d6d9d81336375cd86f23b0c82
5
5
  SHA512:
6
- metadata.gz: 57e78d10df3b84a5cce7320d6142515d4eb7bfd866479de0b0d6641e8092ade1c115b35ff50e10842a71d21ad095a8d758d149776488729c92b1fb872a56c6e5
7
- data.tar.gz: 36aeb19a4a4fd7a61448a8236974bb65b8fadd00aedecb80bb821e911d70b4f3c6868538926147d9ad87f215da238bb5e63385a5b72223dd65fbfecaf069aa0b
6
+ metadata.gz: ef9621414c1bcf91a36bb9cdc491fd324b453410d3d8c6f9dd9fc31361e4f17294b77ea1c1b103e5998378e6bd59f36f929288849a78973b8f9498577c37cc58
7
+ data.tar.gz: fd93416742ece1862979cbff05b5b39f65d6e06c1049034beb5ffc5d84429974c2219b4430df6b761b53f62ded29f00abe92f7a3dc121d91d226c947fa7c0798
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- protoboard (0.1.3)
4
+ protoboard (0.1.4)
5
5
  dry-configurable (~> 0.7.0)
6
6
  stoplight (~> 2.1.3)
7
7
 
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
- 'my_circuit1' => 'OK',
106
- 'my_circuit2' => 'NOT_OK'
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
- # 'services' => {
14
- # 'my_service_name' => {
15
- # 'circuits' => {
16
- # 'my_service_name#some_method' => 'OK',
17
- # 'my_custom_name' => 'NOT_OK'
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
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module Protoboard
4
- VERSION = '0.1.3'
4
+ VERSION = '0.1.4'
5
5
  end
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.3
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-06 00:00:00.000000000 Z
12
+ date: 2018-06-08 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: dry-configurable