ebisu_connection 2.2.0 → 2.3.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.travis.yml +1 -1
- data/README.md +44 -43
- data/ebisu_connection.gemspec +3 -3
- data/gemfiles/rails42.gemfile +1 -1
- data/gemfiles/rails50.gemfile +1 -1
- data/lib/ebisu_connection.rb +11 -1
- data/lib/ebisu_connection/conf_file.rb +63 -16
- data/lib/ebisu_connection/connection_manager.rb +26 -17
- data/lib/ebisu_connection/{slave.rb → replica.rb} +4 -4
- data/lib/ebisu_connection/{slave_group.rb → replica_group.rb} +15 -15
- data/lib/ebisu_connection/version.rb +1 -1
- metadata +8 -9
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 8d68fd9cf9403b92b48722cbcfc3f08b66077b7a
|
4
|
+
data.tar.gz: 3829842b34dd46b27489a069caa7ba75fd75c927
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: a76ce24504d64d243ac54c654afff4f9465a9b53cbb0d2a5266a36c62e77fcfaeea71332ce611781ab66b6c6494852f282d1eea1a1697fc5bdd13e0299736214
|
7
|
+
data.tar.gz: effc77faf0ce1d1f710a04e86cbbb6ba2ef9ed142a38c90c2fa0db2b1ac936b961bcbdcd16e2a70ffa44c99c659eade7e4d590406797f97dcc6543bc93b20cc4
|
data/.travis.yml
CHANGED
@@ -8,7 +8,7 @@ before_script:
|
|
8
8
|
- bundle update
|
9
9
|
- cp test/config/database_postgresql.yml.travis test/config/database_postgresql.yml
|
10
10
|
- psql -c 'create database ebisu_connection_test_master;' -U postgres
|
11
|
-
- psql -c 'create database
|
11
|
+
- psql -c 'create database ebisu_connection_test_replica;' -U postgres
|
12
12
|
cache: bundler
|
13
13
|
rvm:
|
14
14
|
- 2.1.10
|
data/README.md
CHANGED
@@ -1,24 +1,24 @@
|
|
1
1
|
# EbisuConnection
|
2
2
|
[![Gem Version](https://badge.fury.io/rb/ebisu_connection.svg)](http://badge.fury.io/rb/ebisu_connection) [![Build Status](https://travis-ci.org/tsukasaoishi/ebisu_connection.svg?branch=master)](https://travis-ci.org/tsukasaoishi/ebisu_connection) [![Code Climate](https://codeclimate.com/github/tsukasaoishi/ebisu_connection/badges/gpa.svg)](https://codeclimate.com/github/tsukasaoishi/ebisu_connection)
|
3
3
|
|
4
|
-
EbisuConnection allows access to
|
5
|
-
You could assign a performance weight to each
|
4
|
+
EbisuConnection allows access to replica servers.
|
5
|
+
You could assign a performance weight to each replica server.
|
6
6
|
|
7
7
|
```
|
8
8
|
Rails ------------ Master DB
|
9
9
|
|
|
10
10
|
|
|
11
|
-
+----
|
11
|
+
+---- Replica1 DB (weight 10)
|
12
12
|
|
|
13
13
|
|
|
14
|
-
+----
|
14
|
+
+---- Replica2 DB (weight 20)
|
15
15
|
```
|
16
16
|
|
17
|
-
If you could put a load balancer in front of
|
17
|
+
If you could put a load balancer in front of replica servers, should use [FreshConnection](https://github.com/tsukasaoishi/fresh_connection).
|
18
18
|
|
19
19
|
## Usage
|
20
|
-
### Access to
|
21
|
-
Read query goes to the
|
20
|
+
### Access to Replica
|
21
|
+
Read query goes to the replica server.
|
22
22
|
|
23
23
|
```ruby
|
24
24
|
Article.where(:id => 1)
|
@@ -50,7 +50,8 @@ article.destory
|
|
50
50
|
```
|
51
51
|
|
52
52
|
## Support ActiveRecord version
|
53
|
-
EbisuConnection supports ActiveRecord version 4.
|
53
|
+
EbisuConnection supports ActiveRecord version 4.2 or later.
|
54
|
+
If you are using Rails 4.1 or 4.0, you can use EbisuConnection version 2.1.0 or before.
|
54
55
|
If you are using Rails 3.2, could use EbisuConnection version 1.0.0 or before.
|
55
56
|
|
56
57
|
## Support DB
|
@@ -92,27 +93,27 @@ production:
|
|
92
93
|
host: localhost
|
93
94
|
socket: /var/run/mysqld/mysqld.sock
|
94
95
|
|
95
|
-
|
96
|
-
username:
|
97
|
-
password:
|
98
|
-
host:
|
96
|
+
replica:
|
97
|
+
username: replica
|
98
|
+
password: replica
|
99
|
+
host: replica
|
99
100
|
```
|
100
101
|
|
101
|
-
```
|
102
|
+
```replica``` is a config to connect to replica servers.
|
102
103
|
Others will use the master server settings.
|
103
104
|
|
104
|
-
Config of each
|
105
|
+
Config of each replica server fill out to `config/replica.yml`
|
105
106
|
|
106
107
|
```yaml
|
107
108
|
production:
|
108
|
-
- "
|
109
|
-
- "
|
109
|
+
- "replica1, 10"
|
110
|
+
- "replica2, 20"
|
110
111
|
-
|
111
|
-
host: "
|
112
|
+
host: "replica3"
|
112
113
|
weight: 30
|
113
114
|
```
|
114
115
|
|
115
|
-
If ``config/
|
116
|
+
If ``config/replica.yml`` changed, it is reflected dynamic. Application doesn't need restart.
|
116
117
|
|
117
118
|
```yaml
|
118
119
|
"hostname, weight"
|
@@ -120,8 +121,8 @@ If ``config/slave.yml`` changed, it is reflected dynamic. Application doesn't ne
|
|
120
121
|
|
121
122
|
String format is it. You can write config with hash.
|
122
123
|
|
123
|
-
### use multiple
|
124
|
-
If you may want to user multiple
|
124
|
+
### use multiple replica servers group
|
125
|
+
If you may want to user multiple replica group, write multiple replica group to config/database.yml.
|
125
126
|
|
126
127
|
```yaml
|
127
128
|
production:
|
@@ -135,45 +136,45 @@ production:
|
|
135
136
|
host: localhost
|
136
137
|
socket: /var/run/mysqld/mysqld.sock
|
137
138
|
|
138
|
-
|
139
|
-
username:
|
140
|
-
password:
|
141
|
-
host:
|
139
|
+
replica:
|
140
|
+
username: replica
|
141
|
+
password: replica
|
142
|
+
host: replica
|
142
143
|
|
143
|
-
|
144
|
-
username:
|
145
|
-
password:
|
146
|
-
host:
|
144
|
+
admin_replica:
|
145
|
+
username: replica
|
146
|
+
password: replica
|
147
|
+
host: admin_replica
|
147
148
|
```
|
148
149
|
|
149
|
-
Config of each
|
150
|
+
Config of each replica server fill out to `config/replica.yml`
|
150
151
|
|
151
152
|
```yaml
|
152
153
|
production:
|
153
|
-
|
154
|
-
- "
|
155
|
-
- "
|
154
|
+
replica:
|
155
|
+
- "replica1, 10"
|
156
|
+
- "replica2, 20"
|
156
157
|
-
|
157
|
-
host: "
|
158
|
+
host: "replica3"
|
158
159
|
weight: 30
|
159
|
-
|
160
|
-
- "
|
161
|
-
- "
|
160
|
+
admin_replica:
|
161
|
+
- "replica4, 10"
|
162
|
+
- "replica5, 20"
|
162
163
|
```
|
163
164
|
|
164
|
-
And call establish_fresh_connection method in model that access to ```
|
165
|
+
And call establish_fresh_connection method in model that access to ```admin_replica``` replica group.
|
165
166
|
|
166
167
|
```ruby
|
167
168
|
class AdminUser < ActiveRecord::Base
|
168
|
-
establish_fresh_connection :
|
169
|
+
establish_fresh_connection :admin_replica
|
169
170
|
end
|
170
171
|
```
|
171
172
|
|
172
|
-
The children is access to same
|
173
|
+
The children is access to same replica group of parent.
|
173
174
|
|
174
175
|
```ruby
|
175
176
|
class Parent < ActiveRecord::Base
|
176
|
-
establish_fresh_connection :
|
177
|
+
establish_fresh_connection :admin_replica
|
177
178
|
end
|
178
179
|
|
179
180
|
class AdminUser < Parent
|
@@ -183,10 +184,10 @@ class Benefit < Parent
|
|
183
184
|
end
|
184
185
|
```
|
185
186
|
|
186
|
-
AdminUser and Benefit access to ```
|
187
|
+
AdminUser and Benefit access to ```admin_replica``` replica group.
|
187
188
|
|
188
189
|
|
189
|
-
### Declare model that doesn't use
|
190
|
+
### Declare model that doesn't use replica db
|
190
191
|
|
191
192
|
```ruby
|
192
193
|
class SomethingModel < ActiveRecord::Base
|
@@ -202,7 +203,7 @@ The model that master_db_only model's child is always access to master db.
|
|
202
203
|
```ruby
|
203
204
|
before_fork do |server, worker|
|
204
205
|
...
|
205
|
-
ActiveRecord::Base.
|
206
|
+
ActiveRecord::Base.clear_all_replica_connections!
|
206
207
|
...
|
207
208
|
end
|
208
209
|
|
data/ebisu_connection.gemspec
CHANGED
@@ -9,8 +9,8 @@ Gem::Specification.new do |spec|
|
|
9
9
|
spec.authors = ["tsukasaoishi"]
|
10
10
|
spec.email = ["tsukasa.oishi@gmail.com"]
|
11
11
|
|
12
|
-
spec.summary = %q{EbisuConnection supports
|
13
|
-
spec.description = %q{
|
12
|
+
spec.summary = %q{EbisuConnection supports connections with configured replica servers.}
|
13
|
+
spec.description = %q{https://github.com/tsukasaoishi/ebisu_connection}
|
14
14
|
spec.homepage = "https://github.com/tsukasaoishi/ebisu_connection"
|
15
15
|
spec.license = "MIT"
|
16
16
|
|
@@ -21,7 +21,7 @@ Gem::Specification.new do |spec|
|
|
21
21
|
|
22
22
|
spec.required_ruby_version = '>= 2.1'
|
23
23
|
|
24
|
-
spec.add_dependency 'fresh_connection', '~> 2.
|
24
|
+
spec.add_dependency 'fresh_connection', '~> 2.3.0'
|
25
25
|
spec.add_dependency 'concurrent-ruby', '~> 1.0.0'
|
26
26
|
|
27
27
|
spec.add_development_dependency 'mysql2', '>= 0.3.13', '< 0.5'
|
data/gemfiles/rails42.gemfile
CHANGED
data/gemfiles/rails50.gemfile
CHANGED
data/lib/ebisu_connection.rb
CHANGED
@@ -1,3 +1,4 @@
|
|
1
|
+
require 'active_support/deprecation'
|
1
2
|
require "fresh_connection"
|
2
3
|
require "ebisu_connection/conf_file"
|
3
4
|
|
@@ -5,8 +6,16 @@ module EbisuConnection
|
|
5
6
|
class << self
|
6
7
|
attr_writer :env
|
7
8
|
|
9
|
+
def replica_file=(file)
|
10
|
+
ConfFile.replica_file = file
|
11
|
+
end
|
12
|
+
|
8
13
|
def slaves_file=(file)
|
9
|
-
|
14
|
+
ActiveSupport::Deprecation.warn(
|
15
|
+
"'slaves_file=' is deprecated and will removed from version 2.4.0. use 'replica_file=' insted."
|
16
|
+
)
|
17
|
+
|
18
|
+
self.replica_file = file
|
10
19
|
end
|
11
20
|
|
12
21
|
def check_interval=(interval)
|
@@ -21,3 +30,4 @@ end
|
|
21
30
|
|
22
31
|
require "ebisu_connection/connection_manager"
|
23
32
|
FreshConnection.connection_manager = EbisuConnection::ConnectionManager
|
33
|
+
ActiveRecord::Base.establish_fresh_connection
|
@@ -1,9 +1,18 @@
|
|
1
1
|
require 'yaml'
|
2
|
+
require 'active_support/deprecation'
|
2
3
|
|
3
4
|
module EbisuConnection
|
4
5
|
class ConfFile
|
5
6
|
class << self
|
6
|
-
attr_writer :
|
7
|
+
attr_writer :replica_file, :check_interval
|
8
|
+
|
9
|
+
def slaves_file=(file)
|
10
|
+
ActiveSupport::Deprecation.warn(
|
11
|
+
"'slaves_file=' is deprecated and will removed from version 2.4.0. use 'replica_file=' insted."
|
12
|
+
)
|
13
|
+
|
14
|
+
self.replica_file = file
|
15
|
+
end
|
7
16
|
|
8
17
|
def if_modify
|
9
18
|
if time_to_check? && modify?
|
@@ -12,25 +21,63 @@ module EbisuConnection
|
|
12
21
|
end
|
13
22
|
|
14
23
|
def conf_clear!
|
15
|
-
@
|
24
|
+
@replica_conf = nil
|
16
25
|
end
|
17
26
|
|
18
|
-
def
|
19
|
-
@
|
20
|
-
|
21
|
-
|
27
|
+
def replica_conf(replica_group)
|
28
|
+
@replica_conf ||= get_replica_conf
|
29
|
+
|
30
|
+
if @replica_conf.is_a?(Hash)
|
31
|
+
c = @replica_conf[replica_group]
|
32
|
+
|
33
|
+
if !c && replica_group == "replica" && @replica_conf.key?("slave")
|
34
|
+
ActiveSupport::Deprecation.warn(
|
35
|
+
"'slave' in replica.yml is deprecated and will ignored from version 2.4.0. use 'replica' insted."
|
36
|
+
)
|
37
|
+
|
38
|
+
c = @replica_conf["slave"]
|
39
|
+
end
|
40
|
+
|
41
|
+
c || @replica_conf
|
22
42
|
else
|
23
|
-
@
|
43
|
+
@replica_conf
|
24
44
|
end
|
25
45
|
end
|
26
46
|
|
47
|
+
def slaves_conf(replica_group)
|
48
|
+
ActiveSupport::Deprecation.warn(
|
49
|
+
"'slaves_conf' is deprecated and will removed from version 2.4.0. use 'replica_conf' insted."
|
50
|
+
)
|
51
|
+
|
52
|
+
replica_conf(replica_group)
|
53
|
+
end
|
54
|
+
|
55
|
+
def replica_file
|
56
|
+
return @replica_file if @replica_file
|
57
|
+
raise "nothing replica_file. You have to set a file path using EbisuConnection.replica_file= method" unless defined?(Rails)
|
58
|
+
|
59
|
+
file = %w(yml yaml).map{|ext| Rails.root.join("config/replica.#{ext}").to_s }.detect {|f| File.exist?(f) }
|
60
|
+
|
61
|
+
unless file
|
62
|
+
file = %w(yml yaml).map{|ext| Rails.root.join("config/slave.#{ext}").to_s }.detect {|f| File.exist?(f) }
|
63
|
+
if file
|
64
|
+
ActiveSupport::Deprecation.warn(
|
65
|
+
"file name 'config/#{file}' is deprecated and will ignored from version 2.4.0. use 'config/replica.yml' insted."
|
66
|
+
)
|
67
|
+
end
|
68
|
+
end
|
69
|
+
|
70
|
+
raise "nothing replica_file. You have to put a config/replica.yml file" unless file
|
71
|
+
|
72
|
+
@replica_file = file
|
73
|
+
end
|
74
|
+
|
27
75
|
def slaves_file
|
28
|
-
|
29
|
-
|
76
|
+
ActiveSupport::Deprecation.warn(
|
77
|
+
"'slaves_file' is deprecated and will removed from version 2.4.0. use 'replica_file' insted."
|
78
|
+
)
|
30
79
|
|
31
|
-
|
32
|
-
raise "nothing slaves_file. You have to put a config/slave.yml file" unless @slaves_file
|
33
|
-
@slaves_file
|
80
|
+
replica_file
|
34
81
|
end
|
35
82
|
|
36
83
|
def check_interval
|
@@ -50,12 +97,12 @@ module EbisuConnection
|
|
50
97
|
end
|
51
98
|
|
52
99
|
def modify?
|
53
|
-
@file_mtime != File.mtime(
|
100
|
+
@file_mtime != File.mtime(replica_file)
|
54
101
|
end
|
55
102
|
|
56
|
-
def
|
57
|
-
@file_mtime = File.mtime(
|
58
|
-
conf = YAML.load_file(
|
103
|
+
def get_replica_conf
|
104
|
+
@file_mtime = File.mtime(replica_file)
|
105
|
+
conf = YAML.load_file(replica_file)
|
59
106
|
conf[EbisuConnection.env.to_s] || {}
|
60
107
|
end
|
61
108
|
end
|
@@ -1,15 +1,24 @@
|
|
1
1
|
require "concurrent"
|
2
|
-
require
|
2
|
+
require 'active_support/deprecation'
|
3
|
+
require "ebisu_connection/replica_group"
|
3
4
|
|
4
5
|
module EbisuConnection
|
5
6
|
class ConnectionManager < FreshConnection::AbstractConnectionManager
|
6
|
-
def initialize(
|
7
|
+
def initialize(replica_group = "replica")
|
7
8
|
super
|
8
|
-
@
|
9
|
+
@replicas = Concurrent::Map.new
|
10
|
+
end
|
11
|
+
|
12
|
+
def replica_connection
|
13
|
+
replicas.sample.connection
|
9
14
|
end
|
10
15
|
|
11
16
|
def slave_connection
|
12
|
-
|
17
|
+
ActiveSupport::Deprecation.warn(
|
18
|
+
"'slave_connection' is deprecated and will removed from version 2.4.0. use 'replica_connection' insted."
|
19
|
+
)
|
20
|
+
|
21
|
+
replica_connection
|
13
22
|
end
|
14
23
|
|
15
24
|
def put_aside!
|
@@ -22,26 +31,26 @@ module EbisuConnection
|
|
22
31
|
end
|
23
32
|
|
24
33
|
def clear_all_connections!
|
25
|
-
@
|
34
|
+
@replicas.each_value do |s|
|
26
35
|
s.all_disconnect!
|
27
36
|
end
|
28
37
|
|
29
|
-
@
|
38
|
+
@replicas.clear
|
30
39
|
ConfFile.conf_clear!
|
31
40
|
end
|
32
41
|
|
33
42
|
def recovery?
|
34
|
-
|
43
|
+
replicas.recovery_connection?
|
35
44
|
end
|
36
45
|
|
37
46
|
private
|
38
47
|
|
39
48
|
def check_own_connection
|
40
|
-
s = @
|
49
|
+
s = @replicas[current_thread_id]
|
41
50
|
|
42
51
|
if s && s.reserved_release?
|
43
52
|
s.all_disconnect!
|
44
|
-
@
|
53
|
+
@replicas.delete(current_thread_id)
|
45
54
|
true
|
46
55
|
else
|
47
56
|
false
|
@@ -49,24 +58,24 @@ module EbisuConnection
|
|
49
58
|
end
|
50
59
|
|
51
60
|
def reserve_release_all_connection
|
52
|
-
@
|
61
|
+
@replicas.each_value do |s|
|
53
62
|
s.reserve_release_connection!
|
54
63
|
end
|
55
64
|
ConfFile.conf_clear!
|
56
65
|
end
|
57
66
|
|
58
|
-
def
|
59
|
-
@
|
60
|
-
|
67
|
+
def replicas
|
68
|
+
@replicas.fetch_or_store(current_thread_id) do |_|
|
69
|
+
get_replicas
|
61
70
|
end
|
62
71
|
end
|
63
72
|
|
64
|
-
def
|
65
|
-
|
73
|
+
def get_replicas
|
74
|
+
ReplicaGroup.new(replica_conf, replica_group)
|
66
75
|
end
|
67
76
|
|
68
|
-
def
|
69
|
-
ConfFile.
|
77
|
+
def replica_conf
|
78
|
+
ConfFile.replica_conf(replica_group)
|
70
79
|
end
|
71
80
|
|
72
81
|
def current_thread_id
|
@@ -1,8 +1,8 @@
|
|
1
1
|
module EbisuConnection
|
2
|
-
class
|
2
|
+
class Replica
|
3
3
|
attr_reader :hostname, :weight
|
4
4
|
|
5
|
-
def initialize(conf,
|
5
|
+
def initialize(conf, replica_group)
|
6
6
|
case conf
|
7
7
|
when String
|
8
8
|
host, weight = conf.split(/\s*,\s*/)
|
@@ -12,11 +12,11 @@ module EbisuConnection
|
|
12
12
|
weight = conf["weight"] || conf[:weight]
|
13
13
|
port = conf["port"] || conf[:port]
|
14
14
|
else
|
15
|
-
raise ArgumentError, "
|
15
|
+
raise ArgumentError, "replica config is invalid"
|
16
16
|
end
|
17
17
|
|
18
18
|
spec = modify_spec(port)
|
19
|
-
@connection_factory = FreshConnection::ConnectionFactory.new(
|
19
|
+
@connection_factory = FreshConnection::ConnectionFactory.new(replica_group, spec)
|
20
20
|
@weight = (weight || 1).to_i
|
21
21
|
end
|
22
22
|
|
@@ -1,33 +1,33 @@
|
|
1
|
-
require "ebisu_connection/
|
1
|
+
require "ebisu_connection/replica"
|
2
2
|
require "ebisu_connection/greatest_common_divisor"
|
3
3
|
|
4
4
|
module EbisuConnection
|
5
|
-
class
|
6
|
-
class
|
5
|
+
class ReplicaGroup
|
6
|
+
class AllReplicaHasGoneError < StandardError; end
|
7
7
|
|
8
|
-
def initialize(
|
9
|
-
@
|
10
|
-
|
8
|
+
def initialize(replica_conf, replica_group)
|
9
|
+
@replicas = replica_conf.map do |conf|
|
10
|
+
Replica.new(conf, replica_group)
|
11
11
|
end
|
12
12
|
|
13
13
|
recalc_roulette
|
14
14
|
end
|
15
15
|
|
16
16
|
def sample
|
17
|
-
raise
|
18
|
-
@
|
17
|
+
raise AllReplicaHasGoneError if @replicas.empty?
|
18
|
+
@replicas[@roulette.sample]
|
19
19
|
end
|
20
20
|
|
21
21
|
def recovery_connection?
|
22
|
-
|
23
|
-
return false if
|
22
|
+
dead_replicas = @replicas.select{|s| !s.active? }
|
23
|
+
return false if dead_replicas.empty?
|
24
24
|
|
25
|
-
|
25
|
+
dead_replicas.each do |s|
|
26
26
|
s.disconnect!
|
27
|
-
@
|
27
|
+
@replicas.delete(s)
|
28
28
|
end
|
29
29
|
|
30
|
-
raise
|
30
|
+
raise AllReplicaHasGoneError if @replicas.empty?
|
31
31
|
|
32
32
|
recalc_roulette
|
33
33
|
true
|
@@ -35,7 +35,7 @@ module EbisuConnection
|
|
35
35
|
|
36
36
|
def all_disconnect!
|
37
37
|
@reserve_release = nil
|
38
|
-
@
|
38
|
+
@replicas.each {|s| s.disconnect!}
|
39
39
|
end
|
40
40
|
|
41
41
|
def reserve_release_connection!
|
@@ -49,7 +49,7 @@ module EbisuConnection
|
|
49
49
|
private
|
50
50
|
|
51
51
|
def recalc_roulette
|
52
|
-
weight_list = @
|
52
|
+
weight_list = @replicas.map {|s| s.weight }
|
53
53
|
|
54
54
|
@roulette = []
|
55
55
|
gcd = GreatestCommonDivisor.calc(weight_list)
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: ebisu_connection
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.
|
4
|
+
version: 2.3.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- tsukasaoishi
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2017-
|
11
|
+
date: 2017-04-19 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: fresh_connection
|
@@ -16,14 +16,14 @@ dependencies:
|
|
16
16
|
requirements:
|
17
17
|
- - "~>"
|
18
18
|
- !ruby/object:Gem::Version
|
19
|
-
version: 2.
|
19
|
+
version: 2.3.0
|
20
20
|
type: :runtime
|
21
21
|
prerelease: false
|
22
22
|
version_requirements: !ruby/object:Gem::Requirement
|
23
23
|
requirements:
|
24
24
|
- - "~>"
|
25
25
|
- !ruby/object:Gem::Version
|
26
|
-
version: 2.
|
26
|
+
version: 2.3.0
|
27
27
|
- !ruby/object:Gem::Dependency
|
28
28
|
name: concurrent-ruby
|
29
29
|
requirement: !ruby/object:Gem::Requirement
|
@@ -148,8 +148,7 @@ dependencies:
|
|
148
148
|
- - ">="
|
149
149
|
- !ruby/object:Gem::Version
|
150
150
|
version: '0'
|
151
|
-
description:
|
152
|
-
need Load Balancer.
|
151
|
+
description: https://github.com/tsukasaoishi/ebisu_connection
|
153
152
|
email:
|
154
153
|
- tsukasa.oishi@gmail.com
|
155
154
|
executables: []
|
@@ -174,8 +173,8 @@ files:
|
|
174
173
|
- lib/ebisu_connection/conf_file.rb
|
175
174
|
- lib/ebisu_connection/connection_manager.rb
|
176
175
|
- lib/ebisu_connection/greatest_common_divisor.rb
|
177
|
-
- lib/ebisu_connection/
|
178
|
-
- lib/ebisu_connection/
|
176
|
+
- lib/ebisu_connection/replica.rb
|
177
|
+
- lib/ebisu_connection/replica_group.rb
|
179
178
|
- lib/ebisu_connection/version.rb
|
180
179
|
homepage: https://github.com/tsukasaoishi/ebisu_connection
|
181
180
|
licenses:
|
@@ -200,5 +199,5 @@ rubyforge_project:
|
|
200
199
|
rubygems_version: 2.5.2
|
201
200
|
signing_key:
|
202
201
|
specification_version: 4
|
203
|
-
summary: EbisuConnection supports
|
202
|
+
summary: EbisuConnection supports connections with configured replica servers.
|
204
203
|
test_files: []
|