ngmoco-cache-money 0.2.10 → 0.2.13
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.
- data/LICENSE +201 -0
- data/README +16 -0
- data/README.markdown +210 -0
- data/config/environment.rb +12 -2
- data/db/schema.rb +6 -0
- data/lib/cache_money.rb +38 -9
- data/lib/cash/buffered.rb +7 -4
- data/lib/cash/config.rb +6 -3
- data/lib/cash/index.rb +6 -1
- data/lib/cash/local.rb +10 -6
- data/lib/cash/lock.rb +11 -4
- data/lib/cash/mock.rb +154 -0
- data/lib/cash/query/abstract.rb +14 -6
- data/lib/cash/query/primary_key.rb +0 -1
- data/lib/cash/transactional.rb +5 -4
- data/lib/cash/write_through.rb +5 -8
- data/lib/mem_cached_session_store.rb +49 -0
- data/lib/mem_cached_support_store.rb +135 -0
- data/lib/memcached_wrapper.rb +3 -2
- data/rails/init.rb +12 -11
- data/spec/cash/accessor_spec.rb +39 -27
- data/spec/cash/active_record_spec.rb +14 -1
- data/spec/cash/buffered_spec.rb +9 -0
- data/spec/cash/calculations_spec.rb +1 -1
- data/spec/cash/finders_spec.rb +38 -2
- data/spec/cash/local_buffer_spec.rb +9 -0
- data/spec/cash/local_spec.rb +9 -0
- data/spec/cash/lock_spec.rb +3 -4
- data/spec/cash/order_spec.rb +1 -1
- data/spec/cash/transactional_spec.rb +16 -12
- data/spec/cash/window_spec.rb +1 -1
- data/spec/cash/write_through_spec.rb +1 -1
- data/spec/memcached_wrapper_test.rb +209 -0
- data/spec/spec_helper.rb +6 -3
- metadata +53 -24
data/spec/cash/lock_spec.rb
CHANGED
@@ -1,4 +1,4 @@
|
|
1
|
-
require
|
1
|
+
require "spec_helper"
|
2
2
|
|
3
3
|
module Cash
|
4
4
|
describe Lock do
|
@@ -22,7 +22,6 @@ module Cash
|
|
22
22
|
$memcache.get("lock/lock_key").should == nil
|
23
23
|
$lock.synchronize('lock_key') {}
|
24
24
|
$memcache.get("lock/lock_key").should == nil
|
25
|
-
|
26
25
|
end
|
27
26
|
|
28
27
|
it "releases the lock even if the block raises" do
|
@@ -47,7 +46,7 @@ module Cash
|
|
47
46
|
|
48
47
|
describe 'when given a timeout for the lock' do
|
49
48
|
it "correctly sets timeout on memcache entries" do
|
50
|
-
mock($memcache).add('lock/lock_key', Process.pid, timeout = 10) { true }
|
49
|
+
mock($memcache).add('lock/lock_key', "#{Socket.gethostname} #{Process.pid}", timeout = 10) { true }
|
51
50
|
# $lock.acquire_lock('lock_key', timeout)
|
52
51
|
lambda { $lock.acquire_lock('lock_key', timeout, 1) }.should raise_error
|
53
52
|
end
|
@@ -66,7 +65,7 @@ module Cash
|
|
66
65
|
it "retries specified number of times" do
|
67
66
|
$lock.acquire_lock('lock_key')
|
68
67
|
as_another_process do
|
69
|
-
mock($memcache).add("lock/lock_key", Process.pid, timeout = 10) { false }.times(retries = 3)
|
68
|
+
mock($memcache).add("lock/lock_key", "#{Socket.gethostname} #{Process.pid}", timeout = 10) { false }.times(retries = 3)
|
70
69
|
stub($lock).exponential_sleep
|
71
70
|
lambda { $lock.acquire_lock('lock_key', timeout, retries) }.should raise_error
|
72
71
|
end
|
data/spec/cash/order_spec.rb
CHANGED
@@ -1,4 +1,4 @@
|
|
1
|
-
require
|
1
|
+
require "spec_helper"
|
2
2
|
|
3
3
|
module Cash
|
4
4
|
describe Transactional do
|
@@ -20,7 +20,7 @@ module Cash
|
|
20
20
|
end
|
21
21
|
|
22
22
|
it "increments through the real cache" do
|
23
|
-
@cache.set(@key, 0)
|
23
|
+
@cache.set(@key, 0, 0, true)
|
24
24
|
@cache.incr(@key, 3)
|
25
25
|
|
26
26
|
@cache.get(@key, true).to_i.should == 3
|
@@ -28,7 +28,7 @@ module Cash
|
|
28
28
|
end
|
29
29
|
|
30
30
|
it "decrements through the real cache" do
|
31
|
-
@cache.set(@key, 0)
|
31
|
+
@cache.set(@key, 0, 0, true)
|
32
32
|
@cache.incr(@key, 3)
|
33
33
|
@cache.decr(@key, 2)
|
34
34
|
|
@@ -130,7 +130,7 @@ module Cash
|
|
130
130
|
describe 'Increment and Decrement' do
|
131
131
|
describe '#incr' do
|
132
132
|
it "works" do
|
133
|
-
@cache.set(@key, 0)
|
133
|
+
@cache.set(@key, 0, 0, true)
|
134
134
|
@cache.incr(@key)
|
135
135
|
@cache.transaction do
|
136
136
|
@cache.incr(@key).should == 2
|
@@ -139,7 +139,7 @@ module Cash
|
|
139
139
|
|
140
140
|
it "is buffered" do
|
141
141
|
@cache.transaction do
|
142
|
-
@cache.set(@key, 0)
|
142
|
+
@cache.set(@key, 0, 0, true)
|
143
143
|
@cache.incr(@key, 2).should == 2
|
144
144
|
@cache.get(@key).should == 2
|
145
145
|
$memcache.get(@key).should == nil
|
@@ -158,7 +158,7 @@ module Cash
|
|
158
158
|
|
159
159
|
describe '#decr' do
|
160
160
|
it "works" do
|
161
|
-
@cache.set(@key, 0)
|
161
|
+
@cache.set(@key, 0, 0, true)
|
162
162
|
@cache.incr(@key)
|
163
163
|
@cache.transaction do
|
164
164
|
@cache.decr(@key).should == 0
|
@@ -167,7 +167,7 @@ module Cash
|
|
167
167
|
|
168
168
|
it "is buffered" do
|
169
169
|
@cache.transaction do
|
170
|
-
@cache.set(@key, 0)
|
170
|
+
@cache.set(@key, 0, 0, true)
|
171
171
|
@cache.incr(@key, 3)
|
172
172
|
@cache.decr(@key, 2).should == 1
|
173
173
|
@cache.get(@key, true).to_i.should == 1
|
@@ -185,7 +185,7 @@ module Cash
|
|
185
185
|
|
186
186
|
it "bottoms out at zero" do
|
187
187
|
@cache.transaction do
|
188
|
-
@cache.set(@key, 0)
|
188
|
+
@cache.set(@key, 0, 0, true)
|
189
189
|
@cache.incr(@key, 1)
|
190
190
|
@cache.get(@key, true).should == 1
|
191
191
|
@cache.decr(@key)
|
@@ -336,7 +336,7 @@ module Cash
|
|
336
336
|
|
337
337
|
describe '#incr' do
|
338
338
|
it "increment be atomic" do
|
339
|
-
@cache.set(@key, 0)
|
339
|
+
@cache.set(@key, 0, 0, true)
|
340
340
|
@cache.transaction do
|
341
341
|
@cache.incr(@key)
|
342
342
|
$memcache.incr(@key)
|
@@ -346,11 +346,11 @@ module Cash
|
|
346
346
|
end
|
347
347
|
|
348
348
|
it "interleaved, etc. increments and sets be ordered" do
|
349
|
-
@cache.set(@key, 0)
|
349
|
+
@cache.set(@key, 0, 0, true)
|
350
350
|
@cache.transaction do
|
351
351
|
@cache.incr(@key)
|
352
352
|
@cache.incr(@key)
|
353
|
-
@cache.set(@key, 0)
|
353
|
+
@cache.set(@key, 0, 0, true)
|
354
354
|
@cache.incr(@key)
|
355
355
|
@cache.incr(@key)
|
356
356
|
end
|
@@ -361,7 +361,7 @@ module Cash
|
|
361
361
|
|
362
362
|
describe '#decr' do
|
363
363
|
it "decrement be atomic" do
|
364
|
-
@cache.set(@key, 0)
|
364
|
+
@cache.set(@key, 0, 0, true)
|
365
365
|
@cache.incr(@key, 3)
|
366
366
|
@cache.transaction do
|
367
367
|
@cache.decr(@key)
|
@@ -570,5 +570,9 @@ module Cash
|
|
570
570
|
end
|
571
571
|
end
|
572
572
|
end
|
573
|
+
|
574
|
+
it "should have method_missing as a private method" do
|
575
|
+
Transactional.private_instance_methods.should include("method_missing")
|
576
|
+
end
|
573
577
|
end
|
574
578
|
end
|
data/spec/cash/window_spec.rb
CHANGED
@@ -0,0 +1,209 @@
|
|
1
|
+
require 'test_helper'
|
2
|
+
require 'memcache'
|
3
|
+
|
4
|
+
class MemcachedWrapperTest < ActiveSupport::TestCase
|
5
|
+
|
6
|
+
context "with single memcached server" do
|
7
|
+
|
8
|
+
setup do
|
9
|
+
@wrapper = MemcachedWrapper.new("127.0.0.1:11211", {:namespace => "wrapper", :show_backtraces => true, :support_cas => true})
|
10
|
+
@memcache = MemCache.new("127.0.0.1:11211", {:namespace => "memcache"})
|
11
|
+
@wrapper.flush_all
|
12
|
+
@memcache.flush_all
|
13
|
+
end
|
14
|
+
|
15
|
+
teardown do
|
16
|
+
@wrapper.close
|
17
|
+
@memcache.reset
|
18
|
+
end
|
19
|
+
|
20
|
+
should "add" do
|
21
|
+
assert_equal(@wrapper.add("blah/toe", "blah"), @memcache.add("blah/toe", "blah"))
|
22
|
+
assert_equal(@wrapper.get("blah/toe"), @memcache.get("blah/toe"))
|
23
|
+
assert_equal(@wrapper.add("blah/toe", "blah2"), @memcache.add("blah/toe", "blah2"))
|
24
|
+
assert_equal(@wrapper.get("blah/toe"), @memcache.get("blah/toe"))
|
25
|
+
end
|
26
|
+
|
27
|
+
should "replace" do
|
28
|
+
assert_equal(@wrapper.replace("blah/toe", "blah"), @memcache.replace("blah/toe", "blah"))
|
29
|
+
assert_equal(@wrapper.add("blah/toe", "blah"), @memcache.add("blah/toe", "blah"))
|
30
|
+
assert_equal(@wrapper.replace("blah/toe", "blah2"), @memcache.replace("blah/toe", "blah2"))
|
31
|
+
assert_equal(@wrapper.get("blah/toe"), @memcache.get("blah/toe"))
|
32
|
+
end
|
33
|
+
|
34
|
+
should "get" do
|
35
|
+
assert_equal(@wrapper.add("blah/toe", "blah"), @memcache.add("blah/toe", "blah"))
|
36
|
+
assert_equal(@wrapper.get("blah/toe"), @memcache.get("blah/toe"))
|
37
|
+
end
|
38
|
+
|
39
|
+
should "fetch" do
|
40
|
+
assert_equal(@wrapper.fetch("blah/toe") { "blah" }, @memcache.fetch("blah/toe") { "blah" })
|
41
|
+
assert_equal(@wrapper.fetch("blah/toe") { "blah2" }, @memcache.fetch("blah/toe") { "blah2" })
|
42
|
+
end
|
43
|
+
|
44
|
+
should "compare and swap" do
|
45
|
+
assert_equal(@wrapper.cas("blah/toe") { "blah" }, @memcache.cas("blah/toe") { "blah" })
|
46
|
+
assert_equal(@wrapper.add("blah/toe", "blah"), @memcache.add("blah/toe", "blah"))
|
47
|
+
assert_equal(@wrapper.cas("blah/toe") { "blah2" }, @memcache.cas("blah/toe") { "blah2" })
|
48
|
+
assert_equal(@wrapper.get("blah/toe"), @memcache.get("blah/toe"))
|
49
|
+
end
|
50
|
+
|
51
|
+
should "get multiple" do
|
52
|
+
assert_equal(@wrapper.add("blah/toe", "blah"), @memcache.add("blah/toe", "blah"))
|
53
|
+
assert_equal(@wrapper.add("blah/finger", "blah2"), @memcache.add("blah/finger", "blah2"))
|
54
|
+
assert_equal(@wrapper.get_multi(["blah/toe", "blah/finger"]), @memcache.get_multi(["blah/toe", "blah/finger"]))
|
55
|
+
end
|
56
|
+
|
57
|
+
should "set" do
|
58
|
+
assert_equal(@wrapper.set("blah/toe", "blah"), @memcache.set("blah/toe", "blah"))
|
59
|
+
assert_equal(@wrapper.get("blah/toe"), @memcache.get("blah/toe"))
|
60
|
+
end
|
61
|
+
|
62
|
+
should "append" do
|
63
|
+
assert_equal(@wrapper.append("blah/toe", "blah"), @memcache.append("blah/toe", "blah"))
|
64
|
+
assert_equal(@wrapper.get("blah/toe"), @memcache.get("blah/toe"))
|
65
|
+
|
66
|
+
assert_equal(@wrapper.set("blah/toe", "blah", 0, true), @memcache.set("blah/toe", "blah", 0, true))
|
67
|
+
assert_equal(@wrapper.get("blah/toe", true), @memcache.get("blah/toe", true))
|
68
|
+
assert_equal(@wrapper.append("blah/toe", "blah2"), @memcache.append("blah/toe", "blah2"))
|
69
|
+
assert_equal(@wrapper.get("blah/toe", true), @memcache.get("blah/toe", true))
|
70
|
+
end
|
71
|
+
|
72
|
+
should "prepend" do
|
73
|
+
assert_equal(@wrapper.prepend("blah/toe", "blah"), @memcache.prepend("blah/toe", "blah"))
|
74
|
+
assert_equal(@wrapper.get("blah/toe"), @memcache.get("blah/toe"))
|
75
|
+
|
76
|
+
assert_equal(@wrapper.set("blah/toe", "blah", 0, true), @memcache.set("blah/toe", "blah", 0, true))
|
77
|
+
assert_equal(@wrapper.prepend("blah/toe", "blah2"), @memcache.prepend("blah/toe", "blah2"))
|
78
|
+
assert_equal(@wrapper.get("blah/toe", true), @memcache.get("blah/toe", true))
|
79
|
+
end
|
80
|
+
|
81
|
+
should "delete" do
|
82
|
+
assert_equal(@wrapper.delete("blah/toe"), @memcache.delete("blah/toe"))
|
83
|
+
assert_equal(@wrapper.set("blah/toe", "blah"), @memcache.set("blah/toe", "blah"))
|
84
|
+
assert_equal(@wrapper.delete("blah/toe"), @memcache.delete("blah/toe"))
|
85
|
+
end
|
86
|
+
|
87
|
+
should "increment" do
|
88
|
+
assert_equal(@wrapper.incr("blah/count"), @memcache.incr("blah/count"))
|
89
|
+
assert_equal(@wrapper.set("blah/count", 0, 0, true), @memcache.set("blah/count", 0, 0, true))
|
90
|
+
assert_equal(@wrapper.incr("blah/count"), @memcache.incr("blah/count"))
|
91
|
+
end
|
92
|
+
|
93
|
+
should "decrement" do
|
94
|
+
assert_equal(@wrapper.decr("blah/count"), @memcache.decr("blah/count"))
|
95
|
+
assert_equal(@wrapper.set("blah/count", 2, 0, true), @memcache.set("blah/count", 2, 0, true))
|
96
|
+
assert_equal(@wrapper.decr("blah/count"), @memcache.decr("blah/count"))
|
97
|
+
end
|
98
|
+
|
99
|
+
# should "stats" do
|
100
|
+
# assert_equal(@wrapper.stats(), @memcache.stats())
|
101
|
+
# end
|
102
|
+
|
103
|
+
end
|
104
|
+
|
105
|
+
# context "with two memcached servers" do
|
106
|
+
#
|
107
|
+
# setup do
|
108
|
+
# @wrapper = MemcachedWrapper.new(["127.0.0.1:11211", "127.0.0.1:1111"], {:show_backtraces => true, :support_cas => true})
|
109
|
+
# # @wrapper = MemCache.new(["127.0.0.1:11211", "127.0.0.1:1111"], {:show_backtraces => true, :support_cas => true})
|
110
|
+
# @wrapper.flush_all
|
111
|
+
# end
|
112
|
+
#
|
113
|
+
# teardown do
|
114
|
+
# # @wrapper.close
|
115
|
+
# end
|
116
|
+
#
|
117
|
+
# should "add value" do
|
118
|
+
# assert_stored(@wrapper.add("blah/toe", "blah"))
|
119
|
+
# assert_equal( "blah", @wrapper.get("blah/toe"))
|
120
|
+
# assert_not_stored(@wrapper.add("blah/toe", "blah2"))
|
121
|
+
# assert_equal( "blah", @wrapper.get("blah/toe"))
|
122
|
+
# end
|
123
|
+
#
|
124
|
+
# should "get value" do
|
125
|
+
# assert_stored(@wrapper.add("blah/toe", "blah"))
|
126
|
+
# assert_equal( "blah", @wrapper.get("blah/toe"))
|
127
|
+
# end
|
128
|
+
#
|
129
|
+
# should "fetch value" do
|
130
|
+
# assert_equal( "blah", @wrapper.fetch("blah/toe") { "blah" })
|
131
|
+
# assert_equal( "blah", @wrapper.fetch("blah/toe") { "blah2" })
|
132
|
+
# end
|
133
|
+
#
|
134
|
+
# should "check and set value" do
|
135
|
+
# assert_nil( @wrapper.cas("blah/toe") { "blah" })
|
136
|
+
# assert_stored(@wrapper.add("blah/toe", "blah"))
|
137
|
+
# assert_stored(@wrapper.cas("blah/toe") { "blah2" })
|
138
|
+
# assert_equal( "blah2", @wrapper.get("blah/toe"))
|
139
|
+
# end
|
140
|
+
#
|
141
|
+
# should "get multiple values" do
|
142
|
+
# assert_stored(@wrapper.add("blah/toe", "blah"))
|
143
|
+
# assert_stored(@wrapper.add("blah/finger", "blah2"))
|
144
|
+
# assert_equal( {'blah/toe'=>'blah','blah/finger'=>'blah2'}, @wrapper.get_multi(["blah/toe", "blah/finger"]))
|
145
|
+
# end
|
146
|
+
#
|
147
|
+
# should "set value" do
|
148
|
+
# assert_stored(@wrapper.set("blah/toe", "blah"))
|
149
|
+
# assert_equal( "blah", @wrapper.get("blah/toe"))
|
150
|
+
# end
|
151
|
+
#
|
152
|
+
# should "append value" do
|
153
|
+
# assert_not_stored( @wrapper.append("blah/toe", "blah"))
|
154
|
+
# assert_nil( @wrapper.get("blah/toe"))
|
155
|
+
#
|
156
|
+
# assert_stored( @wrapper.set("blah/toe", "blah", 0, true))
|
157
|
+
# assert_equal( "blah", @wrapper.get("blah/toe", true))
|
158
|
+
# assert_stored( @wrapper.append("blah/toe", "blah2"))
|
159
|
+
# assert_equal( "blahblah2", @wrapper.get("blah/toe", true))
|
160
|
+
# end
|
161
|
+
#
|
162
|
+
# should "prepend value" do
|
163
|
+
# assert_not_stored(@wrapper.prepend("blah/toe", "blah"))
|
164
|
+
# assert_nil( @wrapper.get("blah/toe"))
|
165
|
+
#
|
166
|
+
# assert_stored( @wrapper.set("blah/toe", "blah", 0, true))
|
167
|
+
# assert_stored( @wrapper.prepend("blah/toe", "blah2"))
|
168
|
+
# assert_equal( "blah2blah", @wrapper.get("blah/toe", true))
|
169
|
+
# end
|
170
|
+
#
|
171
|
+
# should "delete value" do
|
172
|
+
# assert_not_found( @wrapper.delete("blah/toe"))
|
173
|
+
# assert_stored( @wrapper.set("blah/toe", "blah"))
|
174
|
+
# assert_deleted( @wrapper.delete("blah/toe"))
|
175
|
+
# end
|
176
|
+
#
|
177
|
+
# should "increment value" do
|
178
|
+
# assert_nil( @wrapper.incr("blah/count"))
|
179
|
+
# assert_stored(@wrapper.set("blah/count", 0, 0, true))
|
180
|
+
# assert_equal( 1, @wrapper.incr("blah/count"))
|
181
|
+
# end
|
182
|
+
#
|
183
|
+
# should "decrement value" do
|
184
|
+
# assert_nil( @wrapper.decr("blah/count"))
|
185
|
+
# assert_stored(@wrapper.set("blah/count", 2, 0, true))
|
186
|
+
# assert_equal( 1, @wrapper.decr("blah/count"))
|
187
|
+
# end
|
188
|
+
#
|
189
|
+
# end
|
190
|
+
|
191
|
+
private
|
192
|
+
|
193
|
+
def assert_stored(val)
|
194
|
+
assert_equal("STORED\r\n", val)
|
195
|
+
end
|
196
|
+
|
197
|
+
def assert_deleted(val)
|
198
|
+
assert_equal("DELETED\r\n", val)
|
199
|
+
end
|
200
|
+
|
201
|
+
def assert_not_stored(val)
|
202
|
+
assert_equal("NOT_STORED\r\n", val)
|
203
|
+
end
|
204
|
+
|
205
|
+
def assert_not_found(val)
|
206
|
+
assert_equal("NOT_FOUND\r\n", val)
|
207
|
+
end
|
208
|
+
|
209
|
+
end
|
data/spec/spec_helper.rb
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
dir = File.dirname(__FILE__)
|
2
2
|
$LOAD_PATH.unshift "#{dir}/../lib"
|
3
3
|
|
4
|
-
require '
|
4
|
+
require File.join(dir, '../config/environment')
|
5
5
|
require 'spec'
|
6
6
|
require 'pp'
|
7
7
|
require 'cache_money'
|
@@ -9,8 +9,6 @@ require 'cache_money'
|
|
9
9
|
require 'memcached'
|
10
10
|
require 'memcached_wrapper'
|
11
11
|
|
12
|
-
require File.join(dir, '../config/environment')
|
13
|
-
|
14
12
|
Spec::Runner.configure do |config|
|
15
13
|
config.mock_with :rr
|
16
14
|
config.before :suite do
|
@@ -42,6 +40,11 @@ Spec::Runner.configure do |config|
|
|
42
40
|
index :published
|
43
41
|
end
|
44
42
|
|
43
|
+
Short = Class.new(Story)
|
44
|
+
Short.class_eval do
|
45
|
+
index :subtitle, :order_column => 'title'
|
46
|
+
end
|
47
|
+
|
45
48
|
Epic = Class.new(Story)
|
46
49
|
Oral = Class.new(Epic)
|
47
50
|
|
metadata
CHANGED
@@ -1,58 +1,79 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: ngmoco-cache-money
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
|
4
|
+
prerelease: false
|
5
|
+
segments:
|
6
|
+
- 0
|
7
|
+
- 2
|
8
|
+
- 13
|
9
|
+
version: 0.2.13
|
5
10
|
platform: ruby
|
6
11
|
authors:
|
7
12
|
- Nick Kallen
|
8
13
|
- Ashley Martens
|
14
|
+
- Scott Mace
|
15
|
+
- John Markos
|
9
16
|
autorequire:
|
10
17
|
bindir: bin
|
11
18
|
cert_chain: []
|
12
19
|
|
13
|
-
date: 2010-
|
20
|
+
date: 2010-08-05 00:00:00 -07:00
|
14
21
|
default_executable:
|
15
22
|
dependencies:
|
16
23
|
- !ruby/object:Gem::Dependency
|
17
|
-
|
18
|
-
type: :runtime
|
19
|
-
version_requirement:
|
20
|
-
version_requirements: !ruby/object:Gem::Requirement
|
24
|
+
requirement: &id001 !ruby/object:Gem::Requirement
|
21
25
|
requirements:
|
22
26
|
- - ">="
|
23
27
|
- !ruby/object:Gem::Version
|
28
|
+
segments:
|
29
|
+
- 2
|
30
|
+
- 2
|
31
|
+
- 0
|
24
32
|
version: 2.2.0
|
25
|
-
|
26
|
-
- !ruby/object:Gem::Dependency
|
27
|
-
name: activesupport
|
33
|
+
prerelease: false
|
28
34
|
type: :runtime
|
29
|
-
|
30
|
-
version_requirements:
|
35
|
+
name: activerecord
|
36
|
+
version_requirements: *id001
|
37
|
+
- !ruby/object:Gem::Dependency
|
38
|
+
requirement: &id002 !ruby/object:Gem::Requirement
|
31
39
|
requirements:
|
32
40
|
- - ">="
|
33
41
|
- !ruby/object:Gem::Version
|
42
|
+
segments:
|
43
|
+
- 2
|
44
|
+
- 2
|
45
|
+
- 0
|
34
46
|
version: 2.2.0
|
35
|
-
|
36
|
-
|
47
|
+
prerelease: false
|
48
|
+
type: :runtime
|
49
|
+
name: activesupport
|
50
|
+
version_requirements: *id002
|
51
|
+
description: Write-through and Read-through Cacheing for ActiveRecord
|
37
52
|
email: teamplatform@ngmoco.com
|
38
53
|
executables: []
|
39
54
|
|
40
55
|
extensions: []
|
41
56
|
|
42
|
-
extra_rdoc_files:
|
43
|
-
|
57
|
+
extra_rdoc_files:
|
58
|
+
- LICENSE
|
59
|
+
- README
|
60
|
+
- README.markdown
|
61
|
+
- TODO
|
44
62
|
files:
|
45
63
|
- README
|
46
64
|
- TODO
|
47
65
|
- UNSUPPORTED_FEATURES
|
66
|
+
- init.rb
|
67
|
+
- lib/cache_money.rb
|
48
68
|
- lib/cash/accessor.rb
|
49
69
|
- lib/cash/buffered.rb
|
50
70
|
- lib/cash/config.rb
|
71
|
+
- lib/cash/fake.rb
|
51
72
|
- lib/cash/finders.rb
|
52
73
|
- lib/cash/index.rb
|
53
74
|
- lib/cash/local.rb
|
54
75
|
- lib/cash/lock.rb
|
55
|
-
- lib/cash/
|
76
|
+
- lib/cash/mock.rb
|
56
77
|
- lib/cash/query/abstract.rb
|
57
78
|
- lib/cash/query/calculation.rb
|
58
79
|
- lib/cash/query/primary_key.rb
|
@@ -62,35 +83,39 @@ files:
|
|
62
83
|
- lib/cash/util/array.rb
|
63
84
|
- lib/cash/util/marshal.rb
|
64
85
|
- lib/cash/write_through.rb
|
65
|
-
- lib/
|
86
|
+
- lib/mem_cached_session_store.rb
|
87
|
+
- lib/mem_cached_support_store.rb
|
66
88
|
- lib/memcached_wrapper.rb
|
67
89
|
- rails/init.rb
|
68
|
-
-
|
90
|
+
- LICENSE
|
91
|
+
- README.markdown
|
69
92
|
has_rdoc: true
|
70
93
|
homepage: http://github.com/ngmoco/cache-money
|
71
94
|
licenses: []
|
72
95
|
|
73
96
|
post_install_message:
|
74
|
-
rdoc_options:
|
75
|
-
|
97
|
+
rdoc_options:
|
98
|
+
- --charset=UTF-8
|
76
99
|
require_paths:
|
77
100
|
- lib
|
78
101
|
required_ruby_version: !ruby/object:Gem::Requirement
|
79
102
|
requirements:
|
80
103
|
- - ">="
|
81
104
|
- !ruby/object:Gem::Version
|
105
|
+
segments:
|
106
|
+
- 0
|
82
107
|
version: "0"
|
83
|
-
version:
|
84
108
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
85
109
|
requirements:
|
86
110
|
- - ">="
|
87
111
|
- !ruby/object:Gem::Version
|
112
|
+
segments:
|
113
|
+
- 0
|
88
114
|
version: "0"
|
89
|
-
version:
|
90
115
|
requirements: []
|
91
116
|
|
92
117
|
rubyforge_project:
|
93
|
-
rubygems_version: 1.3.
|
118
|
+
rubygems_version: 1.3.6
|
94
119
|
signing_key:
|
95
120
|
specification_version: 3
|
96
121
|
summary: Write-through and Read-through Cacheing for ActiveRecord
|
@@ -100,12 +125,16 @@ test_files:
|
|
100
125
|
- db/schema.rb
|
101
126
|
- spec/cash/accessor_spec.rb
|
102
127
|
- spec/cash/active_record_spec.rb
|
128
|
+
- spec/cash/buffered_spec.rb
|
103
129
|
- spec/cash/calculations_spec.rb
|
104
130
|
- spec/cash/finders_spec.rb
|
131
|
+
- spec/cash/local_buffer_spec.rb
|
132
|
+
- spec/cash/local_spec.rb
|
105
133
|
- spec/cash/lock_spec.rb
|
134
|
+
- spec/cash/marshal_spec.rb
|
106
135
|
- spec/cash/order_spec.rb
|
107
136
|
- spec/cash/transactional_spec.rb
|
108
137
|
- spec/cash/window_spec.rb
|
109
138
|
- spec/cash/write_through_spec.rb
|
110
|
-
- spec/
|
139
|
+
- spec/memcached_wrapper_test.rb
|
111
140
|
- spec/spec_helper.rb
|