jsierles-memcache-client 1.5.0.5 → 1.5.0.6

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.
Files changed (2) hide show
  1. data/lib/memcache.rb +9 -2
  2. metadata +1 -1
@@ -18,7 +18,7 @@ class MemCache
18
18
  ##
19
19
  # The version of MemCache you are using.
20
20
 
21
- VERSION = '1.5.0.5'
21
+ VERSION = '1.5.0.6'
22
22
 
23
23
  ##
24
24
  # Default options for the cache object.
@@ -661,6 +661,13 @@ class MemCache
661
661
 
662
662
  CONNECT_TIMEOUT = 0.25
663
663
 
664
+ ##
665
+ # The amount of time to wait for a response from a memcached server.
666
+ # If a response isn't received within this time limit,
667
+ # the server will be marked as down.
668
+
669
+ SOCKET_TIMEOUT = 0.25
670
+
664
671
  ##
665
672
  # The amount of time to wait before attempting to re-establish a
666
673
  # connection with a server that is marked dead.
@@ -801,7 +808,7 @@ class TCPTimeoutSocket
801
808
  def initialize(*args)
802
809
  Timeout::timeout(MemCache::Server::CONNECT_TIMEOUT, SocketError) do
803
810
  @sock = TCPSocket.new(*args)
804
- @len = ENV['MEMCACHE_SOCKET_TIMEOUT'].to_f || 0.5
811
+ @len = MemCache::Server::SOCKET_TIMEOUT
805
812
  end
806
813
  end
807
814
 
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: jsierles-memcache-client
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.5.0.5
4
+ version: 1.5.0.6
5
5
  platform: ruby
6
6
  authors:
7
7
  - Eric Hodel