gruf 2.0.0 → 2.0.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +4 -0
- data/README.md +1 -1
- data/lib/gruf/interceptors/active_record/connection_reset.rb +5 -1
- data/lib/gruf/version.rb +1 -1
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 355dcc90e5af826c230fed08326ade8b56b57728
|
4
|
+
data.tar.gz: 6c0e2780048afff13c754c23aace69bfbd0c3463
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: e69f8aa9f733f528be6adf971d21c38fbcacbaf18ee9f610bf970a44066f0e6d350858a90f4852006b39277ec2ba4ce63f428fa19d969c327e01850fb17037d7
|
7
|
+
data.tar.gz: 1be4c4efc4bc0af3af2f3bd9516409739a207780f0a6c26009fa5336fa4b46711e602f5565dac65d6929664aed735ab20e9494d7c3f3708b24ec8d6134b9096a
|
data/CHANGELOG.md
CHANGED
@@ -2,6 +2,10 @@ Changelog for the gruf gem. This includes internal history before the gem was ma
|
|
2
2
|
|
3
3
|
### Pending release
|
4
4
|
|
5
|
+
### 2.0.1
|
6
|
+
|
7
|
+
- Handle ActiveRecord connection management more gracefully (Fixes #30)
|
8
|
+
|
5
9
|
### 2.0.0
|
6
10
|
|
7
11
|
Gruf 2.0 is a major shift from Gruf 1.0. See [UPGRADING.md](UPGRADING.md) for details.
|
data/README.md
CHANGED
@@ -123,7 +123,7 @@ username and password pairs (or password-only credentials).
|
|
123
123
|
```ruby
|
124
124
|
Gruf.configure do |c|
|
125
125
|
c.interceptors.use(
|
126
|
-
Gruf::
|
126
|
+
Gruf::Interceptors::Authentication::Basic,
|
127
127
|
credentials: [{
|
128
128
|
username: 'my-username-here',
|
129
129
|
password: 'my-password-here',
|
@@ -26,8 +26,12 @@ module Gruf
|
|
26
26
|
# connection pool, we need to ensure that this is done to properly
|
27
27
|
#
|
28
28
|
def call
|
29
|
-
|
29
|
+
if enabled? && !::ActiveRecord::Base.connection.active?
|
30
|
+
::ActiveRecord::Base.establish_connection
|
31
|
+
end
|
30
32
|
yield
|
33
|
+
ensure
|
34
|
+
::ActiveRecord::Base.clear_active_connections! if enabled?
|
31
35
|
end
|
32
36
|
|
33
37
|
private
|
data/lib/gruf/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: gruf
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.0.
|
4
|
+
version: 2.0.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Shaun McCormick
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2017-10-
|
11
|
+
date: 2017-10-10 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|
@@ -158,7 +158,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
158
158
|
version: '0'
|
159
159
|
requirements: []
|
160
160
|
rubyforge_project:
|
161
|
-
rubygems_version: 2.6.
|
161
|
+
rubygems_version: 2.6.14
|
162
162
|
signing_key:
|
163
163
|
specification_version: 4
|
164
164
|
summary: gRPC Ruby Framework
|