dalli 2.7.0 → 2.7.11
Sign up to get free protection for your applications and to get access to all the features.
Potentially problematic release.
This version of dalli might be problematic. Click here for more details.
- checksums.yaml +5 -5
- data/Gemfile +6 -3
- data/History.md +94 -0
- data/LICENSE +1 -1
- data/README.md +62 -43
- data/lib/action_dispatch/middleware/session/dalli_store.rb +2 -1
- data/lib/active_support/cache/dalli_store.rb +121 -41
- data/lib/dalli/cas/client.rb +5 -4
- data/lib/dalli/client.rb +103 -52
- data/lib/dalli/compressor.rb +2 -1
- data/lib/dalli/options.rb +1 -0
- data/lib/dalli/railtie.rb +1 -0
- data/lib/dalli/ring.rb +6 -6
- data/lib/dalli/server.rb +151 -91
- data/lib/dalli/socket.rb +104 -42
- data/lib/dalli/version.rb +2 -1
- data/lib/dalli.rb +3 -0
- data/lib/rack/session/dalli.rb +140 -27
- metadata +22 -95
- data/Performance.md +0 -42
- data/Rakefile +0 -42
- data/dalli.gemspec +0 -29
- data/test/benchmark_test.rb +0 -242
- data/test/helper.rb +0 -55
- data/test/memcached_mock.rb +0 -121
- data/test/sasldb +0 -1
- data/test/test_active_support.rb +0 -427
- data/test/test_cas_client.rb +0 -107
- data/test/test_compressor.rb +0 -53
- data/test/test_dalli.rb +0 -601
- data/test/test_encoding.rb +0 -32
- data/test/test_failover.rb +0 -128
- data/test/test_network.rb +0 -54
- data/test/test_rack_session.rb +0 -321
- data/test/test_ring.rb +0 -85
- data/test/test_sasl.rb +0 -110
- data/test/test_serializer.rb +0 -30
data/test/test_serializer.rb
DELETED
@@ -1,30 +0,0 @@
|
|
1
|
-
# encoding: utf-8
|
2
|
-
require 'helper'
|
3
|
-
require 'json'
|
4
|
-
require 'memcached_mock'
|
5
|
-
|
6
|
-
describe 'Serializer' do
|
7
|
-
|
8
|
-
it 'default to Marshal' do
|
9
|
-
memcached_kill(29198) do |dc|
|
10
|
-
memcache = Dalli::Client.new('127.0.0.1:29198')
|
11
|
-
memcache.set 1,2
|
12
|
-
assert_equal Marshal, memcache.instance_variable_get('@ring').servers.first.serializer
|
13
|
-
end
|
14
|
-
end
|
15
|
-
|
16
|
-
it 'support a custom serializer' do
|
17
|
-
memcached_kill(29198) do |dc|
|
18
|
-
memcache = Dalli::Client.new('127.0.0.1:29198', :serializer => JSON)
|
19
|
-
memcache.set 1,2
|
20
|
-
begin
|
21
|
-
assert_equal JSON, memcache.instance_variable_get('@ring').servers.first.serializer
|
22
|
-
|
23
|
-
memcached(19128) do |newdc|
|
24
|
-
assert newdc.set("json_test", {"foo" => "bar"})
|
25
|
-
assert_equal({"foo" => "bar"}, newdc.get("json_test"))
|
26
|
-
end
|
27
|
-
end
|
28
|
-
end
|
29
|
-
end
|
30
|
-
end
|