active_replicas 0.1.1 → 0.1.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
  SHA1:
3
- metadata.gz: 427ca73933de1c1f3074567a2658ae21bf7b4a2d
4
- data.tar.gz: cec562e1e12412a2e37f31b28e67b854bc384900
3
+ metadata.gz: 12543c609a56645522b185ac709b69e9acfc3a92
4
+ data.tar.gz: 8b3009b7ba30137204b742ec39794e1e13702036
5
5
  SHA512:
6
- metadata.gz: 72d817738a586ed4c80c844e0308f6e941ed26aef8194280da3f8c659e481ad97b0ad56ffef83eef7b88decd85473a25aac5269598a1dee51ffe855fd6fb4308
7
- data.tar.gz: 176e55128a50a79874164e8559579c76da9d197996bc1ce3e5b44e3baaedcec9d0495fc9735551cb22668a87c8310254b604090ae49cb69bd0fcfe84d6340f93
6
+ metadata.gz: b1409e66dabb4e520b0f903d60749681372177b3aaa69beb8a4b07467eb74db08c0d118d7831d5aee1ae633715eb11d1a264697a298537e760d88bf478a6599c
7
+ data.tar.gz: da45f12c15c38eb999f8de4d267933301040a0dd949e96b982c518236077d9a532df21d10a26318edfc0008a9a38144cfa69c9264ecad8893ecb2ec5d32287ba
@@ -7,8 +7,8 @@ module ActiveReplicas
7
7
  class ConnectionHandler
8
8
  def initialize(proxy_configuration:, delegate: nil, overrides: nil)
9
9
  @proxy_configuration = proxy_configuration
10
- @delegate = delegate
11
- @overrides = Set.new(overrides || [])
10
+ # @delegate = delegate
11
+ # @overrides = Set.new(overrides || [])
12
12
 
13
13
  # Each process will get its own map of connection keys to database
14
14
  # connection instances.
@@ -42,6 +42,14 @@ module ActiveReplicas
42
42
  pool && pool.connected?
43
43
  end
44
44
 
45
+ def remove_connection(owner_klass)
46
+ if pool = @process_to_connection_pool.delete(Process.pid)
47
+ pool.automatic_reconnect = false
48
+ pool.disconnect!
49
+ pool.spec.config
50
+ end
51
+ end
52
+
45
53
  def proxying_connection_pool
46
54
  @process_to_connection_pool[Process.pid] ||= ProxyingConnectionPool.new(@proxy_configuration)
47
55
  end
@@ -1,3 +1,3 @@
1
1
  module ActiveReplicas
2
- VERSION = "0.1.1"
2
+ VERSION = "0.1.2"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: active_replicas
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.1
4
+ version: 0.1.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Dirk Gadsden