odania 0.0.14 → 0.0.15

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 6b25cd590a38977bc30861e4b0a9552731c22995
4
- data.tar.gz: 940785a1695d98c61a46590314c7f733c0e8af2d
3
+ metadata.gz: 873375ded1a7a7134b41490f71ac169daff40d22
4
+ data.tar.gz: 583057469c6cb16fb84bee391f0a0b5784ff9107
5
5
  SHA512:
6
- metadata.gz: 7d81101ba6509293269e7b091df110faca516e517a72c50134fba37f9fa47d79858dc8d100d322f3a80c7f3c7ab23f674ec5ba51c5e114c7e2a077b338c6050a
7
- data.tar.gz: 2dad96a940a60d565d048abc4939177b944a4e7748eb77094cb007abd53be1167b93c195ed94a81832ed54e34fe39078cd9ed53175b63eaa3888d80208653615
6
+ metadata.gz: 588cc513d44e2d505a7475685aa428aeb5ce91508faa55f02708e02155b262704372b7a8f5d915f8c551ece85df639507b70546b3706e51f75193a7fe0ab9718
7
+ data.tar.gz: c2d6875df759483ca33e007fdbddacd157c00ea6a0ddf04512460707a9038b951c10797e48ea3adfd6012bebb0b8f41869136c60de9530257ebdf55c6ba0189b
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- odania (0.0.14)
4
+ odania (0.0.15)
5
5
  diplomat
6
6
 
7
7
  GEM
@@ -8,9 +8,9 @@ module Odania
8
8
  end
9
9
  end
10
10
 
11
- def get(name)
11
+ def get(name, scope=:first)
12
12
  begin
13
- Diplomat::Service.get(name)
13
+ Diplomat::Service.get(name, scope)
14
14
  rescue Diplomat::PathNotFound => e
15
15
  puts "Service not found: #{e}"
16
16
  puts e.backtrace.inspect
@@ -19,11 +19,16 @@ module Odania
19
19
  end
20
20
  end
21
21
 
22
+ def get_all
23
+ Diplomat::Service.get_all
24
+ end
25
+
22
26
  def consul_service_config(plugin_name, plugin_instance_name, ip, tags=[], port=80)
23
27
  {
24
28
  'id' => plugin_instance_name,
25
29
  'name' => plugin_name,
26
30
  'tags' => tags,
31
+ 'address' => ip,
27
32
  'port' => port,
28
33
  'token' => plugin_instance_name,
29
34
  'checks' => [
@@ -1,3 +1,3 @@
1
1
  module Odania
2
- VERSION = '0.0.14'
2
+ VERSION = '0.0.15'
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: odania
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.14
4
+ version: 0.0.15
5
5
  platform: ruby
6
6
  authors:
7
7
  - Mike Petersen