This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require 'rest-client' | |
class Reports | |
def initialize(host, args={}) | |
@host = host | |
@username = args[:username] || 'exampleuser' | |
@password = args[:password] || 'examplepass' | |
@foreman_host = args[:foreman_host] || 'http://foreman.example.com' | |
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
D:\www\apache-2.4.25\bin>ab.exe -n 10000 -c 10 http://localhost:8000/ | |
This is ApacheBench, Version 2.3 <$Revision: 1757674 $> | |
Copyright 1996 Adam Twiss, Zeus Technology Ltd, http://www.zeustech.net/ | |
Licensed to The Apache Software Foundation, http://www.apache.org/ | |
Benchmarking localhost (be patient) | |
Server Software: rocket | |
Server Hostname: localhost | |
Server Port: 8000 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
D:\www\apache-2.4.25\bin>ab.exe -n 10000 -c 10 http://localhost:8080/ | |
This is ApacheBench, Version 2.3 <$Revision: 1757674 $> | |
Copyright 1996 Adam Twiss, Zeus Technology Ltd, http://www.zeustech.net/ | |
Licensed to The Apache Software Foundation, http://www.apache.org/ | |
Benchmarking localhost (be patient) | |
Server Software: | |
Server Hostname: localhost | |
Server Port: 8080 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
D:\www\apache-2.4.25\bin>ab -n 10000 -c 10 http://localhost:8000/ | |
This is ApacheBench, Version 2.3 <$Revision: 1757674 $> | |
Copyright 1996 Adam Twiss, Zeus Technology Ltd, http://www.zeustech.net/ | |
Licensed to The Apache Software Foundation, http://www.apache.org/ | |
Benchmarking localhost (be patient) | |
Completed 1000 requests | |
Completed 2000 requests | |
Completed 3000 requests | |
Completed 4000 requests |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
D:\www\apache-2.4.25\bin>ab -n 10000 -c 10 http://127.0.0.1:8002/ | |
This is ApacheBench, Version 2.3 <$Revision: 1757674 $> | |
Copyright 1996 Adam Twiss, Zeus Technology Ltd, http://www.zeustech.net/ | |
Licensed to The Apache Software Foundation, http://www.apache.org/ | |
Benchmarking 127.0.0.1 (be patient) | |
Completed 1000 requests | |
Completed 2000 requests | |
Completed 3000 requests | |
Completed 4000 requests |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[sean:~/rust/rocket-api] $ ab -n 10000 -c 10 http://127.0.0.1:8000/ | |
This is ApacheBench, Version 2.3 <$Revision: 1706008 $> | |
Copyright 1996 Adam Twiss, Zeus Technology Ltd, http://www.zeustech.net/ | |
Licensed to The Apache Software Foundation, http://www.apache.org/ | |
Benchmarking 127.0.0.1 (be patient) | |
Completed 1000 requests | |
Completed 2000 requests | |
Completed 3000 requests | |
Completed 4000 requests |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[sean:~/rust/rocket-api] $ wrk -d1m http://127.0.0.1:8000/ | |
Running 1m test @ http://127.0.0.1:8000/ | |
2 threads and 10 connections | |
Thread Stats Avg Stdev Max +/- Stdev | |
Latency 106.75us 14.93us 1.92ms 83.38% | |
Req/Sec 36.25k 8.96k 47.49k 50.08% | |
4327977 requests in 1.00m, 602.61MB read | |
Requests/sec: 72133.75 | |
Transfer/sec: 10.04MB |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[sean:~/node/restify-api] $ wrk -d1m http://127.0.0.1:8080/ | |
Running 1m test @ http://127.0.0.1:8080/ | |
2 threads and 10 connections | |
Thread Stats Avg Stdev Max +/- Stdev | |
Latency 1.26ms 322.81us 22.70ms 93.94% | |
Req/Sec 4.02k 291.35 4.33k 91.08% | |
479768 requests in 1.00m, 67.26MB read | |
Requests/sec: 7996.19 | |
Transfer/sec: 1.12MB |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#![feature(plugin)] | |
#![plugin(rocket_codegen)] | |
extern crate rocket; | |
#[get("/")] | |
fn index() -> &'static str { | |
"Hello, world!" | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
"use strict"; | |
const restify = require('restify'); | |
const app = restify.createServer(); | |
app.use(restify.queryParser()); | |
app.use(restify.bodyParser()); | |
app.get('/', (req, res, next) => { | |
res.send('Hello, world!'); |
OlderNewer