ruby_skynet 1.2.6 → 1.2.7
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/ruby_skynet/version.rb +1 -1
- data/lib/ruby_skynet/zookeeper/registry.rb +14 -10
- 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: d66558afbf4e84bec8db1eb77f09b6e2f2157cfd
|
4
|
+
data.tar.gz: 7d99411322f3550d9cbc4bfca9305470d622b6dc
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 473f10c3632f770220484db927cc9ca3052c6e5b963e90ffae00eaa8358697a5a262f8189db88fe42127f549325ce0031009c68c98fd6b431145d568a323dab6
|
7
|
+
data.tar.gz: 4e76abe1ce6771be9f397918dfe8b61e2c325364cae0067ee6cf8d1ab985a31e017636cfaa19dd54eb806455d021928ceaede6fa9f2ac9f8600a107a4fa88912
|
data/lib/ruby_skynet/version.rb
CHANGED
@@ -330,16 +330,20 @@ module RubySkynet
|
|
330
330
|
logger.trace "Event Received", event_hash
|
331
331
|
case event_hash[:type]
|
332
332
|
when ::Zookeeper::ZOO_CHANGED_EVENT
|
333
|
-
|
334
|
-
|
335
|
-
|
336
|
-
|
337
|
-
|
338
|
-
|
339
|
-
|
340
|
-
|
341
|
-
|
342
|
-
|
333
|
+
begin
|
334
|
+
logger.debug "Node '#{path}' Changed", event_hash
|
335
|
+
|
336
|
+
# Fetch current value and re-subscribe
|
337
|
+
result = @zookeeper.get(:path => path, :watcher => @watch_proc)
|
338
|
+
check_rc(result)
|
339
|
+
value = @deserializer.deserialize(result[:data])
|
340
|
+
stat = result[:stat]
|
341
|
+
|
342
|
+
# Invoke on_update callbacks
|
343
|
+
node_updated(relative_key(path), value, stat.version)
|
344
|
+
rescue ::Zookeeper::Exceptions::NoNode
|
345
|
+
# Ignore errors where the value changes and then deleted
|
346
|
+
end
|
343
347
|
|
344
348
|
when ::Zookeeper::ZOO_DELETED_EVENT
|
345
349
|
# A node has been deleted
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: ruby_skynet
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.2.
|
4
|
+
version: 1.2.7
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Reid Morrison
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2013-09-
|
11
|
+
date: 2013-09-19 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: semantic_logger
|