faraday_persistent_excon 0.3.2 → 0.3.3
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
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: c1f85714b132f22e4e9fe9852dbfc6780b6c00f95f5e36e6b77b7f0a9be7de70
|
4
|
+
data.tar.gz: 8946a5d751ef31a98636799191c0563530be3c4ffeb3347c38adc954d294f7a9
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 80df392684a609ed27fc0f4da85f73e1f5675c9a98369ffc0ee34c7310961a6052163af813d94df1986cf65f36288e1d395c2ec5b37399c0a4feaf7359f493eb
|
7
|
+
data.tar.gz: 8e111c4143ae990cf9e5bb201bd8f2360003768ea70a6e4ddaf9704efb7b22a6d609f5d58002b967790e9945162e074d127dbcac02df264d6974ff91b35e4b32
|
data/.dockerignore
ADDED
data/Dockerfile
CHANGED
@@ -1,4 +1,4 @@
|
|
1
|
-
FROM ruby:2.6.
|
1
|
+
FROM ruby:2.6.5-alpine
|
2
2
|
MAINTAINER Ryan Schlesinger <ryan@outstand.com>
|
3
3
|
|
4
4
|
RUN addgroup -g 1000 -S gem && \
|
@@ -11,6 +11,13 @@ RUN addgroup -g 1000 -S gem && \
|
|
11
11
|
git \
|
12
12
|
openssh
|
13
13
|
|
14
|
+
ENV LANG en_US.UTF-8
|
15
|
+
ENV LANGUAGE en_US:en
|
16
|
+
ENV LC_ALL en_US.UTF-8
|
17
|
+
|
18
|
+
ENV BUNDLER_VERSION 2.1.4
|
19
|
+
RUN gem install bundler -v ${BUNDLER_VERSION} -i /usr/local/lib/ruby/gems/$(ls /usr/local/lib/ruby/gems) --force
|
20
|
+
|
14
21
|
WORKDIR /srv
|
15
22
|
RUN chown -R gem:gem /srv
|
16
23
|
USER gem
|
@@ -18,13 +18,13 @@ Gem::Specification.new do |spec|
|
|
18
18
|
spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
|
19
19
|
spec.require_paths = ["lib"]
|
20
20
|
|
21
|
-
spec.add_dependency "faraday"
|
21
|
+
spec.add_dependency "faraday", ">= 0.10.0"
|
22
22
|
spec.add_dependency "excon"
|
23
23
|
spec.add_dependency "connection_pool"
|
24
24
|
spec.add_dependency "activesupport"
|
25
25
|
spec.add_dependency "thread_safe"
|
26
26
|
|
27
|
-
spec.add_development_dependency "bundler", "~> 1
|
28
|
-
spec.add_development_dependency "rake", "~>
|
27
|
+
spec.add_development_dependency "bundler", "~> 2.1"
|
28
|
+
spec.add_development_dependency "rake", "~> 13.0"
|
29
29
|
spec.add_development_dependency "rspec"
|
30
30
|
end
|
@@ -12,7 +12,13 @@ module FaradayPersistentExcon
|
|
12
12
|
|
13
13
|
def perform_request(env)
|
14
14
|
response = FaradayPersistentExcon.perform_request_class.new.call env
|
15
|
-
save_response(
|
15
|
+
save_response(
|
16
|
+
env,
|
17
|
+
response.status.to_i,
|
18
|
+
response.body,
|
19
|
+
response.headers,
|
20
|
+
response.reason_phrase
|
21
|
+
)
|
16
22
|
end
|
17
23
|
end
|
18
24
|
end
|
@@ -11,15 +11,16 @@ module FaradayPersistentExcon
|
|
11
11
|
end
|
12
12
|
|
13
13
|
rescue ::Excon::Errors::SocketError => err
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
|
14
|
+
case err.message
|
15
|
+
when /\btimeout\b/
|
16
|
+
raise Faraday::TimeoutError, err
|
17
|
+
when /\bcertificate\b/
|
18
|
+
raise Faraday::SSLError, err
|
18
19
|
else
|
19
|
-
raise Faraday::
|
20
|
+
raise Faraday::ConnectionFailed, err
|
20
21
|
end
|
21
22
|
rescue ::Excon::Errors::Timeout => err
|
22
|
-
raise Faraday::
|
23
|
+
raise Faraday::TimeoutError, err
|
23
24
|
end
|
24
25
|
|
25
26
|
protected
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: faraday_persistent_excon
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.3.
|
4
|
+
version: 0.3.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Ryan Schlesinger
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2020-06-30 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: faraday
|
@@ -16,14 +16,14 @@ dependencies:
|
|
16
16
|
requirements:
|
17
17
|
- - ">="
|
18
18
|
- !ruby/object:Gem::Version
|
19
|
-
version:
|
19
|
+
version: 0.10.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:
|
26
|
+
version: 0.10.0
|
27
27
|
- !ruby/object:Gem::Dependency
|
28
28
|
name: excon
|
29
29
|
requirement: !ruby/object:Gem::Requirement
|
@@ -86,28 +86,28 @@ dependencies:
|
|
86
86
|
requirements:
|
87
87
|
- - "~>"
|
88
88
|
- !ruby/object:Gem::Version
|
89
|
-
version: '1
|
89
|
+
version: '2.1'
|
90
90
|
type: :development
|
91
91
|
prerelease: false
|
92
92
|
version_requirements: !ruby/object:Gem::Requirement
|
93
93
|
requirements:
|
94
94
|
- - "~>"
|
95
95
|
- !ruby/object:Gem::Version
|
96
|
-
version: '1
|
96
|
+
version: '2.1'
|
97
97
|
- !ruby/object:Gem::Dependency
|
98
98
|
name: rake
|
99
99
|
requirement: !ruby/object:Gem::Requirement
|
100
100
|
requirements:
|
101
101
|
- - "~>"
|
102
102
|
- !ruby/object:Gem::Version
|
103
|
-
version: '
|
103
|
+
version: '13.0'
|
104
104
|
type: :development
|
105
105
|
prerelease: false
|
106
106
|
version_requirements: !ruby/object:Gem::Requirement
|
107
107
|
requirements:
|
108
108
|
- - "~>"
|
109
109
|
- !ruby/object:Gem::Version
|
110
|
-
version: '
|
110
|
+
version: '13.0'
|
111
111
|
- !ruby/object:Gem::Dependency
|
112
112
|
name: rspec
|
113
113
|
requirement: !ruby/object:Gem::Requirement
|
@@ -129,6 +129,7 @@ executables: []
|
|
129
129
|
extensions: []
|
130
130
|
extra_rdoc_files: []
|
131
131
|
files:
|
132
|
+
- ".dockerignore"
|
132
133
|
- ".gitignore"
|
133
134
|
- ".rspec"
|
134
135
|
- ".travis.yml"
|