ffi-hiredis_vip 0.1.0.pre2 → 0.1.0.pre3

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 5d392a1b85f1385b7d1d85dec53a4b53b11bdde7
4
- data.tar.gz: 49d262af8f46e4393a60671eadf411bcc9f8652f
3
+ metadata.gz: 4ead994de23fa7de4efacb74af787d989acb82d4
4
+ data.tar.gz: 2e6f99f82a141bf37eb144bb57e7c1108ebd45cd
5
5
  SHA512:
6
- metadata.gz: a07d40b8d3c9cb72483b4fc09e74c6b07752a2d2a63241882c127e6eb142d71594fdde229798fcfc8479ac674c4e5e747e8090ef8c098a202cf81c9d50f2a0e2
7
- data.tar.gz: 4d3da8146e51139744964f25c964099836977f9ed0d214edf369c003b2526cbfc10711aa802ab7ea0766eca878952a9365f3940dd4c85934b75e54a0b86a68f4
6
+ metadata.gz: efb2b833917327f59abcec80d43908eaba3fee6f113078076e0375e6fee997aef9b955975f2c95a48464e562851976818417734653da3a6036ff04c9ed70b694
7
+ data.tar.gz: 2a35ee601a6d641b0633664e36c8247841137982c6f56955319509f37edcf5e313c1f2194ddfe8e3d08411c7b75cbaaa98a71ecb4195dbb569545c6c7bdd175e
@@ -71,7 +71,7 @@ module FFI
71
71
  def decr(key)
72
72
  reply = nil
73
73
  command = "DECR %b"
74
- command_args = [ :string, key, :size_t, key.size ]
74
+ command_args = [ :pointer, key, :size_t, key.size ]
75
75
  synchronize do |connection|
76
76
  reply = execute_command(connection, command, *command_args)
77
77
  end
@@ -90,7 +90,7 @@ module FFI
90
90
  reply = nil
91
91
  _amount = "#{amount}"
92
92
  command = "DECRBY %b %b"
93
- command_args = [ :string, key, :size_t, key.size, :string, _amount, :size_t, _amount.size ]
93
+ command_args = [ :pointer, key, :size_t, key.size, :string, _amount, :size_t, _amount.size ]
94
94
  synchronize do |connection|
95
95
  reply = execute_command(connection, command, *command_args)
96
96
  end
@@ -112,7 +112,7 @@ module FFI
112
112
  command = "DEL#{' %b' * number_of_deletes}"
113
113
  command_args = []
114
114
  keys.each do |key|
115
- command_args << :string << key << :size_t << key.size
115
+ command_args << :pointer << key << :size_t << key.size
116
116
  end
117
117
 
118
118
  synchronize do |connection|
@@ -132,7 +132,7 @@ module FFI
132
132
  def dump(key)
133
133
  reply = nil
134
134
  command = "DUMP %b"
135
- command_args = [ :string, key, :size_t, key.size ]
135
+ command_args = [ :pointer, key, :size_t, key.size ]
136
136
  synchronize do |connection|
137
137
  reply = execute_command(connection, command, *command_args)
138
138
  end
@@ -150,7 +150,7 @@ module FFI
150
150
  def echo(value)
151
151
  reply = nil
152
152
  command = "ECHO %b"
153
- command_args = [ :string, value, :size_t, value.size ]
153
+ command_args = [ :pointer, value, :size_t, value.size ]
154
154
  synchronize do |connection|
155
155
  reply = execute_command(connection, command, *command_args)
156
156
  end
@@ -183,7 +183,7 @@ module FFI
183
183
  reply = nil
184
184
  time_in_seconds = "#{seconds}"
185
185
  command = "EXPIRE %b %b"
186
- command_args = [ :string, key, :size_t, key.size, :string, time_in_seconds, :size_t, time_in_seconds.size ]
186
+ command_args = [ :pointer, key, :size_t, key.size, :string, time_in_seconds, :size_t, time_in_seconds.size ]
187
187
  synchronize do |connection|
188
188
  reply = execute_command(connection, command, *command_args)
189
189
  end
@@ -207,7 +207,7 @@ module FFI
207
207
  reply = nil
208
208
  epoch = "#{unix_time}"
209
209
  command = "EXPIREAT %b %b"
210
- command_args = [ :string, key, :size_t, key.size, :string, epoch, :size_t, epoch.size ]
210
+ command_args = [ :pointer, key, :size_t, key.size, :string, epoch, :size_t, epoch.size ]
211
211
  synchronize do |connection|
212
212
  reply = execute_command(connection, command, *command_args)
213
213
  end
@@ -269,7 +269,7 @@ module FFI
269
269
  def get(key)
270
270
  reply = nil
271
271
  command = "GET %b"
272
- command_args = [ :string, key, :size_t, key.size ]
272
+ command_args = [ :pointer, key, :size_t, key.size ]
273
273
 
274
274
  synchronize do |connection|
275
275
  reply = execute_command(connection, command, *command_args)
@@ -291,7 +291,7 @@ module FFI
291
291
  def incr(key)
292
292
  reply = nil
293
293
  command = "INCR %b"
294
- command_args = [ :string, key, :size_t, key.size ]
294
+ command_args = [ :pointer, key, :size_t, key.size ]
295
295
  synchronize do |connection|
296
296
  reply = execute_command(connection, command, *command_args)
297
297
  end
@@ -310,7 +310,7 @@ module FFI
310
310
  reply = nil
311
311
  _amount = "#{amount}"
312
312
  command = "INCRBY %b %b"
313
- command_args = [ :string, key, :size_t, key.size, :string, _amount, :size_t, _amount.size ]
313
+ command_args = [ :pointer, key, :size_t, key.size, :string, _amount, :size_t, _amount.size ]
314
314
  synchronize do |connection|
315
315
  reply = execute_command(connection, command, *command_args)
316
316
  end
@@ -500,7 +500,7 @@ module FFI
500
500
  def ttl(key)
501
501
  reply = nil
502
502
  command = "TTL %b"
503
- command_args = [ :string, key, :size_t, key.size ]
503
+ command_args = [ :pointer, key, :size_t, key.size ]
504
504
  synchronize do |connection|
505
505
  reply = execute_command(connection, command, *command_args)
506
506
  end
@@ -12,7 +12,7 @@ module FFI
12
12
  command = "EXISTS#{' %b' * number_of_exists}"
13
13
  command_args = []
14
14
  keys.each do |key|
15
- command_args << :string << key << :size_t << key.size
15
+ command_args << :pointer << key << :size_t << key.size
16
16
  end
17
17
 
18
18
  synchronize do |connection|
@@ -12,7 +12,7 @@ module FFI
12
12
 
13
13
  keys.each do |key|
14
14
  reply = nil
15
- command_args = [ :string, key, :size_t, key.size ]
15
+ command_args = [ :pointer, key, :size_t, key.size ]
16
16
  @client.synchronize do |connection|
17
17
  reply = @client.execute_command(connection, command, *command_args)
18
18
  end
@@ -9,7 +9,7 @@ module FFI
9
9
  reply = nil
10
10
  pattern = "#{pattern}"
11
11
  command = "KEYS %b"
12
- command_args = [ :string, pattern, :size_t, pattern.size ]
12
+ command_args = [ :pointer, pattern, :size_t, pattern.size ]
13
13
 
14
14
  synchronize do |connection|
15
15
  reply = @client.execute_command(connection, command, *command_args)
@@ -12,7 +12,7 @@ module FFI
12
12
  command_args = []
13
13
  keys.each do |key|
14
14
  command << " %b"
15
- command_args << :string << key << :size_t << key.size
15
+ command_args << :pointer << key << :size_t << key.size
16
16
  end
17
17
 
18
18
  synchronize do |connection|
@@ -8,7 +8,7 @@ module FFI
8
8
  def persist(key)
9
9
  reply = nil
10
10
  command = "PERSIST %b"
11
- command_args = [ :string, key, :size_t, key.size ]
11
+ command_args = [ :pointer, key, :size_t, key.size ]
12
12
  synchronize do |connection|
13
13
  reply = @client.execute_command(connection, command, *command_args)
14
14
  end
@@ -10,9 +10,9 @@ module FFI
10
10
  values = values.flatten
11
11
  number_of_values = values.size
12
12
  command = "SADD %b#{' %b' * number_of_values}"
13
- command_args = [ :string, key, :size_t, key.size ]
13
+ command_args = [ :pointer, key, :size_t, key.size ]
14
14
  values.each do |value|
15
- command_args << :string << value << :size_t << value.size
15
+ command_args << :pointer << value << :size_t << value.size
16
16
  end
17
17
 
18
18
  synchronize do |connection|
@@ -13,7 +13,7 @@ module FFI
13
13
  if options[:match]
14
14
  matcher = "#{options[:match]}"
15
15
  command << " MATCH %b"
16
- command_args << :string << matcher << :size_t << matcher.size
16
+ command_args << :pointer << matcher << :size_t << matcher.size
17
17
  end
18
18
 
19
19
  if options[:count]
@@ -13,7 +13,7 @@ module FFI
13
13
  reply = nil
14
14
  command = "SET %b %b"
15
15
  value = value.to_s
16
- command_args = [ :string, key, :size_t, key.size, :string, value, :size_t, value.size ]
16
+ command_args = [ :pointer, key, :size_t, key.size, :pointer, value, :size_t, value.size ]
17
17
 
18
18
  if options[:ex]
19
19
  expiry = "#{options[:ex]}"
@@ -10,7 +10,7 @@ module FFI
10
10
  reply = nil
11
11
  value = value.to_s
12
12
  command = "PSETEX %b %b %b"
13
- command_args = [ :string, key, :size_t, key.size, :string, expiry, :size_t, expiry.size, :string, value, :size_t, value.size ]
13
+ command_args = [ :pointer, key, :size_t, key.size, :string, expiry, :size_t, expiry.size, :pointer, value, :size_t, value.size ]
14
14
 
15
15
  synchronize do |connection|
16
16
  reply = @client.execute_command(connection, command, *command_args)
@@ -34,7 +34,7 @@ module FFI
34
34
  reply = nil
35
35
  value = value.to_s
36
36
  command = "SET %b %b"
37
- command_args = [ :string, key, :size_t, key.size, :string, value, :size_t, value.size ]
37
+ command_args = [ :pointer, key, :size_t, key.size, :pointer, value, :size_t, value.size ]
38
38
 
39
39
  case
40
40
  when options[:ex]
@@ -68,7 +68,7 @@ module FFI
68
68
  reply = nil
69
69
  value = value.to_s
70
70
  command = "SETEX %b %b %b"
71
- command_args = [ :string, key, :size_t, key.size, :string, expiry, :size_t, expiry.size, :string, value, :size_t, value.size ]
71
+ command_args = [ :pointer, key, :size_t, key.size, :string, expiry, :size_t, expiry.size, :pointer, value, :size_t, value.size ]
72
72
 
73
73
  synchronize do |connection|
74
74
  reply = @client.execute_command(connection, command, *command_args)
@@ -92,7 +92,7 @@ module FFI
92
92
  reply = nil
93
93
  value = value.to_s
94
94
  command = "SETNX %b %b"
95
- command_args = [ :string, key, :size_t, key.size, :string, value, :size_t, value.size ]
95
+ command_args = [ :pointer, key, :size_t, key.size, :pointer, value, :size_t, value.size ]
96
96
 
97
97
  synchronize do |connection|
98
98
  reply = @client.execute_command(connection, command, *command_args)
@@ -8,18 +8,18 @@ module FFI
8
8
  def sscan(key, cursor, options = {})
9
9
  reply = nil
10
10
  command = "SSCAN %b %b"
11
- command_args = [ :string, key, :size_t, key.size, :string, cursor, :size_t, cursor.size ]
11
+ command_args = [ :pointer, key, :size_t, key.size, :string, cursor, :size_t, cursor.size ]
12
12
 
13
13
  if options[:match]
14
14
  matcher = "#{options[:match]}"
15
15
  command << " MATCH %b"
16
- command_args << :string << matcher << :size_t << matcher.size
16
+ command_args << :pointer << matcher << :size_t << matcher.size
17
17
  end
18
18
 
19
19
  if options[:count]
20
20
  count = "#{options[:count]}"
21
21
  command << " COUNT %b"
22
- command_args << :string << count << :size_t << count.size
22
+ command_args << :pointer << count << :size_t << count.size
23
23
  end
24
24
 
25
25
  synchronize do |connection|
@@ -12,7 +12,7 @@ module FFI
12
12
  command = "TOUCH#{' %b' * number_of_touches}"
13
13
  command_args = []
14
14
  keys.each do |key|
15
- command_args << :string << key << :size_t << key.size
15
+ command_args << :pointer << key << :size_t << key.size
16
16
  end
17
17
 
18
18
  synchronize do |connection|
@@ -1,5 +1,5 @@
1
1
  module FFI
2
2
  module HiredisVip
3
- VERSION = "0.1.0.pre2"
3
+ VERSION = "0.1.0.pre3"
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: ffi-hiredis_vip
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.0.pre2
4
+ version: 0.1.0.pre3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Brandon Dewitt