semian 0.13.2 → 0.13.3

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.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 540294c5a9ecdfdcbafcdc1485afd1314a94fd869501bc6795ee327606d3e799
4
- data.tar.gz: 5855959232d25ea3c2da1f7ca7096c18afb15161ac8116e8f1ece9792fd456e4
3
+ metadata.gz: b572c4e4fa4dee4453017187bc759a29890dca1627f8bebea6207223e58e49ba
4
+ data.tar.gz: f8b7f8eda600b096242becc44cb80a10592d9a9b2490349eecb5c11a008c0fe0
5
5
  SHA512:
6
- metadata.gz: c7549cd0c6dc515733612fcd7b200c23467104c5616ff9501b65a554712e0449d07d8d2d479b45962cffb87c8e6cd2fc82d695a1d9f399a5724b3b4c241c59a8
7
- data.tar.gz: cf31ff975016b22e101db10813d73ab8288584657c9f7319ef222790dcd052d3ab45caedcca2639140d2199be87d1f790f0c82edf918d388c669f9be68b467f2
6
+ metadata.gz: 30c39a27e0e57ddcccc794fbe9cc04f1d84c864c1cd2786bb2e4e6e7050b51f152feeba8c66c59d1feae3c195b93a921a76aa1985dc034f00e3394d6b4cb3123
7
+ data.tar.gz: 922ba4aa39b90898b84cb301ee28344e5cfe8f57b523e531db24bba2bee3731d55dda0256bf7dd923fe33175daad960a93a1090addad68a448e6fe384a6a8c42
data/CHANGELOG.md CHANGED
@@ -1,5 +1,9 @@
1
1
  # Unreleased
2
2
 
3
+ # v0.13.3
4
+
5
+ * Add a warning message about redis 5.x. (#386)
6
+
3
7
  # v0.13.2
4
8
 
5
9
  * Fix: Update AbstractAdapter patch to accomodate recent Rails changes. (#364)
data/lib/semian/mysql2.rb CHANGED
@@ -43,16 +43,18 @@ module Semian
43
43
  %r{\A(?:/\*.*?\*/)?\s*RELEASE\s+SAVEPOINT}i,
44
44
  )
45
45
 
46
- # The naked methods are exposed as `raw_query` and `raw_connect` for instrumentation purpose
47
- def self.included(base)
48
- base.send(:alias_method, :raw_query, :query)
49
- base.send(:remove_method, :query)
46
+ class << self
47
+ # The naked methods are exposed as `raw_query` and `raw_connect` for instrumentation purpose
48
+ def included(base)
49
+ base.send(:alias_method, :raw_query, :query)
50
+ base.send(:remove_method, :query)
50
51
 
51
- base.send(:alias_method, :raw_connect, :connect)
52
- base.send(:remove_method, :connect)
52
+ base.send(:alias_method, :raw_connect, :connect)
53
+ base.send(:remove_method, :connect)
53
54
 
54
- base.send(:alias_method, :raw_ping, :ping)
55
- base.send(:remove_method, :ping)
55
+ base.send(:alias_method, :raw_ping, :ping)
56
+ base.send(:remove_method, :ping)
57
+ end
56
58
  end
57
59
 
58
60
  def semian_identifier
data/lib/semian/redis.rb CHANGED
@@ -3,6 +3,11 @@
3
3
  require "semian/adapter"
4
4
  require "redis"
5
5
 
6
+ if Redis::VERSION >= "5.0.0"
7
+ Semian.logger.warn("NOTE: Semian is not compatible with Redis 5.x")
8
+ return
9
+ end
10
+
6
11
  class Redis
7
12
  Redis::BaseConnectionError.include(::Semian::AdapterError)
8
13
  ::Errno::EINVAL.include(::Semian::AdapterError)
@@ -65,13 +70,15 @@ module Semian
65
70
  CircuitOpenError = ::Redis::CircuitOpenError
66
71
  ResolveError = ::Redis::ResolveError
67
72
 
68
- # The naked methods are exposed as `raw_query` and `raw_connect` for instrumentation purpose
69
- def self.included(base)
70
- base.send(:alias_method, :raw_io, :io)
71
- base.send(:remove_method, :io)
73
+ class << self
74
+ # The naked methods are exposed as `raw_query` and `raw_connect` for instrumentation purpose
75
+ def included(base)
76
+ base.send(:alias_method, :raw_io, :io)
77
+ base.send(:remove_method, :io)
72
78
 
73
- base.send(:alias_method, :raw_connect, :connect)
74
- base.send(:remove_method, :connect)
79
+ base.send(:alias_method, :raw_connect, :connect)
80
+ base.send(:remove_method, :connect)
81
+ end
75
82
  end
76
83
 
77
84
  def semian_identifier
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module Semian
4
- VERSION = "0.13.2"
4
+ VERSION = "0.13.3"
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: semian
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.13.2
4
+ version: 0.13.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Scott Francis
@@ -10,7 +10,7 @@ authors:
10
10
  autorequire:
11
11
  bindir: bin
12
12
  cert_chain: []
13
- date: 2022-08-19 00:00:00.000000000 Z
13
+ date: 2022-09-02 00:00:00.000000000 Z
14
14
  dependencies: []
15
15
  description: |2
16
16
  A Ruby C extention that is used to control access to shared resources
@@ -61,7 +61,17 @@ metadata:
61
61
  bug_tracker_uri: https://github.com/Shopify/semian/issues
62
62
  changelog_uri: https://github.com/Shopify/semian/blob/master/CHANGELOG.md
63
63
  source_code_uri: https://github.com/Shopify/semian
64
- post_install_message:
64
+ post_install_message: |2+
65
+
66
+ ==============================================================================
67
+
68
+ semians is not compatible with redis 5.x.
69
+ Update Gemfile to use older redis version:
70
+
71
+ gem "redis", "~> 4.8"
72
+
73
+ ==============================================================================
74
+
65
75
  rdoc_options: []
66
76
  require_paths:
67
77
  - lib