lib/dalli/client.rb in dalli-1.0.0 vs lib/dalli/client.rb in dalli-1.0.1
- old
+ new
@@ -17,11 +17,11 @@
# Options:
# - :failover - if a server is down, look for and store values on another server in the ring. Default: true.
# - :threadsafe - ensure that only one thread is actively using a socket at a time. Default: true.
# - :expires_in - default TTL in seconds if you do not pass TTL as a parameter to an individual operation, defaults to 0 or forever
# - :compression - defaults to false, if true Dalli will compress values larger than 100 bytes before
- # sending them to memcached.
+ # sending them to memcached.
#
def initialize(servers=nil, options={})
@servers = env_servers || servers || 'localhost:11211'
@options = { :expires_in => 0 }.merge(options)
end
@@ -143,12 +143,10 @@
time = -delay
ring.servers.map { |s| s.request(:flush, time += delay) }
end
# deprecated, please use #flush.
- def flush_all(delay=0)
- flush(delay)
- end
+ alias_method :flush_all, :flush
##
# Incr adds the given amount to the counter on the memcached server.
# Amt must be a positive value.
#