second_level_cache 2.3.2 → 2.3.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/Gemfile +1 -1
- data/lib/second_level_cache/active_record/finder_methods.rb +2 -2
- data/lib/second_level_cache/version.rb +1 -1
- data/second_level_cache.gemspec +2 -2
- data/test/model/user.rb +2 -2
- metadata +10 -10
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 1c4b3cf277afefb0bc9e4943fe03fbd45ad1c487
|
4
|
+
data.tar.gz: 6869caa60874ba8b133552c4a32db346e86bd0fa
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: e02c7b7980021f26efd958825dd3c69a06717f6a07c93e94ae812a7bf89383fe44482699e59c6fb78728cdeb935bba86b7e727a7a0142d83ad0ae17d51981f9a
|
7
|
+
data.tar.gz: 1d6f9f6f1f335f4ad5f3507491b15cf9034d9a74029a1c751bf792fe67b6c294a295ad221c6f909c8bac638599d0d717514d58297d1b4c0a4f5aeada4af3c418
|
data/Gemfile
CHANGED
@@ -19,7 +19,6 @@ module SecondLevelCache
|
|
19
19
|
return super(id) unless select_all_column?
|
20
20
|
|
21
21
|
id = id.id if ActiveRecord::Base == id
|
22
|
-
|
23
22
|
if cachable?
|
24
23
|
record = @klass.read_second_level_cache(id)
|
25
24
|
if record
|
@@ -61,12 +60,13 @@ module SecondLevelCache
|
|
61
60
|
|
62
61
|
private
|
63
62
|
|
63
|
+
# readonly_value - active_record/relation/query_methods.rb Rails 5.1 true/false
|
64
64
|
def cachable?
|
65
65
|
limit_one? &&
|
66
66
|
order_values.blank? &&
|
67
67
|
includes_values.blank? &&
|
68
68
|
preload_values.blank? &&
|
69
|
-
readonly_value.
|
69
|
+
readonly_value.blank? &&
|
70
70
|
joins_values.blank? &&
|
71
71
|
!@klass.locking_enabled? &&
|
72
72
|
where_clause_match_equality?
|
data/second_level_cache.gemspec
CHANGED
@@ -30,8 +30,8 @@ Gem::Specification.new do |gem|
|
|
30
30
|
gem.require_paths = ['lib']
|
31
31
|
gem.version = SecondLevelCache::VERSION
|
32
32
|
|
33
|
-
gem.add_runtime_dependency 'activesupport', ['>= 5.0.0
|
34
|
-
gem.add_runtime_dependency 'activerecord', ['>= 5.0.0
|
33
|
+
gem.add_runtime_dependency 'activesupport', ['>= 5.0.0', '< 5.2']
|
34
|
+
gem.add_runtime_dependency 'activerecord', ['>= 5.0.0', '< 5.2']
|
35
35
|
|
36
36
|
gem.add_development_dependency 'sqlite3'
|
37
37
|
gem.add_development_dependency 'rake'
|
data/test/model/user.rb
CHANGED
@@ -49,6 +49,6 @@ class Namespace < ActiveRecord::Base
|
|
49
49
|
end
|
50
50
|
|
51
51
|
class ForkedUserLink < ActiveRecord::Base
|
52
|
-
belongs_to :forked_from_user, class_name: User
|
53
|
-
belongs_to :forked_to_user, class_name: User
|
52
|
+
belongs_to :forked_from_user, class_name: 'User'
|
53
|
+
belongs_to :forked_to_user, class_name: 'User'
|
54
54
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: second_level_cache
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.3.
|
4
|
+
version: 2.3.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Hooopo
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2017-04-
|
11
|
+
date: 2017-04-28 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: activesupport
|
@@ -16,40 +16,40 @@ dependencies:
|
|
16
16
|
requirements:
|
17
17
|
- - ">="
|
18
18
|
- !ruby/object:Gem::Version
|
19
|
-
version: 5.0.0
|
19
|
+
version: 5.0.0
|
20
20
|
- - "<"
|
21
21
|
- !ruby/object:Gem::Version
|
22
|
-
version: 5.
|
22
|
+
version: '5.2'
|
23
23
|
type: :runtime
|
24
24
|
prerelease: false
|
25
25
|
version_requirements: !ruby/object:Gem::Requirement
|
26
26
|
requirements:
|
27
27
|
- - ">="
|
28
28
|
- !ruby/object:Gem::Version
|
29
|
-
version: 5.0.0
|
29
|
+
version: 5.0.0
|
30
30
|
- - "<"
|
31
31
|
- !ruby/object:Gem::Version
|
32
|
-
version: 5.
|
32
|
+
version: '5.2'
|
33
33
|
- !ruby/object:Gem::Dependency
|
34
34
|
name: activerecord
|
35
35
|
requirement: !ruby/object:Gem::Requirement
|
36
36
|
requirements:
|
37
37
|
- - ">="
|
38
38
|
- !ruby/object:Gem::Version
|
39
|
-
version: 5.0.0
|
39
|
+
version: 5.0.0
|
40
40
|
- - "<"
|
41
41
|
- !ruby/object:Gem::Version
|
42
|
-
version: 5.
|
42
|
+
version: '5.2'
|
43
43
|
type: :runtime
|
44
44
|
prerelease: false
|
45
45
|
version_requirements: !ruby/object:Gem::Requirement
|
46
46
|
requirements:
|
47
47
|
- - ">="
|
48
48
|
- !ruby/object:Gem::Version
|
49
|
-
version: 5.0.0
|
49
|
+
version: 5.0.0
|
50
50
|
- - "<"
|
51
51
|
- !ruby/object:Gem::Version
|
52
|
-
version: 5.
|
52
|
+
version: '5.2'
|
53
53
|
- !ruby/object:Gem::Dependency
|
54
54
|
name: sqlite3
|
55
55
|
requirement: !ruby/object:Gem::Requirement
|