gcra 1.2.0 → 1.2.1

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
  SHA256:
3
- metadata.gz: b02bda1b59d67535c5f7e098f0553e7d79dab0baed8266668e4533eaf083fdd8
4
- data.tar.gz: 12f92e851d067cc367180e9c4528f7564ffc487ddd62273fecd6450fbb8de894
3
+ metadata.gz: 4523f1a5f4d9e01c3363bbfd24a1d50f3933799a3ee8ac2774a82de49687344e
4
+ data.tar.gz: 963f7aaa9d67b39920bedc148d7b5c89d7acc7ec6a538fef58b7f845804e2f05
5
5
  SHA512:
6
- metadata.gz: 993dfc9876b0b5f92e7456a20f1e9da2875505f41457540d7e8a41ea59f2e0080880ad96bc6e7b1751dbea67c60b4b416a88099350a5435c60b467f90f42e1fa
7
- data.tar.gz: cdc1e40167c88d8a3749a8176c2683520973e844063ed3035e4b9be8533c1c07af7d8119ed8eec6a24e3c918850f914a55394784e3db06d8d9c0e91e5bb3eed0
6
+ metadata.gz: 7b049fed03339f68e9ef24e6c4d715b28a894a990deb3e50d4f9bedc4af621f7440300efe41b519158b982806df9b3495972de367e39ae8c599095a0e42466e8
7
+ data.tar.gz: 6f65016b71ad0fce7b47e1f5340e04023ba800304404e1d7eb1dcedb6a183e4dfb0550a58a0cf9b326ef5218f06763e6d12b8b11d79055bda19815a669ef867e
@@ -30,9 +30,9 @@ module GCRA
30
30
  # Returns the value of the key or nil, if it isn't in the store.
31
31
  # Also returns the time from the Redis server, with microsecond precision.
32
32
  def get_with_time(key)
33
- time_response, value = @redis.pipelined do
34
- @redis.time # returns tuple (seconds since epoch, microseconds)
35
- @redis.get(@key_prefix + key)
33
+ time_response, value = @redis.pipelined do |pipeline|
34
+ pipeline.time # returns tuple (seconds since epoch, microseconds)
35
+ pipeline.get(@key_prefix + key)
36
36
  end
37
37
  # Convert tuple to nanoseconds
38
38
  time = (time_response[0] * 1_000_000 + time_response[1]) * 1_000
data/lib/gcra/version.rb CHANGED
@@ -1,3 +1,3 @@
1
1
  module GCRA
2
- VERSION = '1.2.0'.freeze
2
+ VERSION = '1.2.1'.freeze
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: gcra
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.2.0
4
+ version: 1.2.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Michael Frister
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2020-10-18 00:00:00.000000000 Z
12
+ date: 2022-02-12 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: rspec
@@ -41,7 +41,7 @@ dependencies:
41
41
  version: '3.3'
42
42
  description: GCRA implementation for rate limiting
43
43
  email:
44
- - tobias.schoknecht@barzahlen.de
44
+ - tobias.schoknecht@viafintech.com
45
45
  executables: []
46
46
  extensions: []
47
47
  extra_rdoc_files: []
@@ -49,7 +49,7 @@ files:
49
49
  - lib/gcra/rate_limiter.rb
50
50
  - lib/gcra/redis_store.rb
51
51
  - lib/gcra/version.rb
52
- homepage: https://github.com/Barzahlen/gcra-ruby
52
+ homepage: https://github.com/viafintech/gcra-ruby
53
53
  licenses:
54
54
  - MIT
55
55
  metadata: {}