mperham-politics 0.2.3 → 0.2.4

Sign up to get free protection for your applications and to get access to all the features.
data/History.rdoc CHANGED
@@ -1,8 +1,12 @@
1
1
  = Changelog
2
2
 
3
+ == 0.2.4 (2009-01-28)
4
+
5
+ * Reduce leader token expiration time to discourage a get/set race condition. (Brian Dainton)
6
+
3
7
  == 0.2.3 (2009-01-12)
4
8
 
5
- * FIx invalid result check in previous change. (Brian Dainton)
9
+ * Fix invalid result check in previous change. (Brian Dainton)
6
10
 
7
11
  == 0.2.2 (2009-01-07)
8
12
 
@@ -145,7 +145,7 @@ module Politics
145
145
  # The result will tell us if memcached stored our value and therefore
146
146
  # if we are now leader.
147
147
  def nominate
148
- result = memcache_client.add(token, worker_name, iteration_length)
148
+ result = memcache_client.add(token, worker_name, (iteration_length * 0.9).to_i)
149
149
  @leader = (result =~ /\ASTORED/)
150
150
  end
151
151
 
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: mperham-politics
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.3
4
+ version: 0.2.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Mike Perham