boutons 0.4.3 → 0.4.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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 8404a07f91159d2d6e43aaa0c4373ade25bec0b7
4
- data.tar.gz: 15be8b55b0f1b027d1417658cb606d4aeede9bc8
3
+ metadata.gz: f8c5c658913f95268eb4b5a1d61afbb136e5f9ae
4
+ data.tar.gz: b4c7c25727e06438529ed2a94f76e30236b4f3c4
5
5
  SHA512:
6
- metadata.gz: f25c2b2d639728003cd7a28550c17bf221846dfbe30456e3863f7edd8689c752b9618223e38b8f010e79a923ce9c81c58e02a92d6e59f3f7fb9303a043f0fc5e
7
- data.tar.gz: 26939ca4317d773232c148d35a398f7148fe0ad0b67d19a20004bc22c1cf5d07d38d5417ec9838b66f811aa9e9a585c9aa72c019881339a32bf34c0045c4fc57
6
+ metadata.gz: 3092f22743c1caef1a3eabe97976db939df673dbc3dafe1a8dcd2ba5859d9bfded3990ed24e862709d1976a51af367fc9812e96e064686105e91e675d7172246
7
+ data.tar.gz: b94c370fb516aaa08b169f85fc855b4ca9f111236d9c2bf6473968ef65cc8391d8a967a9725d562865a32fee111b573683d109a15acdeddd0eb8aa3a400a60c3
@@ -125,8 +125,9 @@ module Boutons
125
125
  uri = Boutons::URI.new service_uri
126
126
  params = {}
127
127
  params[:application] = uri.host
128
+ params[:mode] = uri.mode
129
+ params[:uri] = uri.check_uri
128
130
  params[:method] = uri.registry.method
129
- params[:type] = uri.registry.type
130
131
  params[:path] = uri.registry.zk_path
131
132
  params[:hosts] = uri.registry.zk_hosts
132
133
  params[:name] = service
@@ -13,9 +13,6 @@ module Boutons
13
13
  def method
14
14
  @uri.scheme.split("+")[0]
15
15
  end
16
- def type
17
- @uri.scheme.split("+")[1] || "tcp"
18
- end
19
16
  def zk_hosts
20
17
  @hosts = []
21
18
  if @uri.host
@@ -69,7 +66,7 @@ module Boutons
69
66
  end
70
67
  end
71
68
  def zk_path
72
- @uri.path
69
+ ::URI.unescape(@uri.path).split("#",2)[0]
73
70
  end
74
71
  end
75
72
  def initialize uri
@@ -79,9 +76,17 @@ module Boutons
79
76
  def registry
80
77
  @registry ||= Registry.new @uri
81
78
  end
79
+ def mode
80
+ end
82
81
  def type
83
82
  @uri.scheme
84
83
  end
84
+ def mode
85
+ @uri.scheme.split("+")[1] || "tcp"
86
+ end
87
+ def check_uri
88
+ ::URI.unescape(@uri.path).split("#",2)[1] || "/"
89
+ end
85
90
  private
86
91
  def method_missing method, *args, &block
87
92
  @uri.send method, *args, &block
@@ -1,3 +1,3 @@
1
1
  module Boutons
2
- VERSION = "0.4.3"
2
+ VERSION = "0.4.4"
3
3
  end
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.3
4
+ version: 0.4.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Mathias Kaufmann