me-redis 0.1.2 → 0.1.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +7 -3
- data/lib/me_redis/aws_config_blocker.rb +16 -19
- data/lib/me_redis/version.rb +1 -1
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 3a65c3be77f851506ff1fe5e6710e3527bf3c54ecfed4779c46c07807db51467
|
4
|
+
data.tar.gz: 6d5c7c61bb15c9aa82beb4b82850ba17ba8dfc6c8b326d10a66e2f5d99522432
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: b60ea826f7877551700abdb66971bb284ec7a77a000e60424726a23b75e8d43042f7c3165684a937a5cc09a4614f067bc15b0bd32c3f564dd9f41f59f8d7c342
|
7
|
+
data.tar.gz: 58df460a2267047e2f264f5bb58e28e70b4b27e840ac404f2c88dacefa155ac88258ed7af3ad6091290bfaaa1d88a79a3f13ac8c3b1e69c6eb5717ba4196bfe8
|
data/README.md
CHANGED
@@ -100,9 +100,11 @@ AWS blocks config call with exception. To prevent this behaviour prepend MeRedis
|
|
100
100
|
with AwsConfigBlocker module:
|
101
101
|
|
102
102
|
```ruby
|
103
|
+
|
104
|
+
# !!! it should be prepended before including main module.
|
103
105
|
Class.new(Redis)
|
106
|
+
.prepend(MeRedis::AwsConfigBlocker)
|
104
107
|
.include(MeRedis)
|
105
|
-
.prepend( MeRedis::AwsConfigBlocker )
|
106
108
|
.configure({
|
107
109
|
# some config
|
108
110
|
}).new
|
@@ -158,10 +160,10 @@ The idea is to move complexity to config.
|
|
158
160
|
#Options are:
|
159
161
|
|
160
162
|
# if set - configures Redis hash_max_ziplist_entries value,
|
161
|
-
# otherwise it will be filled from Redis hash-max-ziplist-
|
163
|
+
# otherwise it will be filled from Redis hash-max-ziplist-entries
|
162
164
|
:hash_max_ziplist_entries
|
163
165
|
|
164
|
-
# if set - configures Redis
|
166
|
+
# if set - configures Redis hash-max-ziplist-value value,
|
165
167
|
# otherwise it will be filled from Redis hash-max-ziplist-value
|
166
168
|
:hash_max_ziplist_value
|
167
169
|
|
@@ -466,6 +468,8 @@ The gem is available as open source under the terms of the [MIT License](http://
|
|
466
468
|
|
467
469
|
## ToDo List
|
468
470
|
|
471
|
+
* Place config for keys zipping in text form into predefined key, so it would be observable with just redis-cli
|
469
472
|
* add warning option for hash-max-ziplist-value overthrowing
|
470
473
|
* add keys method
|
471
474
|
* refactor readme
|
475
|
+
*
|
@@ -5,26 +5,23 @@ module MeRedis
|
|
5
5
|
module AwsConfigBlocker
|
6
6
|
|
7
7
|
def config( *args, &block )
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
because AWS does not support config get/set calls by throwing an exception.
|
13
|
-
AwsConfigBlocker will block config call from reaching your Redis server!
|
8
|
+
print 'config was called, resulting me_config:'
|
9
|
+
ap self.class.me_config
|
10
|
+
{}
|
11
|
+
end
|
14
12
|
|
15
|
-
|
13
|
+
def self.prepended(base)
|
14
|
+
print <<AWS_MSG
|
15
|
+
|
16
|
+
\e[0;33;31;1m!!!!!!!!! MeRedis AWS CONFIG BLOCKER WARNING!!!!!! \e[0;33;31;0m
|
17
|
+
You introduced AwsConfigBlocker into the ancestors chain, that means that you intend to skip Redis config call,
|
18
|
+
because AWS does not support config get/set calls by throwing an exception.
|
19
|
+
AwsConfigBlocker will block config call from reaching your Redis server!
|
20
|
+
|
21
|
+
Don't forget to setup redis param group through the AWS UI with exact values, or you might face unexpected
|
22
|
+
optimization degradation. For more details look into the README section.
|
16
23
|
|
17
24
|
AWS_MSG
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
print <<END_MSG
|
22
|
-
|
23
|
-
|
24
|
-
Don't forget to setup redis param group with exact values, or you might face unexpected optimization degradation.
|
25
|
-
You can find more details in the README section.
|
26
|
-
END_MSG
|
27
|
-
{}
|
28
|
-
end
|
29
|
-
end
|
25
|
+
end
|
26
|
+
end
|
30
27
|
end
|
data/lib/me_redis/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: me-redis
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- alekseyl
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2019-06-
|
11
|
+
date: 2019-06-30 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: redis
|
@@ -158,7 +158,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
158
158
|
version: '0'
|
159
159
|
requirements: []
|
160
160
|
rubyforge_project:
|
161
|
-
rubygems_version: 2.7.
|
161
|
+
rubygems_version: 2.7.6
|
162
162
|
signing_key:
|
163
163
|
specification_version: 4
|
164
164
|
summary: Memory efficient redis extention
|