boutons 0.4.8 → 0.4.9

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: 90e02e2e17840313b40059cba5b299b12f0613d1
4
- data.tar.gz: f9930675ef228f59f447e53add00c85c27c50a6f
3
+ metadata.gz: 6e675d81810f244e9154b555c99cec37264978b4
4
+ data.tar.gz: 2276c448854581ff2dce7e1e478c8e0817615b38
5
5
  SHA512:
6
- metadata.gz: 09d92c57d785ed7d3d3febab98a29a6e27e14fe1de5de9dc7d7660ed6b64667e7666aa4fc6401f64806413ae6799f8fbd8f7baefe631462d07f634fd3c96a74b
7
- data.tar.gz: 460ecbda7c336496f2b3c329a132c9d176264152ba74335e6362676e974738e790a3dec997ac13c4c280311e99733f6d5c6c183300b28b6832759e251bc92734
6
+ metadata.gz: 83bdc50e3ee82b747115a64a47e05d564da294730aacc9fb6c3d2392482facee325729789bd537d51d34a3da54692de56c2b8207716e2d3610ee3c4f172734b8
7
+ data.tar.gz: 7cceba7b9b6f542dc7f6fadf950738ee416073bdc2ed56079f1a4c405dd10e81c42caa215f4d73bda3ef52ada00602b249a1e9c8196fbf433368c5fd6f74764e
data/README.md CHANGED
@@ -55,6 +55,12 @@ Boutons can also add synapses at runtime.
55
55
  Boutons.provide "smtp", "zookeeper://zookeeper.mail.company.com:2181/outbound-relay/smtp"
56
56
  puts Boutons.smtp.to_s("%h:%p")
57
57
 
58
+ A bit more complex
59
+
60
+ Boutons.provide "weather", "zookeeper+http://zk.weather.earth:2181/europe#/health"
61
+
62
+ Will set the type to http and check if the server by GETting /health.
63
+
58
64
  ## String-Format
59
65
 
60
66
  the to_s method prints the local uri as default. You may provide some kind of format-string to your needs. The following placeholders will be replaces by it's value:
@@ -1,3 +1,3 @@
1
1
  module Boutons
2
- VERSION = "0.4.8"
2
+ VERSION = "0.4.9"
3
3
  end
data/lib/boutons.rb CHANGED
@@ -32,7 +32,8 @@ module Boutons
32
32
  params[:path] = uri.registry.zk_path
33
33
  params[:hosts] = uri.registry.zk_hosts
34
34
  params[:name] = service.to_sym
35
- add Synapse::Easy::Service.new params
35
+ synapse = Synapse::Easy::Service.new params
36
+ add(synapse) and return synapse
36
37
  end
37
38
  def remove name
38
39
  services[mapping[name]] = nil
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: boutons
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.4.8
4
+ version: 0.4.9
5
5
  platform: ruby
6
6
  authors:
7
7
  - Mathias Kaufmann