redis-client 0.3.0 → 0.5.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (63) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +17 -0
  3. data/Gemfile +1 -2
  4. data/Gemfile.lock +1 -2
  5. data/README.md +13 -17
  6. data/Rakefile +41 -22
  7. data/lib/redis_client/command_builder.rb +8 -0
  8. data/lib/redis_client/config.rb +13 -5
  9. data/lib/redis_client/connection_mixin.rb +2 -0
  10. data/lib/redis_client/version.rb +1 -1
  11. data/lib/redis_client.rb +31 -15
  12. data/redis-client.gemspec +2 -4
  13. metadata +6 -56
  14. data/.rubocop.yml +0 -191
  15. data/ext/redis_client/hiredis/export.clang +0 -2
  16. data/ext/redis_client/hiredis/export.gcc +0 -7
  17. data/ext/redis_client/hiredis/extconf.rb +0 -69
  18. data/ext/redis_client/hiredis/hiredis_connection.c +0 -708
  19. data/ext/redis_client/hiredis/vendor/.gitignore +0 -9
  20. data/ext/redis_client/hiredis/vendor/.travis.yml +0 -131
  21. data/ext/redis_client/hiredis/vendor/CHANGELOG.md +0 -364
  22. data/ext/redis_client/hiredis/vendor/CMakeLists.txt +0 -165
  23. data/ext/redis_client/hiredis/vendor/COPYING +0 -29
  24. data/ext/redis_client/hiredis/vendor/Makefile +0 -308
  25. data/ext/redis_client/hiredis/vendor/README.md +0 -664
  26. data/ext/redis_client/hiredis/vendor/adapters/ae.h +0 -130
  27. data/ext/redis_client/hiredis/vendor/adapters/glib.h +0 -156
  28. data/ext/redis_client/hiredis/vendor/adapters/ivykis.h +0 -84
  29. data/ext/redis_client/hiredis/vendor/adapters/libev.h +0 -179
  30. data/ext/redis_client/hiredis/vendor/adapters/libevent.h +0 -175
  31. data/ext/redis_client/hiredis/vendor/adapters/libuv.h +0 -117
  32. data/ext/redis_client/hiredis/vendor/adapters/macosx.h +0 -115
  33. data/ext/redis_client/hiredis/vendor/adapters/qt.h +0 -135
  34. data/ext/redis_client/hiredis/vendor/alloc.c +0 -86
  35. data/ext/redis_client/hiredis/vendor/alloc.h +0 -91
  36. data/ext/redis_client/hiredis/vendor/appveyor.yml +0 -24
  37. data/ext/redis_client/hiredis/vendor/async.c +0 -887
  38. data/ext/redis_client/hiredis/vendor/async.h +0 -147
  39. data/ext/redis_client/hiredis/vendor/async_private.h +0 -75
  40. data/ext/redis_client/hiredis/vendor/dict.c +0 -352
  41. data/ext/redis_client/hiredis/vendor/dict.h +0 -126
  42. data/ext/redis_client/hiredis/vendor/fmacros.h +0 -12
  43. data/ext/redis_client/hiredis/vendor/hiredis-config.cmake.in +0 -13
  44. data/ext/redis_client/hiredis/vendor/hiredis.c +0 -1174
  45. data/ext/redis_client/hiredis/vendor/hiredis.h +0 -336
  46. data/ext/redis_client/hiredis/vendor/hiredis.pc.in +0 -12
  47. data/ext/redis_client/hiredis/vendor/hiredis_ssl-config.cmake.in +0 -13
  48. data/ext/redis_client/hiredis/vendor/hiredis_ssl.h +0 -157
  49. data/ext/redis_client/hiredis/vendor/hiredis_ssl.pc.in +0 -12
  50. data/ext/redis_client/hiredis/vendor/net.c +0 -612
  51. data/ext/redis_client/hiredis/vendor/net.h +0 -56
  52. data/ext/redis_client/hiredis/vendor/read.c +0 -739
  53. data/ext/redis_client/hiredis/vendor/read.h +0 -129
  54. data/ext/redis_client/hiredis/vendor/sds.c +0 -1289
  55. data/ext/redis_client/hiredis/vendor/sds.h +0 -278
  56. data/ext/redis_client/hiredis/vendor/sdsalloc.h +0 -44
  57. data/ext/redis_client/hiredis/vendor/sockcompat.c +0 -248
  58. data/ext/redis_client/hiredis/vendor/sockcompat.h +0 -92
  59. data/ext/redis_client/hiredis/vendor/ssl.c +0 -544
  60. data/ext/redis_client/hiredis/vendor/test.c +0 -1401
  61. data/ext/redis_client/hiredis/vendor/test.sh +0 -78
  62. data/ext/redis_client/hiredis/vendor/win32.h +0 -56
  63. data/lib/redis_client/hiredis_connection.rb +0 -93
data/.rubocop.yml DELETED
@@ -1,191 +0,0 @@
1
- AllCops:
2
- TargetRubyVersion: 2.5
3
- NewCops: enable
4
- SuggestExtensions: false
5
-
6
- Layout/LineLength:
7
- Max: 120
8
- Exclude:
9
- - 'test/**/*'
10
- - 'benchmark/**/*'
11
-
12
- Layout/CaseIndentation:
13
- EnforcedStyle: end
14
-
15
- Layout/LineEndStringConcatenationIndentation:
16
- EnforcedStyle: indented
17
-
18
- Layout/ArgumentAlignment:
19
- EnforcedStyle: with_fixed_indentation
20
-
21
- Lint/RescueException:
22
- Enabled: false
23
-
24
- Lint/SuppressedException:
25
- Enabled: false
26
-
27
- Lint/AssignmentInCondition:
28
- Enabled: false
29
-
30
- Lint/UnifiedInteger:
31
- Enabled: false
32
-
33
- Lint/UnderscorePrefixedVariableName:
34
- Enabled: false
35
-
36
- Lint/EmptyBlock:
37
- Enabled: false
38
-
39
- Lint/MissingSuper:
40
- Enabled: false
41
-
42
- Metrics/ClassLength:
43
- Enabled: false
44
-
45
- Metrics/CyclomaticComplexity:
46
- Enabled: false
47
-
48
- Metrics/AbcSize:
49
- Enabled: false
50
-
51
- Metrics/BlockLength:
52
- Enabled: false
53
-
54
- Metrics/MethodLength:
55
- Enabled: false
56
-
57
- Metrics/ModuleLength:
58
- Enabled: false
59
-
60
- Metrics/ParameterLists:
61
- Enabled: false
62
-
63
- Metrics/PerceivedComplexity:
64
- Enabled: false
65
-
66
- Style/Alias:
67
- EnforcedStyle: prefer_alias_method
68
-
69
- Style/PercentLiteralDelimiters:
70
- Enabled: false
71
-
72
- Style/ParallelAssignment:
73
- Enabled: false
74
-
75
- Style/NumericPredicate:
76
- Enabled: false
77
-
78
- Style/NumericLiterals:
79
- Enabled: false
80
-
81
- Style/IfUnlessModifier:
82
- Enabled: false
83
-
84
- Style/SignalException:
85
- Exclude:
86
- - 'lib/redis/connection/synchrony.rb'
87
-
88
- Style/StringLiterals:
89
- Enabled: false
90
-
91
- Style/DoubleNegation:
92
- Enabled: false
93
-
94
- Style/MultipleComparison:
95
- Enabled: false
96
-
97
- Style/GuardClause:
98
- Enabled: false
99
-
100
- Style/Semicolon:
101
- Enabled: false
102
-
103
- Style/Documentation:
104
- Enabled: false
105
-
106
- Style/FormatStringToken:
107
- Enabled: false
108
-
109
- Style/FormatString:
110
- Enabled: false
111
-
112
- Style/RescueStandardError:
113
- Enabled: false
114
-
115
- Style/WordArray:
116
- Enabled: false
117
-
118
- Style/TrailingCommaInArrayLiteral:
119
- EnforcedStyleForMultiline: consistent_comma
120
-
121
- Style/TrailingCommaInHashLiteral:
122
- EnforcedStyleForMultiline: consistent_comma
123
-
124
- Style/TrailingCommaInArguments:
125
- EnforcedStyleForMultiline: consistent_comma
126
-
127
- Lint/NonLocalExitFromIterator:
128
- Enabled: false
129
-
130
- Layout/FirstArrayElementIndentation:
131
- EnforcedStyle: consistent
132
-
133
- Layout/FirstHashElementIndentation:
134
- EnforcedStyle: consistent
135
-
136
- Layout/EndAlignment:
137
- EnforcedStyleAlignWith: variable
138
-
139
- Layout/ElseAlignment:
140
- Enabled: false
141
-
142
- Layout/RescueEnsureAlignment:
143
- Enabled: false
144
-
145
- Naming/HeredocDelimiterNaming:
146
- Enabled: false
147
-
148
- Naming/FileName:
149
- Enabled: false
150
-
151
- Naming/RescuedExceptionsVariableName:
152
- Enabled: false
153
-
154
- Naming/AccessorMethodName:
155
- Exclude:
156
- - lib/redis/connection/ruby.rb
157
-
158
- Naming/MethodParameterName:
159
- Enabled: false
160
-
161
- Metrics/BlockNesting:
162
- Enabled: false
163
-
164
- Style/HashTransformValues:
165
- Enabled: false
166
-
167
- Style/SymbolProc:
168
- Exclude:
169
- - 'test/**/*'
170
-
171
- Style/SoleNestedConditional:
172
- Enabled: false
173
-
174
- Style/GlobalVars:
175
- Exclude:
176
- - 'ext/**/*'
177
-
178
- Gemspec/RequireMFA:
179
- Enabled: false
180
-
181
- Style/StderrPuts:
182
- Enabled: false
183
-
184
- Style/ModuleFunction:
185
- Enabled: false
186
-
187
- Style/CombinableLoops:
188
- Enabled: false
189
-
190
- Style/DocumentDynamicEvalDefinition:
191
- Enabled: false
@@ -1,2 +0,0 @@
1
- _Init_hiredis_connection
2
- _ruby_abi_version
@@ -1,7 +0,0 @@
1
- hiredis_connection_1.0 {
2
- global:
3
- Init_hiredis_connection;
4
- ruby_abi_version;
5
- local:
6
- *;
7
- };
@@ -1,69 +0,0 @@
1
- # frozen_string_literal: true
2
-
3
- require "mkmf"
4
-
5
- if RUBY_ENGINE == "ruby" && !RUBY_ENGINE.match?(/mswin/)
6
- have_func("rb_hash_new_capa", "ruby.h")
7
-
8
- hiredis_dir = File.expand_path('vendor', __dir__)
9
-
10
- make_program = with_config("make-prog", ENV["MAKE"])
11
- make_program ||= case RUBY_PLATFORM
12
- when /(bsd|solaris)/
13
- 'gmake'
14
- else
15
- 'make'
16
- end
17
-
18
- openssl_include, openssl_lib = dir_config("openssl")
19
-
20
- openssl_include ||= dir_config("opt").first
21
- &.split(File::PATH_SEPARATOR)
22
- &.detect { |dir| dir.include?("openssl") }
23
-
24
- openssl_lib ||= dir_config("opt").last
25
- &.split(File::PATH_SEPARATOR)
26
- &.detect { |dir| dir.include?("openssl") }
27
-
28
- if (!openssl_include || !openssl_lib) && !have_header("openssl/ssl.h")
29
- raise "OpenSSL library could not be found. You might want to use --with-openssl-dir=<dir> option to specify the " \
30
- "prefix where OpenSSL is installed."
31
- end
32
-
33
- Dir.chdir(hiredis_dir) do
34
- flags = ["static", "USE_SSL=1"]
35
- if openssl_lib
36
- flags << %(CFLAGS="-I#{openssl_include}") << %(SSL_LDFLAGS="-L#{openssl_lib}")
37
- end
38
-
39
- flags << "OPTIMIZATION=-g" if ENV["EXT_PEDANTIC"]
40
-
41
- unless system(make_program, *flags)
42
- raise "Building hiredis failed"
43
- end
44
- end
45
-
46
- $CFLAGS << " -I#{hiredis_dir}"
47
- $LDFLAGS << " -lssl -lcrypto"
48
- $libs << " #{hiredis_dir}/libhiredis.a #{hiredis_dir}/libhiredis_ssl.a "
49
- $CFLAGS << " -std=c99 "
50
- if ENV["EXT_PEDANTIC"]
51
- $CFLAGS << " -Werror"
52
- $CFLAGS << " -g "
53
- else
54
- $CFLAGS << " -O3 "
55
- end
56
-
57
- if `cc --version`.match?(/ clang /i) || RbConfig::CONFIG['CC'].match?(/clang/i)
58
- $LDFLAGS << ' -Wl,-exported_symbols_list,"' << File.join(__dir__, 'export.clang') << '"'
59
- elsif RbConfig::CONFIG['CC'].match?(/gcc/i)
60
- $LDFLAGS << ' -Wl,--version-script="' << File.join(__dir__, 'export.gcc') << '"'
61
- end
62
-
63
- $CFLAGS << " -Wno-declaration-after-statement" # Older compilers
64
- $CFLAGS << " -Wno-compound-token-split-by-macro" # Older rubies on macos
65
-
66
- create_makefile("redis_client/hiredis_connection")
67
- else
68
- File.write("Makefile", dummy_makefile($srcdir).join)
69
- end