-
Notifications
You must be signed in to change notification settings - Fork 1.2k
70 lines (61 loc) · 2.3 KB
/
benchmark.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
name: benchmark
on:
push:
paths-ignore:
- '**.md'
pull_request:
paths-ignore:
- '**.md'
jobs:
benchmark:
name: benchmark
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: prepare
run: |
sudo apt update
sudo apt install libssl-dev
sudo apt install iperf
sudo apt install nginx
- name: make examples
run: |
./configure
make examples
- name: build echo-servers
run: |
bash echo-servers/build.sh
- name: benchmark echo-servers
run: |
bash echo-servers/benchmark.sh
- name: benchmark tcp_proxy_server
run: |
iperf -s -p 5001 > /dev/null &
bin/tcp_proxy_server 1212 127.0.0.1:5001 &
iperf -c 127.0.0.1 -p 5001 -l 8K
iperf -c 127.0.0.1 -p 1212 -l 8K
- name: webbench
run: |
sudo nginx -c /etc/nginx/nginx.conf
sudo cp html/index.html index.html
sudo cp html/index.html /var/www/html/index.html
bin/httpd -c etc/httpd.conf -d
ps aux | grep nginx
ps aux | grep httpd
bin/tinyhttpd 9090 &
echo -e "\n======Test nginx send file==============================="
bin/wrk -c 100 -t 2 -d 10s http://127.0.0.1:80/
echo -e "\n======Test libhv/httpd send file (with FileCache)========"
bin/wrk -c 100 -t 2 -d 10s http://127.0.0.1:8080/
echo -e "\n======Test libhv/tinyhttpd send file (no FileCache)======"
bin/wrk -c 100 -t 2 -d 10s http://127.0.0.1:9090/
echo -e "\n======Test nginx 404 Not Found==========================="
bin/wrk -c 100 -t 2 -d 10s http://127.0.0.1:80/404
echo -e "\n======Test libhv/httpd 404 Not Found====================="
bin/wrk -c 100 -t 2 -d 10s http://127.0.0.1:8080/404
echo -e "\n======Test libhv/tinyhttpd 404 Not found================="
bin/wrk -c 100 -t 2 -d 10s http://127.0.0.1:9090/404
echo -e "\n======Test libhv/httpd /ping============================="
bin/wrk -c 100 -t 2 -d 10s http://127.0.0.1:8080/ping
echo -e "\n======Test libhv/tinyhttpd /ping========================="
bin/wrk -c 100 -t 2 -d 10s http://127.0.0.1:9090/ping