active_record_shards 3.19.0 → 3.19.1
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:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 391c29fd84c7b17ac74855b2397903b512648796a6212feebff5cf6984be78a8
|
|
4
|
+
data.tar.gz: cce74b546554fd8994ec90ee69fa3aef6a259c6c2aaec193834fd082da9668bc
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 033e74714876add1c2e89c479b44bc23374371410c5f961967ed2dc58719f8bae2eb9212e8ed87af4294380beb72dcc13cfab92acdedb34147a62411115cdb00
|
|
7
|
+
data.tar.gz: 2f217fb5098b08417973c8430d3cc46715203a7402060d0980148a3f492f01f1b95d7fdcfa4a30b6a31b6643b0dd21d037b40a239863df64c19515f26d27417f
|
|
@@ -4,7 +4,7 @@ module ActiveRecordShards
|
|
|
4
4
|
name = current_shard_selection.resolve_connection_name(sharded: is_sharded?, configurations: configurations)
|
|
5
5
|
|
|
6
6
|
unless configurations[name] || name == "primary"
|
|
7
|
-
raise ActiveRecord::AdapterNotSpecified, "No database defined by #{name} in your database config. (configurations: #{configurations.keys.inspect})"
|
|
7
|
+
raise ActiveRecord::AdapterNotSpecified, "No database defined by #{name} in your database config. (configurations: #{configurations.to_h.keys.inspect})"
|
|
8
8
|
end
|
|
9
9
|
|
|
10
10
|
name
|
|
@@ -4,7 +4,7 @@ module ActiveRecordShards
|
|
|
4
4
|
name = current_shard_selection.resolve_connection_name(sharded: is_sharded?, configurations: configurations)
|
|
5
5
|
|
|
6
6
|
unless configurations[name] || name == "primary"
|
|
7
|
-
raise ActiveRecord::AdapterNotSpecified, "No database defined by #{name} in your database config. (configurations: #{configurations.keys.inspect})"
|
|
7
|
+
raise ActiveRecord::AdapterNotSpecified, "No database defined by #{name} in your database config. (configurations: #{configurations.to_h.keys.inspect})"
|
|
8
8
|
end
|
|
9
9
|
|
|
10
10
|
name
|
|
@@ -154,7 +154,7 @@ module ActiveRecordShards
|
|
|
154
154
|
|
|
155
155
|
def shard_names
|
|
156
156
|
unless config = configurations[shard_env]
|
|
157
|
-
raise "Did not find #{shard_env} in configurations, did you forget to add it to your database config? (configurations: #{configurations.keys.inspect})"
|
|
157
|
+
raise "Did not find #{shard_env} in configurations, did you forget to add it to your database config? (configurations: #{configurations.to_h.keys.inspect})"
|
|
158
158
|
end
|
|
159
159
|
unless config.fetch(SHARD_NAMES_CONFIG_KEY, []).all? { |shard_name| shard_name.is_a?(Integer) }
|
|
160
160
|
raise "All shard names must be integers: #{config[SHARD_NAMES_CONFIG_KEY].inspect}."
|
|
@@ -173,7 +173,7 @@ module ActiveRecordShards
|
|
|
173
173
|
|
|
174
174
|
if options.key?(:shard)
|
|
175
175
|
unless configurations[shard_env]
|
|
176
|
-
raise "Did not find #{shard_env} in configurations, did you forget to add it to your database config? (configurations: #{configurations.keys.inspect})"
|
|
176
|
+
raise "Did not find #{shard_env} in configurations, did you forget to add it to your database config? (configurations: #{configurations.to_h.keys.inspect})"
|
|
177
177
|
end
|
|
178
178
|
|
|
179
179
|
current_shard_selection.shard = options[:shard]
|
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: active_record_shards
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 3.19.
|
|
4
|
+
version: 3.19.1
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Benjamin Quorning
|
|
@@ -13,7 +13,7 @@ authors:
|
|
|
13
13
|
autorequire:
|
|
14
14
|
bindir: bin
|
|
15
15
|
cert_chain: []
|
|
16
|
-
date: 2021-
|
|
16
|
+
date: 2021-09-23 00:00:00.000000000 Z
|
|
17
17
|
dependencies:
|
|
18
18
|
- !ruby/object:Gem::Dependency
|
|
19
19
|
name: activerecord
|