rgossip2 0.1.6 → 0.1.7

Sign up to get free protection for your applications and to get access to all the features.
@@ -162,9 +162,14 @@ module RGossip2
162
162
 
163
163
  # デッドリストのクリーニング
164
164
  def clear_dead_list
165
+ dead_list_len = 0
166
+
165
167
  @dead_list.synchronize {
168
+ dead_list_len = @dead_list.length
166
169
  @dead_list.clear
167
170
  }
171
+
172
+ return dead_list_len
168
173
  end
169
174
 
170
175
  # ノードを舐める
@@ -26,7 +26,7 @@ module RGossip2
26
26
  end
27
27
 
28
28
  # Hashに委譲
29
- def_delegators :@nodes, :[], :[]=, :delete
29
+ def_delegators :@nodes, :[], :[]=, :delete, :clear, :length
30
30
 
31
31
  # Nodeの配列でイテレートする
32
32
  def each
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: rgossip2
3
3
  version: !ruby/object:Gem::Version
4
- hash: 23
4
+ hash: 21
5
5
  prerelease:
6
6
  segments:
7
7
  - 0
8
8
  - 1
9
- - 6
10
- version: 0.1.6
9
+ - 7
10
+ version: 0.1.7
11
11
  platform: ruby
12
12
  authors:
13
13
  - winebarrel