puma 2.0.0.b2 → 2.0.0.b3
Sign up to get free protection for your applications and to get access to all the features.
Potentially problematic release.
This version of puma might be problematic. Click here for more details.
- data/History.txt +5 -0
- data/Manifest.txt +2 -37
- data/lib/puma/capistrano.rb +26 -0
- data/lib/puma/const.rb +1 -1
- data/lib/puma/daemon_ext.rb +20 -0
- data/puma.gemspec +3 -3
- metadata +7 -27
- data/examples/CA/cacert.pem +0 -23
- data/examples/CA/newcerts/cert_1.pem +0 -19
- data/examples/CA/newcerts/cert_2.pem +0 -19
- data/examples/CA/private/cakeypair.pem +0 -30
- data/examples/CA/serial +0 -1
- data/examples/config.rb +0 -5
- data/examples/puma/cert_puma.pem +0 -19
- data/examples/puma/csr_puma.pem +0 -11
- data/examples/puma/keystore.jks +0 -0
- data/examples/puma/puma_keypair.pem +0 -15
- data/examples/qc_config.rb +0 -13
- data/lib/puma/puma_http11.bundle +0 -0
- data/lib/puma/puma_http11.jar +0 -0
- data/test/ab_rs.rb +0 -22
- data/test/config/app.rb +0 -3
- data/test/hello-post.ru +0 -4
- data/test/hello.ru +0 -1
- data/test/lobster.ru +0 -4
- data/test/mime.yaml +0 -3
- data/test/slow.ru +0 -4
- data/test/testhelp.rb +0 -38
- data/tools/trickletest.rb +0 -45
data/History.txt
CHANGED
data/Manifest.txt
CHANGED
@@ -10,17 +10,6 @@ bin/puma
|
|
10
10
|
bin/pumactl
|
11
11
|
docs/config.md
|
12
12
|
docs/nginx.md
|
13
|
-
examples/CA/cacert.pem
|
14
|
-
examples/CA/newcerts/cert_1.pem
|
15
|
-
examples/CA/newcerts/cert_2.pem
|
16
|
-
examples/CA/private/cakeypair.pem
|
17
|
-
examples/CA/serial
|
18
|
-
examples/config.rb
|
19
|
-
examples/puma/cert_puma.pem
|
20
|
-
examples/puma/csr_puma.pem
|
21
|
-
examples/puma/keystore.jks
|
22
|
-
examples/puma/puma_keypair.pem
|
23
|
-
examples/qc_config.rb
|
24
13
|
ext/puma_http11/PumaHttp11Service.java
|
25
14
|
ext/puma_http11/ext_help.h
|
26
15
|
ext/puma_http11/extconf.rb
|
@@ -39,12 +28,14 @@ lib/puma.rb
|
|
39
28
|
lib/puma/accept_nonblock.rb
|
40
29
|
lib/puma/app/status.rb
|
41
30
|
lib/puma/binder.rb
|
31
|
+
lib/puma/capistrano.rb
|
42
32
|
lib/puma/cli.rb
|
43
33
|
lib/puma/client.rb
|
44
34
|
lib/puma/compat.rb
|
45
35
|
lib/puma/configuration.rb
|
46
36
|
lib/puma/const.rb
|
47
37
|
lib/puma/control_cli.rb
|
38
|
+
lib/puma/daemon_ext.rb
|
48
39
|
lib/puma/delegation.rb
|
49
40
|
lib/puma/detect.rb
|
50
41
|
lib/puma/events.rb
|
@@ -53,38 +44,12 @@ lib/puma/java_io_buffer.rb
|
|
53
44
|
lib/puma/jruby_restart.rb
|
54
45
|
lib/puma/minissl.rb
|
55
46
|
lib/puma/null_io.rb
|
56
|
-
lib/puma/puma_http11.bundle
|
57
|
-
lib/puma/puma_http11.jar
|
58
47
|
lib/puma/rack_patch.rb
|
59
48
|
lib/puma/reactor.rb
|
60
49
|
lib/puma/server.rb
|
61
50
|
lib/puma/thread_pool.rb
|
62
51
|
lib/rack/handler/puma.rb
|
63
52
|
puma.gemspec
|
64
|
-
test/ab_rs.rb
|
65
|
-
test/config/app.rb
|
66
|
-
test/hello-post.ru
|
67
|
-
test/hello.ru
|
68
|
-
test/lobster.ru
|
69
|
-
test/mime.yaml
|
70
|
-
test/slow.ru
|
71
|
-
test/test_app_status.rb
|
72
|
-
test/test_cli.rb
|
73
|
-
test/test_config.rb
|
74
|
-
test/test_http10.rb
|
75
|
-
test/test_http11.rb
|
76
|
-
test/test_integration.rb
|
77
|
-
test/test_iobuffer.rb
|
78
|
-
test/test_null_io.rb
|
79
|
-
test/test_persistent.rb
|
80
|
-
test/test_puma_server.rb
|
81
|
-
test/test_rack_handler.rb
|
82
|
-
test/test_rack_server.rb
|
83
|
-
test/test_thread_pool.rb
|
84
|
-
test/test_unix_socket.rb
|
85
|
-
test/test_ws.rb
|
86
|
-
test/testhelp.rb
|
87
53
|
tools/jungle/README.md
|
88
54
|
tools/jungle/puma
|
89
55
|
tools/jungle/run-puma
|
90
|
-
tools/trickletest.rb
|
@@ -0,0 +1,26 @@
|
|
1
|
+
Capistrano::Configuration.instance.load do
|
2
|
+
after "deploy:stop", "puma:stop"
|
3
|
+
after "deploy:start", "puma:start"
|
4
|
+
after "deploy:restart", "puma:restart"
|
5
|
+
|
6
|
+
_cset(:puma_role) { :app }
|
7
|
+
|
8
|
+
namespace :puma do
|
9
|
+
desc "Start puma"
|
10
|
+
task :start, :roles => lambda { fetch(:puma_role) }, :on_no_matching_servers => :continue do
|
11
|
+
puma_env = fetch(:rack_env, fetch(:rails_env, "production"))
|
12
|
+
run "cd #{current_path} && #{fetch(:bundle_cmd, "bundle")} exec puma -d -e #{puma_env} -b 'unix://#{shared_path}/sockets/puma.sock' -S #{shared_path}/sockets/puma.state --control 'unix://#{shared_path}/sockets/pumactl.sock'", :pty => false
|
13
|
+
end
|
14
|
+
|
15
|
+
desc "Stop puma"
|
16
|
+
task :stop, :roles => lambda { fetch(:puma_role) }, :on_no_matching_servers => :continue do
|
17
|
+
run "cd #{current_path} && #{fetch(:bundle_cmd, "bundle")} exec pumactl -S #{shared_path}/sockets/puma.state stop"
|
18
|
+
end
|
19
|
+
|
20
|
+
desc "Restart puma"
|
21
|
+
task :restart, :roles => lambda { fetch(:puma_role) }, :on_no_matching_servers => :continue do
|
22
|
+
run "cd #{current_path} && #{fetch(:bundle_cmd, "bundle")} exec pumactl -S #{shared_path}/sockets/puma.state restart"
|
23
|
+
end
|
24
|
+
|
25
|
+
end
|
26
|
+
end
|
data/lib/puma/const.rb
CHANGED
@@ -0,0 +1,20 @@
|
|
1
|
+
module Process
|
2
|
+
def self.daemon(nochdir=false, noclose=false)
|
3
|
+
exit if fork # Parent exits, child continues.
|
4
|
+
|
5
|
+
Process.setsid # Become session leader.
|
6
|
+
|
7
|
+
exit if fork # Zap session leader. See [1].
|
8
|
+
|
9
|
+
Dir.chdir "/" unless nochdir # Release old working directory.
|
10
|
+
|
11
|
+
if !noclose
|
12
|
+
null = File.open "/dev/null"
|
13
|
+
STDIN.reopen null
|
14
|
+
STDOUT.reopen null
|
15
|
+
STDERR.reopen null
|
16
|
+
end
|
17
|
+
|
18
|
+
0
|
19
|
+
end unless respond_to?(:daemon)
|
20
|
+
end
|
data/puma.gemspec
CHANGED
@@ -2,17 +2,17 @@
|
|
2
2
|
|
3
3
|
Gem::Specification.new do |s|
|
4
4
|
s.name = "puma"
|
5
|
-
s.version = "2.0.0.
|
5
|
+
s.version = "2.0.0.b3"
|
6
6
|
|
7
7
|
s.required_rubygems_version = Gem::Requirement.new("> 1.3.1") if s.respond_to? :required_rubygems_version=
|
8
8
|
s.authors = ["Evan Phoenix"]
|
9
|
-
s.date = "2012-11-
|
9
|
+
s.date = "2012-11-22"
|
10
10
|
s.description = "Puma is a simple, fast, and highly concurrent HTTP 1.1 server for Ruby web applications. It can be used with any application that supports Rack, and is considered the replacement for Webrick and Mongrel. It was designed to be the go-to server for [Rubinius](http://rubini.us), but also works well with JRuby and MRI. Puma is intended for use in both development and production environments.\n\nUnder the hood, Puma processes requests using a C-optimized Ragel extension (inherited from Mongrel) that provides fast, accurate HTTP 1.1 protocol parsing in a portable way. Puma then serves the request in a thread from an internal thread pool (which you can control). This allows Puma to provide real concurrency for your web application!\n\nWith Rubinius 2.0, Puma will utilize all cores on your CPU with real threads, meaning you won't have to spawn multiple processes to increase throughput. You can expect to see a similar benefit from JRuby.\n\nOn MRI, there is a Global Interpreter Lock (GIL) that ensures only one thread can be run at a time. But if you're doing a lot of blocking IO (such as HTTP calls to external APIs like Twitter), Puma still improves MRI's throughput by allowing blocking IO to be run concurrently (EventMachine-based servers such as Thin turn off this ability, requiring you to use special libraries). Your mileage may vary. In order to get the best throughput, it is highly recommended that you use a Ruby implementation with real threads like [Rubinius](http://rubini.us) or [JRuby](http://jruby.org)."
|
11
11
|
s.email = ["evan@phx.io"]
|
12
12
|
s.executables = ["puma", "pumactl"]
|
13
13
|
s.extensions = ["ext/puma_http11/extconf.rb"]
|
14
14
|
s.extra_rdoc_files = ["History.txt", "Manifest.txt"]
|
15
|
-
s.files = ["COPYING", "Gemfile", "History.txt", "LICENSE", "Manifest.txt", "README.md", "Rakefile", "TODO", "bin/puma", "bin/pumactl", "docs/config.md", "docs/nginx.md", "
|
15
|
+
s.files = ["COPYING", "Gemfile", "History.txt", "LICENSE", "Manifest.txt", "README.md", "Rakefile", "TODO", "bin/puma", "bin/pumactl", "docs/config.md", "docs/nginx.md", "ext/puma_http11/PumaHttp11Service.java", "ext/puma_http11/ext_help.h", "ext/puma_http11/extconf.rb", "ext/puma_http11/http11_parser.c", "ext/puma_http11/http11_parser.h", "ext/puma_http11/http11_parser.java.rl", "ext/puma_http11/http11_parser.rl", "ext/puma_http11/http11_parser_common.rl", "ext/puma_http11/io_buffer.c", "ext/puma_http11/mini_ssl.c", "ext/puma_http11/org/jruby/puma/Http11.java", "ext/puma_http11/org/jruby/puma/Http11Parser.java", "ext/puma_http11/org/jruby/puma/MiniSSL.java", "ext/puma_http11/puma_http11.c", "lib/puma.rb", "lib/puma/accept_nonblock.rb", "lib/puma/app/status.rb", "lib/puma/binder.rb", "lib/puma/capistrano.rb", "lib/puma/cli.rb", "lib/puma/client.rb", "lib/puma/compat.rb", "lib/puma/configuration.rb", "lib/puma/const.rb", "lib/puma/control_cli.rb", "lib/puma/daemon_ext.rb", "lib/puma/delegation.rb", "lib/puma/detect.rb", "lib/puma/events.rb", "lib/puma/io_buffer.rb", "lib/puma/java_io_buffer.rb", "lib/puma/jruby_restart.rb", "lib/puma/minissl.rb", "lib/puma/null_io.rb", "lib/puma/rack_patch.rb", "lib/puma/reactor.rb", "lib/puma/server.rb", "lib/puma/thread_pool.rb", "lib/rack/handler/puma.rb", "puma.gemspec", "tools/jungle/README.md", "tools/jungle/puma", "tools/jungle/run-puma", "test/test_app_status.rb", "test/test_cli.rb", "test/test_config.rb", "test/test_http10.rb", "test/test_http11.rb", "test/test_integration.rb", "test/test_iobuffer.rb", "test/test_null_io.rb", "test/test_persistent.rb", "test/test_puma_server.rb", "test/test_rack_handler.rb", "test/test_rack_server.rb", "test/test_thread_pool.rb", "test/test_unix_socket.rb", "test/test_ws.rb"]
|
16
16
|
s.homepage = "http://puma.io"
|
17
17
|
s.rdoc_options = ["--main", "README.md"]
|
18
18
|
s.require_paths = ["lib"]
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: puma
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.0.0.
|
4
|
+
version: 2.0.0.b3
|
5
5
|
prerelease: 6
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2012-11-
|
12
|
+
date: 2012-11-22 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: rack
|
@@ -123,17 +123,6 @@ files:
|
|
123
123
|
- bin/pumactl
|
124
124
|
- docs/config.md
|
125
125
|
- docs/nginx.md
|
126
|
-
- examples/CA/cacert.pem
|
127
|
-
- examples/CA/newcerts/cert_1.pem
|
128
|
-
- examples/CA/newcerts/cert_2.pem
|
129
|
-
- examples/CA/private/cakeypair.pem
|
130
|
-
- examples/CA/serial
|
131
|
-
- examples/config.rb
|
132
|
-
- examples/puma/cert_puma.pem
|
133
|
-
- examples/puma/csr_puma.pem
|
134
|
-
- examples/puma/keystore.jks
|
135
|
-
- examples/puma/puma_keypair.pem
|
136
|
-
- examples/qc_config.rb
|
137
126
|
- ext/puma_http11/PumaHttp11Service.java
|
138
127
|
- ext/puma_http11/ext_help.h
|
139
128
|
- ext/puma_http11/extconf.rb
|
@@ -152,12 +141,14 @@ files:
|
|
152
141
|
- lib/puma/accept_nonblock.rb
|
153
142
|
- lib/puma/app/status.rb
|
154
143
|
- lib/puma/binder.rb
|
144
|
+
- lib/puma/capistrano.rb
|
155
145
|
- lib/puma/cli.rb
|
156
146
|
- lib/puma/client.rb
|
157
147
|
- lib/puma/compat.rb
|
158
148
|
- lib/puma/configuration.rb
|
159
149
|
- lib/puma/const.rb
|
160
150
|
- lib/puma/control_cli.rb
|
151
|
+
- lib/puma/daemon_ext.rb
|
161
152
|
- lib/puma/delegation.rb
|
162
153
|
- lib/puma/detect.rb
|
163
154
|
- lib/puma/events.rb
|
@@ -166,21 +157,15 @@ files:
|
|
166
157
|
- lib/puma/jruby_restart.rb
|
167
158
|
- lib/puma/minissl.rb
|
168
159
|
- lib/puma/null_io.rb
|
169
|
-
- lib/puma/puma_http11.bundle
|
170
|
-
- lib/puma/puma_http11.jar
|
171
160
|
- lib/puma/rack_patch.rb
|
172
161
|
- lib/puma/reactor.rb
|
173
162
|
- lib/puma/server.rb
|
174
163
|
- lib/puma/thread_pool.rb
|
175
164
|
- lib/rack/handler/puma.rb
|
176
165
|
- puma.gemspec
|
177
|
-
-
|
178
|
-
-
|
179
|
-
-
|
180
|
-
- test/hello.ru
|
181
|
-
- test/lobster.ru
|
182
|
-
- test/mime.yaml
|
183
|
-
- test/slow.ru
|
166
|
+
- tools/jungle/README.md
|
167
|
+
- tools/jungle/puma
|
168
|
+
- tools/jungle/run-puma
|
184
169
|
- test/test_app_status.rb
|
185
170
|
- test/test_cli.rb
|
186
171
|
- test/test_config.rb
|
@@ -196,11 +181,6 @@ files:
|
|
196
181
|
- test/test_thread_pool.rb
|
197
182
|
- test/test_unix_socket.rb
|
198
183
|
- test/test_ws.rb
|
199
|
-
- test/testhelp.rb
|
200
|
-
- tools/jungle/README.md
|
201
|
-
- tools/jungle/puma
|
202
|
-
- tools/jungle/run-puma
|
203
|
-
- tools/trickletest.rb
|
204
184
|
homepage: http://puma.io
|
205
185
|
licenses: []
|
206
186
|
post_install_message:
|
data/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3OlsVCnHYrDQ0cemhLOYPuiyKTtCUIs2nHuiM4RwoCRJgsVBUnKK+tTx
|
21
|
-
AkM9uQvYsrZ/DoBooBdXJQy3uiHH86zEskiy72H8Wgcu8GbLt2JgCyhXkwDzrIRf
|
22
|
-
hnAN4FS2VNOt5dDTVHBWG1vIxxlM2+LrYpY/QqihNgotZ+C4VWHkoDwbF478JgxM
|
23
|
-
5Yk+0X9kGvLQbZCJFXdAKAyr/AzRH+Hx1cDvSi7gypf8qOEZwD1rq7f0qw8jnqfG
|
24
|
-
3QIFoN1/+xTAV8lTlGhvbQYz1XHVBH9l7TSQDLIrnwHTIv+PdZbTveGftCCnLdDo
|
25
|
-
wBLBnw4mKVCtnHrEgXMQF62yuwueQ8zhdh8jf3osYV/COlRZwQQGgZtnQCeeyDIh
|
26
|
-
8GJR9b4uv22QDNv7J2vcqTEWJdnpAZvIBFGuCBCAgev+URLGW2ELXfWQwNgc5+yP
|
27
|
-
nGRXo+IwD1uhvEqtuin+cAn/sJhOa66g0ZcV/3AcrdQhbicn12YM71cMvA/XRKf5
|
28
|
-
rpo8bAEwDqyoFoywH4IHM3HNV45rS+brskz6tZC5ELondCPVmUqgVu7ELHlJfPXx
|
29
|
-
RbzbMPJEGr8WjWUiTDhrD2vWgoJ6NRKkDAUYm6KQb8Sbajd2JAAlYntLz5jKqNqN
|
30
|
-
-----END RSA PRIVATE KEY-----
|
data/examples/CA/serial
DELETED
@@ -1 +0,0 @@
|
|
1
|
-
0003
|
data/examples/config.rb
DELETED
data/examples/puma/cert_puma.pem
DELETED
@@ -1,19 +0,0 @@
|
|
1
|
-
-----BEGIN CERTIFICATE-----
|
2
|
-
MIIC/jCCAeagAwIBAgIBAjANBgkqhkiG9w0BAQUFADA5MQswCQYDVQQGEwJVUzEO
|
3
|
-
MAwGA1UECgwFbG9jYWwxDTALBgNVBAsMBGFlcm8xCzAJBgNVBAMMAkNBMB4XDTEy
|
4
|
-
MDExNDAwMjcyN1oXDTEzMDExMzAwMjcy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
|
|
1
|
-
-----BEGIN CERTIFICATE REQUEST-----
|
2
|
-
MIIBhzCB8QIBADBIMQswCQYDVQQGEwJVUzEOMAwGA1UECgwFbG9jYWwxDTALBgNV
|
3
|
-
BAsMBGFlcm8xCzAJBgNVBAsMAkNBMQ0wCwYDVQQDDARwdW1hMIGfMA0GCSqGSIb3
|
4
|
-
DQEBAQUAA4GNADCBiQKBgQCvF80yn6D+kqGwMSQHcpHUwCRt+c39Qoy99fCWdenP
|
5
|
-
thfUscecy62Ij8+rKYCnoE9y766a5baowdDKqq3IBOZn2Ove3zfueGbHAbWehFop
|
6
|
-
G2xySf0UPjdmWk+DRDlCeFLig6xfAnOKWo+N0MViso3dNK8gYzb6FWqlWgZgAcMp
|
7
|
-
swIDAQABoAAwDQYJKoZIhvcNAQEEBQADgYEAmRsmIQ0pF9iPOO7V1NeHxrVpFz1B
|
8
|
-
CZK0yAIGlCWqzpFO/OILN1hJfFnsFl7hZWipoARk15fN1sSXQF3Xb7/sc/8qVhyz
|
9
|
-
oY38uu/8CE9CTdUutniLzP/4sUomXjslKNVV0qKtmfsFkj2tHtWjJkGAyZUcoKeG
|
10
|
-
hDJxQlIHhZa7Xvw=
|
11
|
-
-----END CERTIFICATE REQUEST-----
|
data/examples/puma/keystore.jks
DELETED
Binary file
|
@@ -1,15 +0,0 @@
|
|
1
|
-
-----BEGIN RSA PRIVATE KEY-----
|
2
|
-
MIICXQIBAAKBgQCvF80yn6D+kqGwMSQHcpHUwCRt+c39Qoy99fCWdenPthfUscec
|
3
|
-
y62Ij8+rKYCnoE9y766a5baowdDKqq3IBOZn2Ove3zfueGbHAbWehFopG2xySf0U
|
4
|
-
PjdmWk+DRDlCeFLig6xfAnOKWo+N0MViso3dNK8gYzb6FWqlWgZgAcMpswIDAQAB
|
5
|
-
AoGAHv/UyZivdULas4oPue3T2dnm2T239ZXZuywW21ym96pij7ql/6Gj6KClgMVJ
|
6
|
-
TOQ6DLxYqn3vF/OwlqEfQWF0tTUYY+xNbEDE1YsbrS5/FSzbaEYYOHzRl/vMmnsf
|
7
|
-
aNgYaSjOIecin7L71Wzq0piMIxg8BLb6IVECBku9EQNzxuECQQDZsbRgg1XZGj+r
|
8
|
-
XAu/qXTNKQ/r7k+iPN5bXON6ApBomG+4Q7VVITL3tkGzLOphRZ37Q28FrN4B4gtC
|
9
|
-
Xb9il5lDAkEAzecTSopPi2VdcME4WWmwn1rbTp/jJNt4dGZLsNfj9RejVDd32i/L
|
10
|
-
P7wCpoPDaaVcoF2HgvCs39qatyVg6ecu0QJBALN4q+q9nDMGTuNpWU5D2EWjyrqJ
|
11
|
-
mCF66R6NcASQxJlWwxQ4zfBHFIvgOD4Nk5VqHZqet5MIN2d6AipOu4/+x50CQHDp
|
12
|
-
jf+rd1GHBcXGf8MwnUXWCjvEnEhi/lw+mLVivsRx8QRG4rfIy9monX949Flj8DaU
|
13
|
-
87IPj422kG9s1QeP2nECQQCkg+RUcoQm7SiM8OXuXNeHQlvQNp65geFRxzKAXxT/
|
14
|
-
+1Mbtwnd3AXXZBekFDDpE9U3ZQjahoe7oc1oUBuw5hXL
|
15
|
-
-----END RSA PRIVATE KEY-----
|
data/examples/qc_config.rb
DELETED
@@ -1,13 +0,0 @@
|
|
1
|
-
full_hostname = `hostname`.strip
|
2
|
-
domainname = full_hostname.split('.')[1..-1].join('.')
|
3
|
-
hostname = full_hostname.split('.')[0]
|
4
|
-
|
5
|
-
CA[:hostname] = hostname
|
6
|
-
CA[:domainname] = domainname
|
7
|
-
CA[:CA_dir] = File.join Dir.pwd, "CA"
|
8
|
-
CA[:password] = 'puma'
|
9
|
-
|
10
|
-
CERTS << {
|
11
|
-
:type => 'server',
|
12
|
-
:hostname => 'puma'
|
13
|
-
}
|
data/lib/puma/puma_http11.bundle
DELETED
Binary file
|
data/lib/puma/puma_http11.jar
DELETED
Binary file
|
data/test/ab_rs.rb
DELETED
@@ -1,22 +0,0 @@
|
|
1
|
-
url = ARGV.shift
|
2
|
-
count = (ARGV.shift || 1000).to_i
|
3
|
-
|
4
|
-
STDOUT.sync = true
|
5
|
-
|
6
|
-
1.upto(5) do |i|
|
7
|
-
print "#{i}: "
|
8
|
-
str = `ab -n #{count} -c #{i} #{url} 2>/dev/null`
|
9
|
-
|
10
|
-
rs = /Requests per second:\s+([\d.]+)\s/.match(str)
|
11
|
-
puts rs[1]
|
12
|
-
end
|
13
|
-
|
14
|
-
puts "Keep Alive:"
|
15
|
-
|
16
|
-
1.upto(5) do |i|
|
17
|
-
print "#{i}: "
|
18
|
-
str = `ab -n #{count} -k -c #{i} #{url} 2>/dev/null`
|
19
|
-
|
20
|
-
rs = /Requests per second:\s+([\d.]+)\s/.match(str)
|
21
|
-
puts rs[1]
|
22
|
-
end
|
data/test/config/app.rb
DELETED
data/test/hello-post.ru
DELETED
data/test/hello.ru
DELETED
@@ -1 +0,0 @@
|
|
1
|
-
run lambda { |env| [200, {"Content-Type" => "text/plain"}, ["Hello World"]] }
|
data/test/lobster.ru
DELETED
data/test/mime.yaml
DELETED
data/test/slow.ru
DELETED
data/test/testhelp.rb
DELETED
@@ -1,38 +0,0 @@
|
|
1
|
-
# Copyright (c) 2011 Evan Phoenix
|
2
|
-
# Copyright (c) 2005 Zed A. Shaw
|
3
|
-
|
4
|
-
|
5
|
-
%w(lib test).each do |d|
|
6
|
-
dir = File.expand_path("../../#{d}", __FILE__)
|
7
|
-
$LOAD_PATH.unshift dir unless $LOAD_PATH.include?(dir)
|
8
|
-
end
|
9
|
-
|
10
|
-
require 'rubygems'
|
11
|
-
require 'test/unit'
|
12
|
-
require 'net/http'
|
13
|
-
require 'digest/sha1'
|
14
|
-
require 'uri'
|
15
|
-
require 'stringio'
|
16
|
-
|
17
|
-
require 'puma'
|
18
|
-
|
19
|
-
# Either takes a string to do a get request against, or a tuple of [URI, HTTP] where
|
20
|
-
# HTTP is some kind of Net::HTTP request object (POST, HEAD, etc.)
|
21
|
-
def hit(uris)
|
22
|
-
results = []
|
23
|
-
uris.each do |u|
|
24
|
-
res = nil
|
25
|
-
|
26
|
-
if u.kind_of? String
|
27
|
-
res = Net::HTTP.get(URI.parse(u))
|
28
|
-
else
|
29
|
-
url = URI.parse(u[0])
|
30
|
-
res = Net::HTTP.new(url.host, url.port).start {|h| h.request(u[1]) }
|
31
|
-
end
|
32
|
-
|
33
|
-
assert res != nil, "Didn't get a response: #{u}"
|
34
|
-
results << res
|
35
|
-
end
|
36
|
-
|
37
|
-
return results
|
38
|
-
end
|
data/tools/trickletest.rb
DELETED
@@ -1,45 +0,0 @@
|
|
1
|
-
require 'socket'
|
2
|
-
require 'stringio'
|
3
|
-
|
4
|
-
def do_test(st, chunk)
|
5
|
-
s = TCPSocket.new('127.0.0.1',ARGV[0].to_i);
|
6
|
-
req = StringIO.new(st)
|
7
|
-
nout = 0
|
8
|
-
randstop = rand(st.length / 10)
|
9
|
-
STDERR.puts "stopping after: #{randstop}"
|
10
|
-
|
11
|
-
begin
|
12
|
-
while data = req.read(chunk)
|
13
|
-
nout += s.write(data)
|
14
|
-
s.flush
|
15
|
-
sleep 0.1
|
16
|
-
if nout > randstop
|
17
|
-
STDERR.puts "BANG! after #{nout} bytes."
|
18
|
-
break
|
19
|
-
end
|
20
|
-
end
|
21
|
-
rescue Object => e
|
22
|
-
STDERR.puts "ERROR: #{e}"
|
23
|
-
ensure
|
24
|
-
s.close
|
25
|
-
end
|
26
|
-
end
|
27
|
-
|
28
|
-
content = "-" * (1024 * 240)
|
29
|
-
st = "GET / HTTP/1.1\r\nHost: www.zedshaw.com\r\nContent-Type: text/plain\r\nContent-Length: #{content.length}\r\n\r\n#{content}"
|
30
|
-
|
31
|
-
puts "length: #{content.length}"
|
32
|
-
|
33
|
-
threads = []
|
34
|
-
ARGV[1].to_i.times do
|
35
|
-
t = Thread.new do
|
36
|
-
size = 100
|
37
|
-
puts ">>>> #{size} sized chunks"
|
38
|
-
do_test(st, size)
|
39
|
-
end
|
40
|
-
|
41
|
-
t.abort_on_exception = true
|
42
|
-
threads << t
|
43
|
-
end
|
44
|
-
|
45
|
-
threads.each {|t| t.join}
|