sequel-replica-failover 1.0.0 → 1.0.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
  SHA1:
3
- metadata.gz: 4427d0bd15392df069157501d649dc8f1208ca14
4
- data.tar.gz: bc0ee4ad2bcad88f2aaf3d724418dea7b5d47c82
3
+ metadata.gz: 4d6591f26230c08ccc58cecb7b05646362451251
4
+ data.tar.gz: e708c054f4068721c8478a6e0e25cc8da79621ed
5
5
  SHA512:
6
- metadata.gz: 80086a61fbc3969a6696df41f25d4b97f9306528c502d0cfe9c289dc5e18dbc0a25f69de1863fe18fa1ea161148918d6aae0dc61ccf89b5236735e93ef5e230c
7
- data.tar.gz: 473f829e1df49607fc6516fb5b3f583b820b12ba878f7057b08b0e4b43976a7112c1a464d96bffd2b6e5ba49549bba68ec32f386306a9109f6e3fbbb2e52eb7c
6
+ metadata.gz: 35432ccbcda3fa45526c08b308234f755335a912a0d5d80215be7d60c822a97af66e46871c3eea23319c0210d772df80329c49075ae8612b178f548df17690ff
7
+ data.tar.gz: 3d022a85dc1f8deaea5683bf28fd193c35ed47b5037526750f7363bd2eb976a5db25d628a1884cb316f7edfcf2df22f9034699976e225cfd0d8d3a8743ffee59
@@ -27,3 +27,5 @@ module Sequel
27
27
  end
28
28
  end
29
29
  end
30
+
31
+ Sequel::ReplicaFailover::DTraceProvider.provider
@@ -1,5 +1,5 @@
1
1
  module Sequel
2
2
  module ReplicaFailover
3
- VERSION = '1.0.0'
3
+ VERSION = '1.0.1'
4
4
  end
5
5
  end
@@ -41,7 +41,8 @@ class Sequel::ShardedSingleFailoverConnectionPool < Sequel::ShardedSingleConnect
41
41
  unstick(:read_only)
42
42
  end
43
43
 
44
- super(server, &block)
44
+ server = pick_server(server)
45
+ block.call(@conns[server] ||= make_new(server))
45
46
  rescue Sequel::DatabaseDisconnectError, Sequel::DatabaseConnectionError => e
46
47
  raise if server != :read_only
47
48
  raise if @db.in_transaction?(server: :read_only)
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: sequel-replica-failover
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.0
4
+ version: 1.0.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Paul Henry
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2014-06-18 00:00:00.000000000 Z
11
+ date: 2014-06-19 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: sequel