redis 3.0.0 → 4.2.2

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.
Files changed (106) hide show
  1. checksums.yaml +7 -0
  2. data/CHANGELOG.md +269 -0
  3. data/README.md +295 -58
  4. data/lib/redis.rb +1760 -451
  5. data/lib/redis/client.rb +355 -88
  6. data/lib/redis/cluster.rb +295 -0
  7. data/lib/redis/cluster/command.rb +81 -0
  8. data/lib/redis/cluster/command_loader.rb +34 -0
  9. data/lib/redis/cluster/key_slot_converter.rb +72 -0
  10. data/lib/redis/cluster/node.rb +107 -0
  11. data/lib/redis/cluster/node_key.rb +31 -0
  12. data/lib/redis/cluster/node_loader.rb +37 -0
  13. data/lib/redis/cluster/option.rb +90 -0
  14. data/lib/redis/cluster/slot.rb +86 -0
  15. data/lib/redis/cluster/slot_loader.rb +49 -0
  16. data/lib/redis/connection.rb +4 -2
  17. data/lib/redis/connection/command_helper.rb +5 -10
  18. data/lib/redis/connection/hiredis.rb +12 -8
  19. data/lib/redis/connection/registry.rb +2 -1
  20. data/lib/redis/connection/ruby.rb +232 -63
  21. data/lib/redis/connection/synchrony.rb +41 -14
  22. data/lib/redis/distributed.rb +205 -70
  23. data/lib/redis/errors.rb +48 -0
  24. data/lib/redis/hash_ring.rb +31 -73
  25. data/lib/redis/pipeline.rb +74 -18
  26. data/lib/redis/subscribe.rb +24 -13
  27. data/lib/redis/version.rb +3 -1
  28. metadata +63 -160
  29. data/.gitignore +0 -10
  30. data/.order +0 -169
  31. data/.travis.yml +0 -50
  32. data/.travis/Gemfile +0 -11
  33. data/.yardopts +0 -3
  34. data/Rakefile +0 -392
  35. data/benchmarking/logging.rb +0 -62
  36. data/benchmarking/pipeline.rb +0 -51
  37. data/benchmarking/speed.rb +0 -21
  38. data/benchmarking/suite.rb +0 -24
  39. data/benchmarking/worker.rb +0 -71
  40. data/examples/basic.rb +0 -15
  41. data/examples/dist_redis.rb +0 -43
  42. data/examples/incr-decr.rb +0 -17
  43. data/examples/list.rb +0 -26
  44. data/examples/pubsub.rb +0 -31
  45. data/examples/sets.rb +0 -36
  46. data/examples/unicorn/config.ru +0 -3
  47. data/examples/unicorn/unicorn.rb +0 -20
  48. data/redis.gemspec +0 -41
  49. data/test/blocking_commands_test.rb +0 -42
  50. data/test/command_map_test.rb +0 -30
  51. data/test/commands_on_hashes_test.rb +0 -21
  52. data/test/commands_on_lists_test.rb +0 -20
  53. data/test/commands_on_sets_test.rb +0 -77
  54. data/test/commands_on_sorted_sets_test.rb +0 -109
  55. data/test/commands_on_strings_test.rb +0 -83
  56. data/test/commands_on_value_types_test.rb +0 -99
  57. data/test/connection_handling_test.rb +0 -189
  58. data/test/db/.gitignore +0 -1
  59. data/test/distributed_blocking_commands_test.rb +0 -46
  60. data/test/distributed_commands_on_hashes_test.rb +0 -10
  61. data/test/distributed_commands_on_lists_test.rb +0 -22
  62. data/test/distributed_commands_on_sets_test.rb +0 -83
  63. data/test/distributed_commands_on_sorted_sets_test.rb +0 -18
  64. data/test/distributed_commands_on_strings_test.rb +0 -48
  65. data/test/distributed_commands_on_value_types_test.rb +0 -87
  66. data/test/distributed_commands_requiring_clustering_test.rb +0 -148
  67. data/test/distributed_connection_handling_test.rb +0 -23
  68. data/test/distributed_internals_test.rb +0 -15
  69. data/test/distributed_key_tags_test.rb +0 -52
  70. data/test/distributed_persistence_control_commands_test.rb +0 -26
  71. data/test/distributed_publish_subscribe_test.rb +0 -92
  72. data/test/distributed_remote_server_control_commands_test.rb +0 -53
  73. data/test/distributed_scripting_test.rb +0 -102
  74. data/test/distributed_sorting_test.rb +0 -20
  75. data/test/distributed_test.rb +0 -58
  76. data/test/distributed_transactions_test.rb +0 -32
  77. data/test/encoding_test.rb +0 -18
  78. data/test/error_replies_test.rb +0 -59
  79. data/test/helper.rb +0 -188
  80. data/test/helper_test.rb +0 -22
  81. data/test/internals_test.rb +0 -214
  82. data/test/lint/blocking_commands.rb +0 -124
  83. data/test/lint/hashes.rb +0 -162
  84. data/test/lint/lists.rb +0 -143
  85. data/test/lint/sets.rb +0 -96
  86. data/test/lint/sorted_sets.rb +0 -201
  87. data/test/lint/strings.rb +0 -157
  88. data/test/lint/value_types.rb +0 -106
  89. data/test/persistence_control_commands_test.rb +0 -26
  90. data/test/pipelining_commands_test.rb +0 -195
  91. data/test/publish_subscribe_test.rb +0 -153
  92. data/test/remote_server_control_commands_test.rb +0 -104
  93. data/test/scripting_test.rb +0 -78
  94. data/test/sorting_test.rb +0 -45
  95. data/test/support/connection/hiredis.rb +0 -1
  96. data/test/support/connection/ruby.rb +0 -1
  97. data/test/support/connection/synchrony.rb +0 -17
  98. data/test/support/redis_mock.rb +0 -92
  99. data/test/support/wire/synchrony.rb +0 -24
  100. data/test/support/wire/thread.rb +0 -5
  101. data/test/synchrony_driver.rb +0 -57
  102. data/test/test.conf +0 -9
  103. data/test/thread_safety_test.rb +0 -32
  104. data/test/transactions_test.rb +0 -244
  105. data/test/unknown_commands_test.rb +0 -14
  106. data/test/url_param_test.rb +0 -64
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  class Redis
2
4
  # Base error for all redis-rb errors.
3
5
  class BaseError < RuntimeError
@@ -37,4 +39,50 @@ class Redis
37
39
  # Raised when the connection was inherited by a child process.
38
40
  class InheritedError < BaseConnectionError
39
41
  end
42
+
43
+ # Raised when client options are invalid.
44
+ class InvalidClientOptionError < BaseError
45
+ end
46
+
47
+ class Cluster
48
+ # Raised when client connected to redis as cluster mode
49
+ # and some cluster subcommands were called.
50
+ class OrchestrationCommandNotSupported < BaseError
51
+ def initialize(command, subcommand = '')
52
+ str = [command, subcommand].map(&:to_s).reject(&:empty?).join(' ').upcase
53
+ msg = "#{str} command should be used with care "\
54
+ 'only by applications orchestrating Redis Cluster, like redis-trib, '\
55
+ 'and the command if used out of the right context can leave the cluster '\
56
+ 'in a wrong state or cause data loss.'
57
+ super(msg)
58
+ end
59
+ end
60
+
61
+ # Raised when error occurs on any node of cluster.
62
+ class CommandErrorCollection < BaseError
63
+ attr_reader :errors
64
+
65
+ # @param errors [Hash{String => Redis::CommandError}]
66
+ # @param error_message [String]
67
+ def initialize(errors, error_message = 'Command errors were replied on any node')
68
+ @errors = errors
69
+ super(error_message)
70
+ end
71
+ end
72
+
73
+ # Raised when cluster client can't select node.
74
+ class AmbiguousNodeError < BaseError
75
+ def initialize(command)
76
+ super("Cluster client doesn't know which node the #{command} command should be sent to.")
77
+ end
78
+ end
79
+
80
+ # Raised when commands in pipelining include cross slot keys.
81
+ class CrossSlotPipeliningError < BaseError
82
+ def initialize(keys)
83
+ super("Cluster client couldn't send pipelining to single node. "\
84
+ "The commands include cross slot keys. #{keys}")
85
+ end
86
+ end
87
+ end
40
88
  end
@@ -1,8 +1,9 @@
1
+ # frozen_string_literal: true
2
+
1
3
  require 'zlib'
2
4
 
3
5
  class Redis
4
6
  class HashRing
5
-
6
7
  POINTS_PER_SERVER = 160 # this is the default in libmemcached
7
8
 
8
9
  attr_reader :ring, :sorted_keys, :replicas, :nodes
@@ -10,7 +11,7 @@ class Redis
10
11
  # nodes is a list of objects that have a proper to_s representation.
11
12
  # replicas indicates how many virtual points should be used pr. node,
12
13
  # replicas are required to improve the distribution.
13
- def initialize(nodes=[], replicas=POINTS_PER_SERVER)
14
+ def initialize(nodes = [], replicas = POINTS_PER_SERVER)
14
15
  @replicas = replicas
15
16
  @ring = {}
16
17
  @nodes = []
@@ -32,11 +33,11 @@ class Redis
32
33
  end
33
34
 
34
35
  def remove_node(node)
35
- @nodes.reject!{|n| n.id == node.id}
36
+ @nodes.reject! { |n| n.id == node.id }
36
37
  @replicas.times do |i|
37
38
  key = Zlib.crc32("#{node.id}:#{i}")
38
39
  @ring.delete(key)
39
- @sorted_keys.reject! {|k| k == key}
40
+ @sorted_keys.reject! { |k| k == key }
40
41
  end
41
42
  end
42
43
 
@@ -46,86 +47,43 @@ class Redis
46
47
  end
47
48
 
48
49
  def get_node_pos(key)
49
- return [nil,nil] if @ring.size == 0
50
+ return [nil, nil] if @ring.empty?
51
+
50
52
  crc = Zlib.crc32(key)
51
53
  idx = HashRing.binary_search(@sorted_keys, crc)
52
- return [@ring[@sorted_keys[idx]], idx]
54
+ [@ring[@sorted_keys[idx]], idx]
53
55
  end
54
56
 
55
57
  def iter_nodes(key)
56
- return [nil,nil] if @ring.size == 0
58
+ return [nil, nil] if @ring.empty?
59
+
57
60
  _, pos = get_node_pos(key)
58
- @sorted_keys[pos..-1].each do |k|
59
- yield @ring[k]
61
+ @ring.size.times do |n|
62
+ yield @ring[@sorted_keys[(pos + n) % @ring.size]]
60
63
  end
61
64
  end
62
65
 
63
- class << self
64
-
65
- # gem install RubyInline to use this code
66
- # Native extension to perform the binary search within the hashring.
67
- # There's a pure ruby version below so this is purely optional
68
- # for performance. In testing 20k gets and sets, the native
69
- # binary search shaved about 12% off the runtime (9sec -> 8sec).
70
- begin
71
- require 'inline'
72
- inline do |builder|
73
- builder.c <<-EOM
74
- int binary_search(VALUE ary, unsigned int r) {
75
- int upper = RARRAY_LEN(ary) - 1;
76
- int lower = 0;
77
- int idx = 0;
78
-
79
- while (lower <= upper) {
80
- idx = (lower + upper) / 2;
81
-
82
- VALUE continuumValue = RARRAY_PTR(ary)[idx];
83
- unsigned int l = NUM2UINT(continuumValue);
84
- if (l == r) {
85
- return idx;
86
- }
87
- else if (l > r) {
88
- upper = idx - 1;
89
- }
90
- else {
91
- lower = idx + 1;
92
- }
93
- }
94
- if (upper < 0) {
95
- upper = RARRAY_LEN(ary) - 1;
96
- }
97
- return upper;
98
- }
99
- EOM
66
+ # Find the closest index in HashRing with value <= the given value
67
+ def self.binary_search(ary, value)
68
+ upper = ary.size - 1
69
+ lower = 0
70
+ idx = 0
71
+
72
+ while lower <= upper
73
+ idx = (lower + upper) / 2
74
+ comp = ary[idx] <=> value
75
+
76
+ if comp == 0
77
+ return idx
78
+ elsif comp > 0
79
+ upper = idx - 1
80
+ else
81
+ lower = idx + 1
100
82
  end
101
- rescue Exception
102
- # Find the closest index in HashRing with value <= the given value
103
- def binary_search(ary, value, &block)
104
- upper = ary.size - 1
105
- lower = 0
106
- idx = 0
107
-
108
- while(lower <= upper) do
109
- idx = (lower + upper) / 2
110
- comp = ary[idx] <=> value
111
-
112
- if comp == 0
113
- return idx
114
- elsif comp > 0
115
- upper = idx - 1
116
- else
117
- lower = idx + 1
118
- end
119
- end
120
-
121
- if upper < 0
122
- upper = ary.size - 1
123
- end
124
- return upper
125
- end
126
-
127
83
  end
128
- end
129
84
 
85
+ upper = ary.size - 1 if upper < 0
86
+ upper
87
+ end
130
88
  end
131
89
  end
@@ -1,19 +1,23 @@
1
- class Redis
2
- unless defined?(::BasicObject)
3
- class BasicObject
4
- instance_methods.each { |meth| undef_method(meth) unless meth =~ /\A(__|instance_eval)/ }
5
- end
6
- end
1
+ # frozen_string_literal: true
7
2
 
3
+ class Redis
8
4
  class Pipeline
5
+ attr_accessor :db
6
+ attr_reader :client
7
+
9
8
  attr :futures
10
9
 
11
- def initialize
10
+ def initialize(client)
11
+ @client = client.is_a?(Pipeline) ? client.client : client
12
12
  @with_reconnect = true
13
13
  @shutdown = false
14
14
  @futures = []
15
15
  end
16
16
 
17
+ def timeout
18
+ client.timeout
19
+ end
20
+
17
21
  def with_reconnect?
18
22
  @with_reconnect
19
23
  end
@@ -26,26 +30,39 @@ class Redis
26
30
  @shutdown
27
31
  end
28
32
 
29
- def call(command, &block)
33
+ def empty?
34
+ @futures.empty?
35
+ end
36
+
37
+ def call(command, timeout: nil, &block)
30
38
  # A pipeline that contains a shutdown should not raise ECONNRESET when
31
39
  # the connection is gone.
32
40
  @shutdown = true if command.first == :shutdown
33
- future = Future.new(command, block)
41
+ future = Future.new(command, block, timeout)
34
42
  @futures << future
35
43
  future
36
44
  end
37
45
 
46
+ def call_with_timeout(command, timeout, &block)
47
+ call(command, timeout: timeout, &block)
48
+ end
49
+
38
50
  def call_pipeline(pipeline)
39
51
  @shutdown = true if pipeline.shutdown?
40
52
  @futures.concat(pipeline.futures)
53
+ @db = pipeline.db
41
54
  nil
42
55
  end
43
56
 
44
57
  def commands
45
- @futures.map { |f| f._command }
58
+ @futures.map(&:_command)
46
59
  end
47
60
 
48
- def with_reconnect(val=true)
61
+ def timeouts
62
+ @futures.map(&:timeout)
63
+ end
64
+
65
+ def with_reconnect(val = true)
49
66
  @with_reconnect = false unless val
50
67
  yield
51
68
  end
@@ -68,14 +85,20 @@ class Redis
68
85
 
69
86
  class Multi < self
70
87
  def finish(replies)
71
- return if replies.last.nil? # The transaction failed because of WATCH.
88
+ exec = replies.last
89
+
90
+ return if exec.nil? # The transaction failed because of WATCH.
72
91
 
73
- if replies.last.size < futures.size - 2
92
+ # EXEC command failed.
93
+ raise exec if exec.is_a?(CommandError)
94
+
95
+ if exec.size < futures.size
74
96
  # Some command wasn't recognized by Redis.
75
- raise replies.detect { |r| r.kind_of?(::RuntimeError) }
97
+ command_error = replies.detect { |r| r.is_a?(CommandError) }
98
+ raise command_error
76
99
  end
77
100
 
78
- super(replies.last) do |reply|
101
+ super(exec) do |reply|
79
102
  # Because an EXEC returns nested replies, hiredis won't be able to
80
103
  # convert an error reply to a CommandError instance itself. This is
81
104
  # specific to MULTI/EXEC, so we solve this here.
@@ -83,8 +106,20 @@ class Redis
83
106
  end
84
107
  end
85
108
 
109
+ def timeouts
110
+ if empty?
111
+ []
112
+ else
113
+ [nil, *super, nil]
114
+ end
115
+ end
116
+
86
117
  def commands
87
- [[:multi]] + super + [[:exec]]
118
+ if empty?
119
+ []
120
+ else
121
+ [[:multi]] + super + [[:exec]]
122
+ end
88
123
  end
89
124
  end
90
125
  end
@@ -98,12 +133,25 @@ class Redis
98
133
  class Future < BasicObject
99
134
  FutureNotReady = ::Redis::FutureNotReady.new
100
135
 
101
- def initialize(command, transformation)
136
+ attr_reader :timeout
137
+
138
+ def initialize(command, transformation, timeout)
102
139
  @command = command
103
140
  @transformation = transformation
141
+ @timeout = timeout
104
142
  @object = FutureNotReady
105
143
  end
106
144
 
145
+ def ==(_other)
146
+ message = +"The methods == and != are deprecated for Redis::Future and will be removed in 4.2.0"
147
+ message << " - You probably meant to call .value == or .value !="
148
+ message << " (#{::Kernel.caller(1, 1).first})\n"
149
+
150
+ ::Kernel.warn(message)
151
+
152
+ super
153
+ end
154
+
107
155
  def inspect
108
156
  "<Redis::Future #{@command.inspect}>"
109
157
  end
@@ -118,8 +166,16 @@ class Redis
118
166
  end
119
167
 
120
168
  def value
121
- ::Kernel.raise(@object) if @object.kind_of?(::RuntimeError)
169
+ ::Kernel.raise(@object) if @object.is_a?(::RuntimeError)
122
170
  @object
123
171
  end
172
+
173
+ def is_a?(other)
174
+ self.class.ancestors.include?(other)
175
+ end
176
+
177
+ def class
178
+ Future
179
+ end
124
180
  end
125
181
  end
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  class Redis
2
4
  class SubscribedClient
3
5
  def initialize(client)
@@ -12,32 +14,41 @@ class Redis
12
14
  subscription("subscribe", "unsubscribe", channels, block)
13
15
  end
14
16
 
17
+ def subscribe_with_timeout(timeout, *channels, &block)
18
+ subscription("subscribe", "unsubscribe", channels, block, timeout)
19
+ end
20
+
15
21
  def psubscribe(*channels, &block)
16
22
  subscription("psubscribe", "punsubscribe", channels, block)
17
23
  end
18
24
 
25
+ def psubscribe_with_timeout(timeout, *channels, &block)
26
+ subscription("psubscribe", "punsubscribe", channels, block, timeout)
27
+ end
28
+
19
29
  def unsubscribe(*channels)
20
- call [:unsubscribe, *channels]
30
+ call([:unsubscribe, *channels])
21
31
  end
22
32
 
23
33
  def punsubscribe(*channels)
24
- call [:punsubscribe, *channels]
34
+ call([:punsubscribe, *channels])
25
35
  end
26
36
 
27
- protected
37
+ protected
28
38
 
29
- def subscription(start, stop, channels, block)
39
+ def subscription(start, stop, channels, block, timeout = 0)
30
40
  sub = Subscription.new(&block)
31
41
 
32
- begin
33
- @client.call_loop([start, *channels]) do |line|
34
- type, *rest = line
35
- sub.callbacks[type].call(*rest)
36
- break if type == stop && rest.last == 0
37
- end
38
- ensure
39
- send(stop)
42
+ unsubscribed = false
43
+
44
+ @client.call_loop([start, *channels], timeout) do |line|
45
+ type, *rest = line
46
+ sub.callbacks[type].call(*rest)
47
+ unsubscribed = type == stop && rest.last == 0
48
+ break if unsubscribed
40
49
  end
50
+ # No need to unsubscribe here. The real client closes the connection
51
+ # whenever an exception is raised (see #ensure_connected).
41
52
  end
42
53
  end
43
54
 
@@ -46,7 +57,7 @@ class Redis
46
57
 
47
58
  def initialize
48
59
  @callbacks = Hash.new do |hash, key|
49
- hash[key] = lambda { |*_| }
60
+ hash[key] = ->(*_) {}
50
61
  end
51
62
 
52
63
  yield(self)
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  class Redis
2
- VERSION = "3.0.0"
4
+ VERSION = '4.2.2'
3
5
  end
metadata CHANGED
@@ -1,8 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: redis
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.0.0
5
- prerelease:
4
+ version: 4.2.2
6
5
  platform: ruby
7
6
  authors:
8
7
  - Ezra Zygmuntowicz
@@ -14,60 +13,77 @@ authors:
14
13
  - Michel Martens
15
14
  - Damian Janowski
16
15
  - Pieter Noordhuis
17
- autorequire:
16
+ autorequire:
18
17
  bindir: bin
19
18
  cert_chain: []
20
- date: 2012-05-23 00:00:00.000000000 Z
19
+ date: 2020-09-07 00:00:00.000000000 Z
21
20
  dependencies:
22
21
  - !ruby/object:Gem::Dependency
23
- name: rake
22
+ name: em-synchrony
24
23
  requirement: !ruby/object:Gem::Requirement
25
- none: false
26
24
  requirements:
27
- - - ! '>='
25
+ - - ">="
28
26
  - !ruby/object:Gem::Version
29
27
  version: '0'
30
28
  type: :development
31
29
  prerelease: false
32
30
  version_requirements: !ruby/object:Gem::Requirement
33
- none: false
34
31
  requirements:
35
- - - ! '>='
32
+ - - ">="
36
33
  - !ruby/object:Gem::Version
37
34
  version: '0'
38
- description: ! " A Ruby client that tries to match Redis' API one-to-one, while
39
- still\n providing an idiomatic interface. It features thread-safety,\n client-side
40
- sharding, pipelining, and an obsession for performance.\n"
35
+ - !ruby/object:Gem::Dependency
36
+ name: hiredis
37
+ requirement: !ruby/object:Gem::Requirement
38
+ requirements:
39
+ - - ">="
40
+ - !ruby/object:Gem::Version
41
+ version: '0'
42
+ type: :development
43
+ prerelease: false
44
+ version_requirements: !ruby/object:Gem::Requirement
45
+ requirements:
46
+ - - ">="
47
+ - !ruby/object:Gem::Version
48
+ version: '0'
49
+ - !ruby/object:Gem::Dependency
50
+ name: mocha
51
+ requirement: !ruby/object:Gem::Requirement
52
+ requirements:
53
+ - - ">="
54
+ - !ruby/object:Gem::Version
55
+ version: '0'
56
+ type: :development
57
+ prerelease: false
58
+ version_requirements: !ruby/object:Gem::Requirement
59
+ requirements:
60
+ - - ">="
61
+ - !ruby/object:Gem::Version
62
+ version: '0'
63
+ description: |2
64
+ A Ruby client that tries to match Redis' API one-to-one, while still
65
+ providing an idiomatic interface.
41
66
  email:
42
67
  - redis-db@googlegroups.com
43
68
  executables: []
44
69
  extensions: []
45
70
  extra_rdoc_files: []
46
71
  files:
47
- - .gitignore
48
- - .order
49
- - .travis.yml
50
- - .travis/Gemfile
51
- - .yardopts
52
72
  - CHANGELOG.md
53
73
  - LICENSE
54
74
  - README.md
55
- - Rakefile
56
- - benchmarking/logging.rb
57
- - benchmarking/pipeline.rb
58
- - benchmarking/speed.rb
59
- - benchmarking/suite.rb
60
- - benchmarking/worker.rb
61
- - examples/basic.rb
62
- - examples/dist_redis.rb
63
- - examples/incr-decr.rb
64
- - examples/list.rb
65
- - examples/pubsub.rb
66
- - examples/sets.rb
67
- - examples/unicorn/config.ru
68
- - examples/unicorn/unicorn.rb
69
75
  - lib/redis.rb
70
76
  - lib/redis/client.rb
77
+ - lib/redis/cluster.rb
78
+ - lib/redis/cluster/command.rb
79
+ - lib/redis/cluster/command_loader.rb
80
+ - lib/redis/cluster/key_slot_converter.rb
81
+ - lib/redis/cluster/node.rb
82
+ - lib/redis/cluster/node_key.rb
83
+ - lib/redis/cluster/node_loader.rb
84
+ - lib/redis/cluster/option.rb
85
+ - lib/redis/cluster/slot.rb
86
+ - lib/redis/cluster/slot_loader.rb
71
87
  - lib/redis/connection.rb
72
88
  - lib/redis/connection/command_helper.rb
73
89
  - lib/redis/connection/hiredis.rb
@@ -80,145 +96,32 @@ files:
80
96
  - lib/redis/pipeline.rb
81
97
  - lib/redis/subscribe.rb
82
98
  - lib/redis/version.rb
83
- - redis.gemspec
84
- - test/blocking_commands_test.rb
85
- - test/command_map_test.rb
86
- - test/commands_on_hashes_test.rb
87
- - test/commands_on_lists_test.rb
88
- - test/commands_on_sets_test.rb
89
- - test/commands_on_sorted_sets_test.rb
90
- - test/commands_on_strings_test.rb
91
- - test/commands_on_value_types_test.rb
92
- - test/connection_handling_test.rb
93
- - test/db/.gitignore
94
- - test/distributed_blocking_commands_test.rb
95
- - test/distributed_commands_on_hashes_test.rb
96
- - test/distributed_commands_on_lists_test.rb
97
- - test/distributed_commands_on_sets_test.rb
98
- - test/distributed_commands_on_sorted_sets_test.rb
99
- - test/distributed_commands_on_strings_test.rb
100
- - test/distributed_commands_on_value_types_test.rb
101
- - test/distributed_commands_requiring_clustering_test.rb
102
- - test/distributed_connection_handling_test.rb
103
- - test/distributed_internals_test.rb
104
- - test/distributed_key_tags_test.rb
105
- - test/distributed_persistence_control_commands_test.rb
106
- - test/distributed_publish_subscribe_test.rb
107
- - test/distributed_remote_server_control_commands_test.rb
108
- - test/distributed_scripting_test.rb
109
- - test/distributed_sorting_test.rb
110
- - test/distributed_test.rb
111
- - test/distributed_transactions_test.rb
112
- - test/encoding_test.rb
113
- - test/error_replies_test.rb
114
- - test/helper.rb
115
- - test/helper_test.rb
116
- - test/internals_test.rb
117
- - test/lint/blocking_commands.rb
118
- - test/lint/hashes.rb
119
- - test/lint/lists.rb
120
- - test/lint/sets.rb
121
- - test/lint/sorted_sets.rb
122
- - test/lint/strings.rb
123
- - test/lint/value_types.rb
124
- - test/persistence_control_commands_test.rb
125
- - test/pipelining_commands_test.rb
126
- - test/publish_subscribe_test.rb
127
- - test/remote_server_control_commands_test.rb
128
- - test/scripting_test.rb
129
- - test/sorting_test.rb
130
- - test/support/connection/hiredis.rb
131
- - test/support/connection/ruby.rb
132
- - test/support/connection/synchrony.rb
133
- - test/support/redis_mock.rb
134
- - test/support/wire/synchrony.rb
135
- - test/support/wire/thread.rb
136
- - test/synchrony_driver.rb
137
- - test/test.conf
138
- - test/thread_safety_test.rb
139
- - test/transactions_test.rb
140
- - test/unknown_commands_test.rb
141
- - test/url_param_test.rb
142
99
  homepage: https://github.com/redis/redis-rb
143
- licenses: []
144
- post_install_message:
100
+ licenses:
101
+ - MIT
102
+ metadata:
103
+ bug_tracker_uri: https://github.com/redis/redis-rb/issues
104
+ changelog_uri: https://github.com/redis/redis-rb/blob/master/CHANGELOG.md
105
+ documentation_uri: https://www.rubydoc.info/gems/redis/4.2.2
106
+ homepage_uri: https://github.com/redis/redis-rb
107
+ source_code_uri: https://github.com/redis/redis-rb/tree/v4.2.2
108
+ post_install_message:
145
109
  rdoc_options: []
146
110
  require_paths:
147
111
  - lib
148
112
  required_ruby_version: !ruby/object:Gem::Requirement
149
- none: false
150
113
  requirements:
151
- - - ! '>='
114
+ - - ">="
152
115
  - !ruby/object:Gem::Version
153
- version: '0'
116
+ version: 2.3.0
154
117
  required_rubygems_version: !ruby/object:Gem::Requirement
155
- none: false
156
118
  requirements:
157
- - - ! '>='
119
+ - - ">="
158
120
  - !ruby/object:Gem::Version
159
121
  version: '0'
160
122
  requirements: []
161
- rubyforge_project:
162
- rubygems_version: 1.8.23
163
- signing_key:
164
- specification_version: 3
123
+ rubygems_version: 3.1.2
124
+ signing_key:
125
+ specification_version: 4
165
126
  summary: A Ruby client library for Redis
166
- test_files:
167
- - test/blocking_commands_test.rb
168
- - test/command_map_test.rb
169
- - test/commands_on_hashes_test.rb
170
- - test/commands_on_lists_test.rb
171
- - test/commands_on_sets_test.rb
172
- - test/commands_on_sorted_sets_test.rb
173
- - test/commands_on_strings_test.rb
174
- - test/commands_on_value_types_test.rb
175
- - test/connection_handling_test.rb
176
- - test/db/.gitignore
177
- - test/distributed_blocking_commands_test.rb
178
- - test/distributed_commands_on_hashes_test.rb
179
- - test/distributed_commands_on_lists_test.rb
180
- - test/distributed_commands_on_sets_test.rb
181
- - test/distributed_commands_on_sorted_sets_test.rb
182
- - test/distributed_commands_on_strings_test.rb
183
- - test/distributed_commands_on_value_types_test.rb
184
- - test/distributed_commands_requiring_clustering_test.rb
185
- - test/distributed_connection_handling_test.rb
186
- - test/distributed_internals_test.rb
187
- - test/distributed_key_tags_test.rb
188
- - test/distributed_persistence_control_commands_test.rb
189
- - test/distributed_publish_subscribe_test.rb
190
- - test/distributed_remote_server_control_commands_test.rb
191
- - test/distributed_scripting_test.rb
192
- - test/distributed_sorting_test.rb
193
- - test/distributed_test.rb
194
- - test/distributed_transactions_test.rb
195
- - test/encoding_test.rb
196
- - test/error_replies_test.rb
197
- - test/helper.rb
198
- - test/helper_test.rb
199
- - test/internals_test.rb
200
- - test/lint/blocking_commands.rb
201
- - test/lint/hashes.rb
202
- - test/lint/lists.rb
203
- - test/lint/sets.rb
204
- - test/lint/sorted_sets.rb
205
- - test/lint/strings.rb
206
- - test/lint/value_types.rb
207
- - test/persistence_control_commands_test.rb
208
- - test/pipelining_commands_test.rb
209
- - test/publish_subscribe_test.rb
210
- - test/remote_server_control_commands_test.rb
211
- - test/scripting_test.rb
212
- - test/sorting_test.rb
213
- - test/support/connection/hiredis.rb
214
- - test/support/connection/ruby.rb
215
- - test/support/connection/synchrony.rb
216
- - test/support/redis_mock.rb
217
- - test/support/wire/synchrony.rb
218
- - test/support/wire/thread.rb
219
- - test/synchrony_driver.rb
220
- - test/test.conf
221
- - test/thread_safety_test.rb
222
- - test/transactions_test.rb
223
- - test/unknown_commands_test.rb
224
- - test/url_param_test.rb
127
+ test_files: []