faraday-typhoeus 0.2.1 → 1.1.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +2 -4
- data/lib/faraday/adapter/typhoeus.rb +7 -0
- data/lib/faraday/typhoeus/version.rb +1 -1
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 85608a1b41cb9c7d124e8c846b0d01d931b35358012dcc629ba1bbd19ef0719b
|
4
|
+
data.tar.gz: e00482b428fe1cb2526881162e905412b9aaadcca0db4a8bb50ac39a0a1fef42
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: b2b9bf34fd8d29cf42c8e883f734ee62f0af281b2fdb96282e339413ef2eeb11c9d27358ae44767afec11fd460d7167a2e77c1c813a1840948c9dfffca178c6c
|
7
|
+
data.tar.gz: f112f330c66cb4209d5373dc5b85ecf930dc419dc5126f3efdbc12f5c9ba4d69664a5c611c0c0445acccd8d7f7ca1b90c5b22e4731534f7c3785e37605465523
|
data/README.md
CHANGED
@@ -14,9 +14,7 @@ And then execute:
|
|
14
14
|
|
15
15
|
$ bundle install
|
16
16
|
|
17
|
-
Or install it yourself
|
18
|
-
|
19
|
-
$ gem install faraday-typhoeus
|
17
|
+
Or install it yourself with `gem install faraday-typhoeus` and require it in your ruby code with `require 'faraday/typhoeus'`
|
20
18
|
|
21
19
|
## Usage
|
22
20
|
|
@@ -144,4 +142,4 @@ The gem is available as open source under the terms of the [license][license].
|
|
144
142
|
[faraday_streaming]: https://lostisland.github.io/faraday/usage/streaming
|
145
143
|
[repo]: https://github.com/dleavitt/faraday-typhoeus
|
146
144
|
[license]: LICENSE.md
|
147
|
-
[rubygems]: https://github.com/dleavitt/faraday-typhoeus/blob/main/rubygems
|
145
|
+
[rubygems]: https://github.com/dleavitt/faraday-typhoeus/blob/main/rubygems
|
@@ -1,5 +1,6 @@
|
|
1
1
|
# frozen_string_literal: true
|
2
2
|
|
3
|
+
require 'faraday'
|
3
4
|
require 'typhoeus'
|
4
5
|
|
5
6
|
module Faraday
|
@@ -91,6 +92,12 @@ module Faraday
|
|
91
92
|
end
|
92
93
|
end
|
93
94
|
|
95
|
+
env[:typhoeus_timings] = %i[
|
96
|
+
appconnect connect namelookup pretransfer redirect starttransfer total
|
97
|
+
].to_h do |key|
|
98
|
+
[key, resp.public_send("#{key}_time")]
|
99
|
+
end
|
100
|
+
|
94
101
|
save_response(env, resp.code, resp.body, nil, resp.status_message) do |response_headers|
|
95
102
|
response_headers.parse resp.response_headers
|
96
103
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: faraday-typhoeus
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version:
|
4
|
+
version: 1.1.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Daniel Leavitt
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2023-10-25 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: faraday
|
@@ -73,7 +73,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
73
73
|
- !ruby/object:Gem::Version
|
74
74
|
version: '0'
|
75
75
|
requirements: []
|
76
|
-
rubygems_version: 3.
|
76
|
+
rubygems_version: 3.4.10
|
77
77
|
signing_key:
|
78
78
|
specification_version: 4
|
79
79
|
summary: Faraday adapter for Typhoeus
|