redis-client 0.23.1 → 0.23.2

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: 25ebbae246af076a81474ed506bb8df3dc199475253ab710d0f6963003c7f5a7
4
- data.tar.gz: 36681410082da8b122180382b075e8b39f2bb9ed4985359476804b8f3be09053
3
+ metadata.gz: a3aa8079ed55ab823901c58ee7fc725142ac9f2a964a7db9df9b6eaa8bf3b668
4
+ data.tar.gz: 59127fed6458c327bd964a02e7e53de5172ba17eef7fc79b5dcae4a9cf339d6b
5
5
  SHA512:
6
- metadata.gz: c2609c86de3f6ef9a48e209c75fce8cf9becb0b620f936993eb00272ed2c71b8775a53f76a2ad02079d3d9d831b30ddd1a5e68b4e337f3bac265e9365120cd78
7
- data.tar.gz: 00ae97c0b541a9bb99a731088ad280e586581784b17afb4dfebfb918583047451f1131ecb22a2f94eedaff16afa4ca10e933334b617eefb894131da782316066
6
+ metadata.gz: e0cb0139b70d63b59379364699b0ff4a883df931cd8ee60248dd5db23c20c789e752904babce6d48ecd215ef12eae8783c007b85aff1c6cb84057431d3cb1d1e
7
+ data.tar.gz: 8fe7a3923239ca5143ac01d1b92e724d6ad3001cdb477032e7ed182358c16b0f38037f2f92e2e0b0f329c97967b477df65a041eace290605734d73dfcc7ab050
data/CHANGELOG.md CHANGED
@@ -1,5 +1,9 @@
1
1
  # Unreleased
2
2
 
3
+ # 0.23.2
4
+
5
+ - Fix retry logic not to attempt to retry on an open circuit breaker. Fix #227.
6
+
3
7
  # 0.23.1
4
8
 
5
9
  - Fix a potential crash in `hiredis-client` when using subcriptions (`next_event`). See #221.
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  class RedisClient
4
- VERSION = "0.23.1"
4
+ VERSION = "0.23.2"
5
5
  end
data/lib/redis_client.rb CHANGED
@@ -710,9 +710,14 @@ class RedisClient
710
710
  end
711
711
  rescue ConnectionError, ProtocolError => error
712
712
  preferred_error ||= error
713
- preferred_error = error unless error.is_a?(CircuitBreaker::OpenCircuitError)
714
713
  close
715
714
 
715
+ if error.is_a?(CircuitBreaker::OpenCircuitError)
716
+ raise preferred_error
717
+ else
718
+ preferred_error = error
719
+ end
720
+
716
721
  if !@disable_reconnection && config.retry_connecting?(tries, error)
717
722
  tries += 1
718
723
  retry
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: redis-client
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.23.1
4
+ version: 0.23.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Jean Boussier
8
8
  bindir: bin
9
9
  cert_chain: []
10
- date: 2025-01-12 00:00:00.000000000 Z
10
+ date: 2025-01-16 00:00:00.000000000 Z
11
11
  dependencies:
12
12
  - !ruby/object:Gem::Dependency
13
13
  name: connection_pool