goliath 0.9.1 → 0.9.2
Sign up to get free protection for your applications and to get access to all the features.
Potentially problematic release.
This version of goliath might be problematic. Click here for more details.
- data/.gitignore +1 -0
- data/HISTORY +50 -0
- data/README.md +2 -0
- data/examples/activerecord/srv.rb +1 -3
- data/examples/async_aroundware_demo.rb +81 -0
- data/examples/async_upload.rb +1 -2
- data/examples/auth_and_rate_limit.rb +143 -0
- data/examples/chunked_streaming.rb +37 -0
- data/examples/conf_test.rb +1 -3
- data/examples/config/auth_and_rate_limit.rb +30 -0
- data/examples/config/template.rb +8 -0
- data/examples/content_stream.rb +1 -3
- data/examples/echo.rb +8 -6
- data/examples/env_use_statements.rb +17 -0
- data/examples/gziped.rb +1 -3
- data/examples/public/stylesheets/style.css +296 -0
- data/examples/rack_routes.rb +65 -3
- data/examples/rasterize/rasterize.js +15 -0
- data/examples/rasterize/rasterize.rb +36 -0
- data/examples/rasterize/rasterize_and_shorten.rb +37 -0
- data/examples/stream.rb +2 -2
- data/examples/template.rb +48 -0
- data/examples/test_rig.rb +125 -0
- data/examples/valid.rb +4 -2
- data/examples/views/debug.haml +4 -0
- data/examples/views/joke.markdown +13 -0
- data/examples/views/layout.erb +12 -0
- data/examples/views/layout.haml +39 -0
- data/examples/views/root.haml +28 -0
- data/goliath.gemspec +10 -3
- data/lib/goliath.rb +0 -36
- data/lib/goliath/api.rb +137 -26
- data/lib/goliath/application.rb +71 -21
- data/lib/goliath/connection.rb +4 -2
- data/lib/goliath/constants.rb +1 -0
- data/lib/goliath/env.rb +40 -1
- data/lib/goliath/goliath.rb +30 -15
- data/lib/goliath/headers.rb +2 -2
- data/lib/goliath/plugins/latency.rb +8 -2
- data/lib/goliath/rack.rb +18 -0
- data/lib/goliath/rack/async_aroundware.rb +56 -0
- data/lib/goliath/rack/async_middleware.rb +93 -0
- data/lib/goliath/rack/builder.rb +42 -0
- data/lib/goliath/rack/default_response_format.rb +3 -15
- data/lib/goliath/rack/formatters.rb +11 -0
- data/lib/goliath/rack/formatters/html.rb +2 -18
- data/lib/goliath/rack/formatters/json.rb +2 -17
- data/lib/goliath/rack/formatters/plist.rb +32 -0
- data/lib/goliath/rack/formatters/xml.rb +23 -31
- data/lib/goliath/rack/formatters/yaml.rb +27 -0
- data/lib/goliath/rack/jsonp.rb +1 -13
- data/lib/goliath/rack/params.rb +55 -27
- data/lib/goliath/rack/render.rb +13 -22
- data/lib/goliath/rack/templates.rb +357 -0
- data/lib/goliath/rack/tracer.rb +11 -12
- data/lib/goliath/rack/validation.rb +12 -0
- data/lib/goliath/rack/validation/default_params.rb +0 -2
- data/lib/goliath/rack/validation/numeric_range.rb +11 -2
- data/lib/goliath/rack/validation/request_method.rb +3 -2
- data/lib/goliath/rack/validation/required_param.rb +13 -11
- data/lib/goliath/rack/validation/required_value.rb +11 -15
- data/lib/goliath/rack/validator.rb +51 -0
- data/lib/goliath/request.rb +34 -20
- data/lib/goliath/response.rb +3 -2
- data/lib/goliath/runner.rb +5 -11
- data/lib/goliath/server.rb +2 -1
- data/lib/goliath/synchrony/mongo_receiver.rb +64 -0
- data/lib/goliath/synchrony/response_receiver.rb +64 -0
- data/lib/goliath/test_helper.rb +39 -21
- data/lib/goliath/validation.rb +2 -0
- data/lib/goliath/{rack/validation_error.rb → validation/error.rb} +0 -16
- data/lib/goliath/validation/standard_http_errors.rb +31 -0
- data/lib/goliath/version.rb +1 -1
- data/spec/integration/http_log_spec.rb +16 -16
- data/spec/integration/rack_routes_spec.rb +144 -0
- data/spec/integration/reloader_spec.rb +4 -4
- data/spec/integration/template_spec.rb +54 -0
- data/spec/integration/trace_spec.rb +23 -0
- data/spec/integration/valid_spec.rb +21 -0
- data/spec/spec_helper.rb +3 -1
- data/spec/unit/api_spec.rb +30 -0
- data/spec/unit/rack/builder_spec.rb +40 -0
- data/spec/unit/rack/formatters/plist_spec.rb +51 -0
- data/spec/unit/rack/formatters/yaml_spec.rb +53 -0
- data/spec/unit/rack/params_spec.rb +22 -0
- data/spec/unit/rack/render_spec.rb +10 -5
- data/spec/unit/rack/validation/numeric_range_spec.rb +8 -1
- data/spec/unit/rack/validation/request_method_spec.rb +8 -8
- data/spec/unit/rack/validation/required_param_spec.rb +19 -15
- data/spec/unit/rack/validation/required_value_spec.rb +10 -13
- data/spec/unit/server_spec.rb +4 -4
- data/spec/unit/validation/standard_http_errors_spec.rb +21 -0
- metadata +177 -35
- data/spec/unit/rack/validation_error_spec.rb +0 -40
@@ -44,55 +44,52 @@ describe Goliath::Rack::Validation::RequiredValue do
|
|
44
44
|
|
45
45
|
context '#value_valid!' do
|
46
46
|
it 'raises exception if the key is not provided' do
|
47
|
-
|
47
|
+
@rv.value_valid?(@env['params']).should be_false
|
48
48
|
end
|
49
49
|
|
50
50
|
it 'raises exception if the key is blank' do
|
51
51
|
@env['params']['mk'] = ''
|
52
|
-
|
53
|
-
lambda { @rv.value_valid!(@env['params']) }.should raise_error(Goliath::Validation::Error)
|
52
|
+
@rv.value_valid?(@env['params']).should be_false
|
54
53
|
end
|
55
54
|
|
56
55
|
it 'raises exception if the key is nil' do
|
57
56
|
@env['params']['mk'] = nil
|
58
|
-
|
59
|
-
lambda { @rv.value_valid!(@env['params']) }.should raise_error(Goliath::Validation::Error)
|
57
|
+
@rv.value_valid?(@env['params']).should be_false
|
60
58
|
end
|
61
59
|
|
62
60
|
it 'raises exception if the key is does not match' do
|
63
61
|
@env['params']['mk'] = "blarg"
|
64
|
-
|
65
|
-
lambda { @rv.value_valid!(@env['params']) }.should raise_error(Goliath::Validation::Error)
|
62
|
+
@rv.value_valid?(@env['params']).should be_false
|
66
63
|
end
|
67
64
|
|
68
65
|
it 'handles an empty array' do
|
69
66
|
@env['params']['mk'] = []
|
70
|
-
|
67
|
+
@rv.value_valid?(@env['params']).should be_false
|
71
68
|
end
|
72
69
|
|
73
70
|
it 'handles an array of nils' do
|
74
71
|
@env['params']['mk'] = [nil, nil, nil]
|
75
|
-
|
72
|
+
@rv.value_valid?(@env['params']).should be_false
|
76
73
|
end
|
77
74
|
|
78
75
|
it 'handles an array of blanks' do
|
79
76
|
@env['params']['mk'] = ['', '', '']
|
80
|
-
|
77
|
+
@rv.value_valid?(@env['params']).should be_false
|
81
78
|
end
|
82
79
|
|
83
80
|
it "doesn't raise if the key is value" do
|
84
81
|
@env['params']['mk'] = 'Monkey'
|
85
|
-
|
82
|
+
@rv.value_valid?(@env['params']).should be_true
|
86
83
|
end
|
87
84
|
|
88
85
|
it "doesn't raise if the array contains valid data" do
|
89
86
|
@env['params']['mk'] = ['Monkey', 'frog']
|
90
|
-
|
87
|
+
@rv.value_valid?(@env['params']).should be_true
|
91
88
|
end
|
92
89
|
|
93
90
|
it 'raises if any of the array elements do not match' do
|
94
91
|
@env['params']['mk'] = ["Monkey", "frog", "bat"]
|
95
|
-
|
92
|
+
@rv.value_valid?(@env['params']).should be_false
|
96
93
|
end
|
97
94
|
end
|
98
95
|
end
|
data/spec/unit/server_spec.rb
CHANGED
@@ -106,28 +106,28 @@ describe Goliath::Server do
|
|
106
106
|
context 'config parsing' do
|
107
107
|
context 'environment' do
|
108
108
|
it 'executes the block if the environment matches the provided string' do
|
109
|
-
Goliath.env =
|
109
|
+
Goliath.env = :development
|
110
110
|
block_run = false
|
111
111
|
@s.environment('development') { block_run = true }
|
112
112
|
block_run.should be_true
|
113
113
|
end
|
114
114
|
|
115
115
|
it 'does not execute the block if the environment does not match' do
|
116
|
-
Goliath.env =
|
116
|
+
Goliath.env = :development
|
117
117
|
block_run = false
|
118
118
|
@s.environment('test') { block_run = true }
|
119
119
|
block_run.should be_false
|
120
120
|
end
|
121
121
|
|
122
122
|
it 'accepts an array of environments' do
|
123
|
-
Goliath.env =
|
123
|
+
Goliath.env = :development
|
124
124
|
block_run = false
|
125
125
|
@s.environment(['development', 'test']) { block_run = true }
|
126
126
|
block_run.should be_true
|
127
127
|
end
|
128
128
|
|
129
129
|
it 'does not run the block if the environment is not in the array' do
|
130
|
-
Goliath.env =
|
130
|
+
Goliath.env = :production
|
131
131
|
block_run = false
|
132
132
|
@s.environment(['development', 'test']) { block_run = true }
|
133
133
|
block_run.should be_false
|
@@ -0,0 +1,21 @@
|
|
1
|
+
require 'spec_helper'
|
2
|
+
require 'goliath/validation/standard_http_errors'
|
3
|
+
|
4
|
+
describe Goliath::Validation::Error do
|
5
|
+
it 'defines exceptions for each standard error response' do
|
6
|
+
lambda { Goliath::Validation::BadRequestError.new }.should_not raise_error
|
7
|
+
Goliath::Validation::BadRequestError.should < Goliath::Validation::Error
|
8
|
+
end
|
9
|
+
|
10
|
+
it 'defines InternalServerError not InternalServerErrorError' do
|
11
|
+
lambda { Goliath::Validation::InternalServerError.new }.should_not raise_error
|
12
|
+
Goliath::Validation::InternalServerError.should < Goliath::Validation::Error
|
13
|
+
end
|
14
|
+
|
15
|
+
it 'sets a default status code and message' do
|
16
|
+
nfe = Goliath::Validation::NotFoundError.new
|
17
|
+
nfe.status_code.should == '404'
|
18
|
+
nfe.message.should == 'Not Found'
|
19
|
+
end
|
20
|
+
end
|
21
|
+
|
metadata
CHANGED
@@ -2,7 +2,7 @@
|
|
2
2
|
name: goliath
|
3
3
|
version: !ruby/object:Gem::Version
|
4
4
|
prerelease:
|
5
|
-
version: 0.9.
|
5
|
+
version: 0.9.2
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
8
8
|
- dan sinclair
|
@@ -11,7 +11,7 @@ autorequire:
|
|
11
11
|
bindir: bin
|
12
12
|
cert_chain: []
|
13
13
|
|
14
|
-
date: 2011-
|
14
|
+
date: 2011-07-21 00:00:00 -04:00
|
15
15
|
default_executable:
|
16
16
|
dependencies:
|
17
17
|
- !ruby/object:Gem::Dependency
|
@@ -22,7 +22,7 @@ dependencies:
|
|
22
22
|
requirements:
|
23
23
|
- - ">="
|
24
24
|
- !ruby/object:Gem::Version
|
25
|
-
version: 1.0.0.beta.
|
25
|
+
version: 1.0.0.beta.3
|
26
26
|
type: :runtime
|
27
27
|
version_requirements: *id001
|
28
28
|
- !ruby/object:Gem::Dependency
|
@@ -114,40 +114,40 @@ dependencies:
|
|
114
114
|
type: :runtime
|
115
115
|
version_requirements: *id009
|
116
116
|
- !ruby/object:Gem::Dependency
|
117
|
-
name:
|
117
|
+
name: http_router
|
118
118
|
prerelease: false
|
119
119
|
requirement: &id010 !ruby/object:Gem::Requirement
|
120
120
|
none: false
|
121
121
|
requirements:
|
122
|
-
- -
|
122
|
+
- - ~>
|
123
123
|
- !ruby/object:Gem::Version
|
124
|
-
version:
|
125
|
-
type: :
|
124
|
+
version: 0.8.9
|
125
|
+
type: :runtime
|
126
126
|
version_requirements: *id010
|
127
127
|
- !ruby/object:Gem::Dependency
|
128
|
-
name:
|
128
|
+
name: rake
|
129
129
|
prerelease: false
|
130
130
|
requirement: &id011 !ruby/object:Gem::Requirement
|
131
131
|
none: false
|
132
132
|
requirements:
|
133
|
-
- - "
|
133
|
+
- - "="
|
134
134
|
- !ruby/object:Gem::Version
|
135
|
-
version:
|
135
|
+
version: 0.8.7
|
136
136
|
type: :development
|
137
137
|
version_requirements: *id011
|
138
138
|
- !ruby/object:Gem::Dependency
|
139
|
-
name:
|
139
|
+
name: rspec
|
140
140
|
prerelease: false
|
141
141
|
requirement: &id012 !ruby/object:Gem::Requirement
|
142
142
|
none: false
|
143
143
|
requirements:
|
144
|
-
- - "
|
144
|
+
- - ">"
|
145
145
|
- !ruby/object:Gem::Version
|
146
|
-
version:
|
146
|
+
version: "2.0"
|
147
147
|
type: :development
|
148
148
|
version_requirements: *id012
|
149
149
|
- !ruby/object:Gem::Dependency
|
150
|
-
name:
|
150
|
+
name: nokogiri
|
151
151
|
prerelease: false
|
152
152
|
requirement: &id013 !ruby/object:Gem::Requirement
|
153
153
|
none: false
|
@@ -158,18 +158,18 @@ dependencies:
|
|
158
158
|
type: :development
|
159
159
|
version_requirements: *id013
|
160
160
|
- !ruby/object:Gem::Dependency
|
161
|
-
name:
|
161
|
+
name: em-http-request
|
162
162
|
prerelease: false
|
163
163
|
requirement: &id014 !ruby/object:Gem::Requirement
|
164
164
|
none: false
|
165
165
|
requirements:
|
166
166
|
- - ">="
|
167
167
|
- !ruby/object:Gem::Version
|
168
|
-
version:
|
168
|
+
version: 1.0.0.beta.1
|
169
169
|
type: :development
|
170
170
|
version_requirements: *id014
|
171
171
|
- !ruby/object:Gem::Dependency
|
172
|
-
name:
|
172
|
+
name: em-mongo
|
173
173
|
prerelease: false
|
174
174
|
requirement: &id015 !ruby/object:Gem::Requirement
|
175
175
|
none: false
|
@@ -180,7 +180,7 @@ dependencies:
|
|
180
180
|
type: :development
|
181
181
|
version_requirements: *id015
|
182
182
|
- !ruby/object:Gem::Dependency
|
183
|
-
name:
|
183
|
+
name: yajl-ruby
|
184
184
|
prerelease: false
|
185
185
|
requirement: &id016 !ruby/object:Gem::Requirement
|
186
186
|
none: false
|
@@ -191,18 +191,18 @@ dependencies:
|
|
191
191
|
type: :development
|
192
192
|
version_requirements: *id016
|
193
193
|
- !ruby/object:Gem::Dependency
|
194
|
-
name:
|
194
|
+
name: rack-rewrite
|
195
195
|
prerelease: false
|
196
196
|
requirement: &id017 !ruby/object:Gem::Requirement
|
197
197
|
none: false
|
198
198
|
requirements:
|
199
199
|
- - ">="
|
200
200
|
- !ruby/object:Gem::Version
|
201
|
-
version: 0
|
201
|
+
version: "0"
|
202
202
|
type: :development
|
203
203
|
version_requirements: *id017
|
204
204
|
- !ruby/object:Gem::Dependency
|
205
|
-
name:
|
205
|
+
name: multipart_body
|
206
206
|
prerelease: false
|
207
207
|
requirement: &id018 !ruby/object:Gem::Requirement
|
208
208
|
none: false
|
@@ -213,16 +213,60 @@ dependencies:
|
|
213
213
|
type: :development
|
214
214
|
version_requirements: *id018
|
215
215
|
- !ruby/object:Gem::Dependency
|
216
|
-
name:
|
216
|
+
name: amqp
|
217
217
|
prerelease: false
|
218
218
|
requirement: &id019 !ruby/object:Gem::Requirement
|
219
219
|
none: false
|
220
220
|
requirements:
|
221
221
|
- - ">="
|
222
222
|
- !ruby/object:Gem::Version
|
223
|
-
version:
|
223
|
+
version: 0.7.1
|
224
224
|
type: :development
|
225
225
|
version_requirements: *id019
|
226
|
+
- !ruby/object:Gem::Dependency
|
227
|
+
name: tilt
|
228
|
+
prerelease: false
|
229
|
+
requirement: &id020 !ruby/object:Gem::Requirement
|
230
|
+
none: false
|
231
|
+
requirements:
|
232
|
+
- - ">="
|
233
|
+
- !ruby/object:Gem::Version
|
234
|
+
version: 1.2.2
|
235
|
+
type: :development
|
236
|
+
version_requirements: *id020
|
237
|
+
- !ruby/object:Gem::Dependency
|
238
|
+
name: haml
|
239
|
+
prerelease: false
|
240
|
+
requirement: &id021 !ruby/object:Gem::Requirement
|
241
|
+
none: false
|
242
|
+
requirements:
|
243
|
+
- - ">="
|
244
|
+
- !ruby/object:Gem::Version
|
245
|
+
version: 3.0.25
|
246
|
+
type: :development
|
247
|
+
version_requirements: *id021
|
248
|
+
- !ruby/object:Gem::Dependency
|
249
|
+
name: yard
|
250
|
+
prerelease: false
|
251
|
+
requirement: &id022 !ruby/object:Gem::Requirement
|
252
|
+
none: false
|
253
|
+
requirements:
|
254
|
+
- - ">="
|
255
|
+
- !ruby/object:Gem::Version
|
256
|
+
version: "0"
|
257
|
+
type: :development
|
258
|
+
version_requirements: *id022
|
259
|
+
- !ruby/object:Gem::Dependency
|
260
|
+
name: bluecloth
|
261
|
+
prerelease: false
|
262
|
+
requirement: &id023 !ruby/object:Gem::Requirement
|
263
|
+
none: false
|
264
|
+
requirements:
|
265
|
+
- - ">="
|
266
|
+
- !ruby/object:Gem::Version
|
267
|
+
version: "0"
|
268
|
+
type: :development
|
269
|
+
version_requirements: *id023
|
226
270
|
description: Framework for writing API servers
|
227
271
|
email:
|
228
272
|
- dj2@everburning.com
|
@@ -234,34 +278,95 @@ extensions: []
|
|
234
278
|
extra_rdoc_files: []
|
235
279
|
|
236
280
|
files:
|
237
|
-
- .
|
238
|
-
- .
|
239
|
-
- .
|
240
|
-
- .
|
241
|
-
-
|
242
|
-
- LICENSE
|
243
|
-
- README.
|
244
|
-
-
|
281
|
+
- doc/_index.html
|
282
|
+
- doc/class_list.html
|
283
|
+
- doc/css/common.css
|
284
|
+
- doc/css/full_list.css
|
285
|
+
- doc/css/style.css
|
286
|
+
- doc/file.LICENSE.html
|
287
|
+
- doc/file.README.html
|
288
|
+
- doc/file_list.html
|
289
|
+
- doc/frames.html
|
290
|
+
- doc/Goliath/API.html
|
291
|
+
- doc/Goliath/Constants.html
|
292
|
+
- doc/Goliath/Env.html
|
293
|
+
- doc/Goliath/Plugin/Latency.html
|
294
|
+
- doc/Goliath/Plugin.html
|
295
|
+
- doc/Goliath/Rack/AsyncMiddleware.html
|
296
|
+
- doc/Goliath/Rack/Builder.html
|
297
|
+
- doc/Goliath/Rack/DefaultMimeType.html
|
298
|
+
- doc/Goliath/Rack/DefaultResponseFormat.html
|
299
|
+
- doc/Goliath/Rack/Formatters/HTML.html
|
300
|
+
- doc/Goliath/Rack/Formatters/JSON.html
|
301
|
+
- doc/Goliath/Rack/Formatters/XML.html
|
302
|
+
- doc/Goliath/Rack/Formatters/YAML.html
|
303
|
+
- doc/Goliath/Rack/Formatters.html
|
304
|
+
- doc/Goliath/Rack/Heartbeat.html
|
305
|
+
- doc/Goliath/Rack/JSONP.html
|
306
|
+
- doc/Goliath/Rack/Params.html
|
307
|
+
- doc/Goliath/Rack/Render.html
|
308
|
+
- doc/Goliath/Rack/Templates.html
|
309
|
+
- doc/Goliath/Rack/Tracer.html
|
310
|
+
- doc/Goliath/Rack/Validation/BooleanValue.html
|
311
|
+
- doc/Goliath/Rack/Validation/DefaultParams.html
|
312
|
+
- doc/Goliath/Rack/Validation/NumericRange.html
|
313
|
+
- doc/Goliath/Rack/Validation/RequestMethod.html
|
314
|
+
- doc/Goliath/Rack/Validation/RequiredParam.html
|
315
|
+
- doc/Goliath/Rack/Validation/RequiredValue.html
|
316
|
+
- doc/Goliath/Rack/Validation.html
|
317
|
+
- doc/Goliath/Rack/Validator.html
|
318
|
+
- doc/Goliath/Rack.html
|
319
|
+
- doc/Goliath/Runner.html
|
320
|
+
- doc/Goliath/TestHelper.html
|
321
|
+
- doc/Goliath/Validation/Error.html
|
322
|
+
- doc/Goliath/Validation.html
|
323
|
+
- doc/Goliath.html
|
324
|
+
- doc/index.html
|
325
|
+
- doc/js/app.js
|
326
|
+
- doc/js/full_list.js
|
327
|
+
- doc/js/jquery.js
|
328
|
+
- doc/method_list.html
|
329
|
+
- doc/top-level-namespace.html
|
245
330
|
- examples/activerecord/config/srv.rb
|
246
331
|
- examples/activerecord/srv.rb
|
332
|
+
- examples/async_aroundware_demo.rb
|
247
333
|
- examples/async_upload.rb
|
334
|
+
- examples/auth_and_rate_limit.rb
|
335
|
+
- examples/chunked_streaming.rb
|
248
336
|
- examples/conf_test.rb
|
337
|
+
- examples/config/auth_and_rate_limit.rb
|
249
338
|
- examples/config/conf_test.rb
|
250
339
|
- examples/config/content_stream.rb
|
251
340
|
- examples/config/echo.rb
|
252
341
|
- examples/config/http_log.rb
|
253
342
|
- examples/config/shared.rb
|
343
|
+
- examples/config/template.rb
|
254
344
|
- examples/content_stream.rb
|
255
345
|
- examples/custom_server.rb
|
256
346
|
- examples/echo.rb
|
347
|
+
- examples/env_use_statements.rb
|
348
|
+
- examples/Gemfile.lock
|
257
349
|
- examples/gziped.rb
|
258
350
|
- examples/hello_world.rb
|
259
351
|
- examples/http_log.rb
|
352
|
+
- examples/public/stylesheets/style.css
|
260
353
|
- examples/rack_routes.rb
|
354
|
+
- examples/rasterize/rasterize.js
|
355
|
+
- examples/rasterize/rasterize.rb
|
356
|
+
- examples/rasterize/rasterize_and_shorten.rb
|
357
|
+
- examples/rasterize/thumb/f7ad4cb03e5bfd0e2c43db8e598fb3cd.png
|
261
358
|
- examples/stream.rb
|
359
|
+
- examples/template.rb
|
360
|
+
- examples/test_rig.rb
|
262
361
|
- examples/valid.rb
|
362
|
+
- examples/views/debug.haml
|
363
|
+
- examples/views/joke.markdown
|
364
|
+
- examples/views/layout.erb
|
365
|
+
- examples/views/layout.haml
|
366
|
+
- examples/views/root.haml
|
367
|
+
- Gemfile
|
263
368
|
- goliath.gemspec
|
264
|
-
-
|
369
|
+
- HISTORY
|
265
370
|
- lib/goliath/api.rb
|
266
371
|
- lib/goliath/application.rb
|
267
372
|
- lib/goliath/connection.rb
|
@@ -271,15 +376,22 @@ files:
|
|
271
376
|
- lib/goliath/headers.rb
|
272
377
|
- lib/goliath/http_status_codes.rb
|
273
378
|
- lib/goliath/plugins/latency.rb
|
379
|
+
- lib/goliath/rack/async_aroundware.rb
|
380
|
+
- lib/goliath/rack/async_middleware.rb
|
381
|
+
- lib/goliath/rack/builder.rb
|
274
382
|
- lib/goliath/rack/default_mime_type.rb
|
275
383
|
- lib/goliath/rack/default_response_format.rb
|
276
384
|
- lib/goliath/rack/formatters/html.rb
|
277
385
|
- lib/goliath/rack/formatters/json.rb
|
386
|
+
- lib/goliath/rack/formatters/plist.rb
|
278
387
|
- lib/goliath/rack/formatters/xml.rb
|
388
|
+
- lib/goliath/rack/formatters/yaml.rb
|
389
|
+
- lib/goliath/rack/formatters.rb
|
279
390
|
- lib/goliath/rack/heartbeat.rb
|
280
391
|
- lib/goliath/rack/jsonp.rb
|
281
392
|
- lib/goliath/rack/params.rb
|
282
393
|
- lib/goliath/rack/render.rb
|
394
|
+
- lib/goliath/rack/templates.rb
|
283
395
|
- lib/goliath/rack/tracer.rb
|
284
396
|
- lib/goliath/rack/validation/boolean_value.rb
|
285
397
|
- lib/goliath/rack/validation/default_params.rb
|
@@ -287,28 +399,47 @@ files:
|
|
287
399
|
- lib/goliath/rack/validation/request_method.rb
|
288
400
|
- lib/goliath/rack/validation/required_param.rb
|
289
401
|
- lib/goliath/rack/validation/required_value.rb
|
290
|
-
- lib/goliath/rack/
|
402
|
+
- lib/goliath/rack/validation.rb
|
403
|
+
- lib/goliath/rack/validator.rb
|
404
|
+
- lib/goliath/rack.rb
|
291
405
|
- lib/goliath/request.rb
|
292
406
|
- lib/goliath/response.rb
|
293
407
|
- lib/goliath/runner.rb
|
294
408
|
- lib/goliath/server.rb
|
409
|
+
- lib/goliath/synchrony/mongo_receiver.rb
|
410
|
+
- lib/goliath/synchrony/response_receiver.rb
|
295
411
|
- lib/goliath/test_helper.rb
|
412
|
+
- lib/goliath/validation/error.rb
|
413
|
+
- lib/goliath/validation/standard_http_errors.rb
|
414
|
+
- lib/goliath/validation.rb
|
296
415
|
- lib/goliath/version.rb
|
416
|
+
- lib/goliath.rb
|
417
|
+
- LICENSE
|
418
|
+
- pkg/goliath-0.9.1.gem
|
419
|
+
- Rakefile
|
420
|
+
- README.md
|
297
421
|
- spec/integration/async_request_processing.rb
|
298
422
|
- spec/integration/echo_spec.rb
|
299
423
|
- spec/integration/empty_body_spec.rb
|
300
424
|
- spec/integration/http_log_spec.rb
|
301
425
|
- spec/integration/keepalive_spec.rb
|
302
426
|
- spec/integration/pipelining_spec.rb
|
427
|
+
- spec/integration/rack_routes_spec.rb
|
303
428
|
- spec/integration/reloader_spec.rb
|
429
|
+
- spec/integration/template_spec.rb
|
430
|
+
- spec/integration/trace_spec.rb
|
304
431
|
- spec/integration/valid_spec.rb
|
305
432
|
- spec/spec_helper.rb
|
433
|
+
- spec/unit/api_spec.rb
|
306
434
|
- spec/unit/connection_spec.rb
|
307
435
|
- spec/unit/env_spec.rb
|
308
436
|
- spec/unit/headers_spec.rb
|
437
|
+
- spec/unit/rack/builder_spec.rb
|
309
438
|
- spec/unit/rack/default_mime_type_spec.rb
|
310
439
|
- spec/unit/rack/formatters/json_spec.rb
|
440
|
+
- spec/unit/rack/formatters/plist_spec.rb
|
311
441
|
- spec/unit/rack/formatters/xml_spec.rb
|
442
|
+
- spec/unit/rack/formatters/yaml_spec.rb
|
312
443
|
- spec/unit/rack/heartbeat_spec.rb
|
313
444
|
- spec/unit/rack/params_spec.rb
|
314
445
|
- spec/unit/rack/render_spec.rb
|
@@ -318,11 +449,15 @@ files:
|
|
318
449
|
- spec/unit/rack/validation/request_method_spec.rb
|
319
450
|
- spec/unit/rack/validation/required_param_spec.rb
|
320
451
|
- spec/unit/rack/validation/required_value_spec.rb
|
321
|
-
- spec/unit/rack/validation_error_spec.rb
|
322
452
|
- spec/unit/request_spec.rb
|
323
453
|
- spec/unit/response_spec.rb
|
324
454
|
- spec/unit/runner_spec.rb
|
325
455
|
- spec/unit/server_spec.rb
|
456
|
+
- spec/unit/validation/standard_http_errors_spec.rb
|
457
|
+
- .gemtest
|
458
|
+
- .gitignore
|
459
|
+
- .rspec
|
460
|
+
- .yardopts
|
326
461
|
has_rdoc: true
|
327
462
|
homepage: http://labs.postrank.com/
|
328
463
|
licenses: []
|
@@ -358,15 +493,22 @@ test_files:
|
|
358
493
|
- spec/integration/http_log_spec.rb
|
359
494
|
- spec/integration/keepalive_spec.rb
|
360
495
|
- spec/integration/pipelining_spec.rb
|
496
|
+
- spec/integration/rack_routes_spec.rb
|
361
497
|
- spec/integration/reloader_spec.rb
|
498
|
+
- spec/integration/template_spec.rb
|
499
|
+
- spec/integration/trace_spec.rb
|
362
500
|
- spec/integration/valid_spec.rb
|
363
501
|
- spec/spec_helper.rb
|
502
|
+
- spec/unit/api_spec.rb
|
364
503
|
- spec/unit/connection_spec.rb
|
365
504
|
- spec/unit/env_spec.rb
|
366
505
|
- spec/unit/headers_spec.rb
|
506
|
+
- spec/unit/rack/builder_spec.rb
|
367
507
|
- spec/unit/rack/default_mime_type_spec.rb
|
368
508
|
- spec/unit/rack/formatters/json_spec.rb
|
509
|
+
- spec/unit/rack/formatters/plist_spec.rb
|
369
510
|
- spec/unit/rack/formatters/xml_spec.rb
|
511
|
+
- spec/unit/rack/formatters/yaml_spec.rb
|
370
512
|
- spec/unit/rack/heartbeat_spec.rb
|
371
513
|
- spec/unit/rack/params_spec.rb
|
372
514
|
- spec/unit/rack/render_spec.rb
|
@@ -376,8 +518,8 @@ test_files:
|
|
376
518
|
- spec/unit/rack/validation/request_method_spec.rb
|
377
519
|
- spec/unit/rack/validation/required_param_spec.rb
|
378
520
|
- spec/unit/rack/validation/required_value_spec.rb
|
379
|
-
- spec/unit/rack/validation_error_spec.rb
|
380
521
|
- spec/unit/request_spec.rb
|
381
522
|
- spec/unit/response_spec.rb
|
382
523
|
- spec/unit/runner_spec.rb
|
383
524
|
- spec/unit/server_spec.rb
|
525
|
+
- spec/unit/validation/standard_http_errors_spec.rb
|