rack-streaming-proxy 2.0.1 → 2.0.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +5 -0
- data/lib/rack/streaming_proxy/response.rb +1 -1
- data/lib/rack/streaming_proxy/version.rb +1 -1
- data/spec/app.ru +1 -1
- data/spec/streaming_proxy_spec.rb +9 -4
- metadata +25 -24
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 0335a2cdc20c6be40b435a210737a961378c8ba7
|
4
|
+
data.tar.gz: 82deb121466cb7b64b5c5a6c0e42bc8b60731b8d
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 053e265e7ee40b593f3a3db6e33f3ba37c226e5d8ba248d0ab5e6044a6d32454d9f498e1deba85df5575943f301afe1c5cc43a54c05deeeac57ed994dfa9a611
|
7
|
+
data.tar.gz: 345a2a78c9d922fe12e7f2addc15c0a9ea56895dd01aadc9aeb45fe09cca8215e0d9d6646eb82f361bd98a88ff09739a16cac2b32c18ed78a4abba42028b2c31
|
data/CHANGELOG.md
ADDED
@@ -20,7 +20,7 @@ class Rack::StreamingProxy::Response
|
|
20
20
|
while chunk = read_from_destination
|
21
21
|
break if chunk == :done
|
22
22
|
if @chunked
|
23
|
-
size = bytesize
|
23
|
+
size = chunk.bytesize
|
24
24
|
next if size == 0
|
25
25
|
if @client_http_version >= '1.1'
|
26
26
|
yield [size.to_s(16), term, chunk, term].join
|
data/spec/app.ru
CHANGED
@@ -54,18 +54,23 @@ shared_examples "rack-streaming-proxy" do
|
|
54
54
|
it "preserves cookies" do
|
55
55
|
set_cookie "foo"
|
56
56
|
post "/env", {}, rack_env
|
57
|
-
|
57
|
+
|
58
|
+
last_response.match("HTTP_COOKIE: ([^\n]*)")[1].should == "foo"
|
58
59
|
end
|
59
60
|
|
60
61
|
it "preserves authentication info" do
|
61
|
-
|
62
|
+
# due to https://github.com/brynary/rack-test/issues/64
|
63
|
+
encoded_login = ["admin:secret"].pack("m0*")
|
64
|
+
header('Authorization', "Basic #{encoded_login}")
|
65
|
+
|
62
66
|
post "/env", {}, rack_env
|
63
|
-
|
67
|
+
|
68
|
+
last_response.match("HTTP_AUTHORIZATION: ([^\n]*)")[1].should == "Basic YWRtaW46c2VjcmV0"
|
64
69
|
end
|
65
70
|
|
66
71
|
it "preserves arbitrary headers" do
|
67
72
|
get "/env", {}, rack_env.merge("HTTP_X_FOOHEADER" => "Bar")
|
68
|
-
|
73
|
+
last_response.match("HTTP_X_FOOHEADER: ([^\n]*)")[1].should == "Bar"
|
69
74
|
end
|
70
75
|
end
|
71
76
|
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: rack-streaming-proxy
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.0.
|
4
|
+
version: 2.0.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Fred Ngo
|
@@ -10,132 +10,132 @@ authors:
|
|
10
10
|
autorequire:
|
11
11
|
bindir: bin
|
12
12
|
cert_chain: []
|
13
|
-
date:
|
13
|
+
date: 2017-01-25 00:00:00.000000000 Z
|
14
14
|
dependencies:
|
15
15
|
- !ruby/object:Gem::Dependency
|
16
16
|
name: rack
|
17
17
|
requirement: !ruby/object:Gem::Requirement
|
18
18
|
requirements:
|
19
|
-
- -
|
19
|
+
- - ">="
|
20
20
|
- !ruby/object:Gem::Version
|
21
21
|
version: '1.4'
|
22
22
|
type: :runtime
|
23
23
|
prerelease: false
|
24
24
|
version_requirements: !ruby/object:Gem::Requirement
|
25
25
|
requirements:
|
26
|
-
- -
|
26
|
+
- - ">="
|
27
27
|
- !ruby/object:Gem::Version
|
28
28
|
version: '1.4'
|
29
29
|
- !ruby/object:Gem::Dependency
|
30
30
|
name: servolux
|
31
31
|
requirement: !ruby/object:Gem::Requirement
|
32
32
|
requirements:
|
33
|
-
- - ~>
|
33
|
+
- - "~>"
|
34
34
|
- !ruby/object:Gem::Version
|
35
35
|
version: '0.10'
|
36
36
|
type: :runtime
|
37
37
|
prerelease: false
|
38
38
|
version_requirements: !ruby/object:Gem::Requirement
|
39
39
|
requirements:
|
40
|
-
- - ~>
|
40
|
+
- - "~>"
|
41
41
|
- !ruby/object:Gem::Version
|
42
42
|
version: '0.10'
|
43
43
|
- !ruby/object:Gem::Dependency
|
44
44
|
name: bundler
|
45
45
|
requirement: !ruby/object:Gem::Requirement
|
46
46
|
requirements:
|
47
|
-
- -
|
47
|
+
- - ">="
|
48
48
|
- !ruby/object:Gem::Version
|
49
49
|
version: '1.3'
|
50
50
|
type: :development
|
51
51
|
prerelease: false
|
52
52
|
version_requirements: !ruby/object:Gem::Requirement
|
53
53
|
requirements:
|
54
|
-
- -
|
54
|
+
- - ">="
|
55
55
|
- !ruby/object:Gem::Version
|
56
56
|
version: '1.3'
|
57
57
|
- !ruby/object:Gem::Dependency
|
58
58
|
name: rake
|
59
59
|
requirement: !ruby/object:Gem::Requirement
|
60
60
|
requirements:
|
61
|
-
- -
|
61
|
+
- - ">="
|
62
62
|
- !ruby/object:Gem::Version
|
63
63
|
version: '10.0'
|
64
64
|
type: :development
|
65
65
|
prerelease: false
|
66
66
|
version_requirements: !ruby/object:Gem::Requirement
|
67
67
|
requirements:
|
68
|
-
- -
|
68
|
+
- - ">="
|
69
69
|
- !ruby/object:Gem::Version
|
70
70
|
version: '10.0'
|
71
71
|
- !ruby/object:Gem::Dependency
|
72
72
|
name: rspec
|
73
73
|
requirement: !ruby/object:Gem::Requirement
|
74
74
|
requirements:
|
75
|
-
- -
|
75
|
+
- - ">="
|
76
76
|
- !ruby/object:Gem::Version
|
77
77
|
version: '0'
|
78
78
|
type: :development
|
79
79
|
prerelease: false
|
80
80
|
version_requirements: !ruby/object:Gem::Requirement
|
81
81
|
requirements:
|
82
|
-
- -
|
82
|
+
- - ">="
|
83
83
|
- !ruby/object:Gem::Version
|
84
84
|
version: '0'
|
85
85
|
- !ruby/object:Gem::Dependency
|
86
86
|
name: rack-test
|
87
87
|
requirement: !ruby/object:Gem::Requirement
|
88
88
|
requirements:
|
89
|
-
- -
|
89
|
+
- - ">="
|
90
90
|
- !ruby/object:Gem::Version
|
91
91
|
version: '0'
|
92
92
|
type: :development
|
93
93
|
prerelease: false
|
94
94
|
version_requirements: !ruby/object:Gem::Requirement
|
95
95
|
requirements:
|
96
|
-
- -
|
96
|
+
- - ">="
|
97
97
|
- !ruby/object:Gem::Version
|
98
98
|
version: '0'
|
99
99
|
- !ruby/object:Gem::Dependency
|
100
100
|
name: unicorn
|
101
101
|
requirement: !ruby/object:Gem::Requirement
|
102
102
|
requirements:
|
103
|
-
- -
|
103
|
+
- - ">="
|
104
104
|
- !ruby/object:Gem::Version
|
105
105
|
version: '0'
|
106
106
|
type: :development
|
107
107
|
prerelease: false
|
108
108
|
version_requirements: !ruby/object:Gem::Requirement
|
109
109
|
requirements:
|
110
|
-
- -
|
110
|
+
- - ">="
|
111
111
|
- !ruby/object:Gem::Version
|
112
112
|
version: '0'
|
113
113
|
- !ruby/object:Gem::Dependency
|
114
114
|
name: pry
|
115
115
|
requirement: !ruby/object:Gem::Requirement
|
116
116
|
requirements:
|
117
|
-
- -
|
117
|
+
- - ">="
|
118
118
|
- !ruby/object:Gem::Version
|
119
119
|
version: '0'
|
120
120
|
type: :development
|
121
121
|
prerelease: false
|
122
122
|
version_requirements: !ruby/object:Gem::Requirement
|
123
123
|
requirements:
|
124
|
-
- -
|
124
|
+
- - ">="
|
125
125
|
- !ruby/object:Gem::Version
|
126
126
|
version: '0'
|
127
127
|
- !ruby/object:Gem::Dependency
|
128
128
|
name: pry-nav
|
129
129
|
requirement: !ruby/object:Gem::Requirement
|
130
130
|
requirements:
|
131
|
-
- -
|
131
|
+
- - ">="
|
132
132
|
- !ruby/object:Gem::Version
|
133
133
|
version: '0'
|
134
134
|
type: :development
|
135
135
|
prerelease: false
|
136
136
|
version_requirements: !ruby/object:Gem::Requirement
|
137
137
|
requirements:
|
138
|
-
- -
|
138
|
+
- - ">="
|
139
139
|
- !ruby/object:Gem::Version
|
140
140
|
version: '0'
|
141
141
|
description: Streaming proxy for Rack, the rainbows to Rack::Proxy's unicorn.
|
@@ -147,7 +147,8 @@ executables: []
|
|
147
147
|
extensions: []
|
148
148
|
extra_rdoc_files: []
|
149
149
|
files:
|
150
|
-
- .gitignore
|
150
|
+
- ".gitignore"
|
151
|
+
- CHANGELOG.md
|
151
152
|
- Gemfile
|
152
153
|
- LICENSE.txt
|
153
154
|
- README.md
|
@@ -179,17 +180,17 @@ require_paths:
|
|
179
180
|
- lib
|
180
181
|
required_ruby_version: !ruby/object:Gem::Requirement
|
181
182
|
requirements:
|
182
|
-
- -
|
183
|
+
- - ">="
|
183
184
|
- !ruby/object:Gem::Version
|
184
185
|
version: '0'
|
185
186
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
186
187
|
requirements:
|
187
|
-
- -
|
188
|
+
- - ">="
|
188
189
|
- !ruby/object:Gem::Version
|
189
190
|
version: '0'
|
190
191
|
requirements: []
|
191
192
|
rubyforge_project:
|
192
|
-
rubygems_version: 2.
|
193
|
+
rubygems_version: 2.5.2
|
193
194
|
signing_key:
|
194
195
|
specification_version: 4
|
195
196
|
summary: Streaming proxy for Rack, the rainbows to Rack::Proxy's unicorn.
|