@@ -65,43 +65,68 @@ jobs:
65
65
- name : Start MySQL
66
66
run : sudo /etc/init.d/mysql start
67
67
68
- - name : Run benchmarks
68
+ - name : Run MySQL benchmarks
69
+ if : github.event.issue.pull_request && !contains(github.event.comment.body, '!skipmysql')
69
70
run : |
70
- echo "## Default run" > benchmark.md
71
+ echo "## MySQL run" > benchmark-mysql .md
71
72
hyperfine --show-output --warmup 1 --export-markdown bench-mysql.md -n 'mysql-main' './bench-main -runs 2 -backend mysql' -n 'mysql-pr' './bench-pr -runs 2 -backend mysql'
73
+ cat bench-mysql.md >> benchmark-mysql.md
74
+
75
+ - name : Run SQLite benchmarks
76
+ if : github.event.issue.pull_request && !contains(github.event.comment.body, '!skipsqlite')
77
+ run : |
78
+ echo "## SQLite run" > benchmark-sqlite.md
72
79
hyperfine --show-output --warmup 1 --export-markdown bench-sqlite.md -n 'sqlite-main' './bench-main -runs 2 -backend sqlite' -n 'sqlite-pr' './bench-pr -runs 2 -backend sqlite'
80
+ cat bench-sqlite.md >> benchmark-sqlite.md
81
+
82
+ - name : Run Redis benchmarks
83
+ if : github.event.issue.pull_request && !contains(github.event.comment.body, '!skipredis')
84
+ run : |
85
+ echo "## Redis run" > benchmark-redis.md
73
86
hyperfine --show-output --warmup 1 --export-markdown bench-redis.md -n 'redis-main' './bench-main -runs 2 -backend redis' -n 'redis-pr' './bench-pr -runs 2 -backend redis'
74
- cat bench-mysql.md >> benchmark.md
75
- echo $'\n' >> benchmark.md
76
- cat bench-sqlite.md >> benchmark.md
77
- echo $'\n' >> benchmark.md
78
- cat bench-redis.md >> benchmark.md
79
-
80
- - name : Run large benchmarks
81
- if : github.event.issue.pull_request && contains(github.event.comment.body, '!large')
87
+ cat bench-redis.md >> benchmark-redis.md
88
+
89
+ - name : Run large MySQL benchmarks
90
+ if : github.event.issue.pull_request && !contains(github.event.comment.body, '!skipmysql') && contains(github.event.comment.body, '!large')
82
91
run : |
83
- echo "## Large payload run (1MB)" >> benchmark.md
92
+ echo "## Large MySQL payload run (1MB)" >> benchmark-mysql .md
84
93
hyperfine --show-output --warmup 1 --export-markdown bench-mysql-l.md -n 'mysql-main' './bench-main -resultsize 1000000 -activities 10 -runs 2 -backend mysql -timeout 240s' -n 'mysql-pr' './bench-pr -resultsize 1000000 -activities 10 -runs 2 -backend mysql -timeout 240s'
94
+ cat bench-mysql-l.md >> benchmark-mysql.md
95
+
96
+ - name : Run large SQLite benchmarks
97
+ if : github.event.issue.pull_request && !contains(github.event.comment.body, '!skipsqlite') && contains(github.event.comment.body, '!large')
98
+ run : |
99
+ echo "## Large SQLite payload run (1MB)" >> benchmark-sqlite.md
85
100
hyperfine --show-output --warmup 1 --export-markdown bench-sqlite-l.md -n 'sqlite-main' './bench-main -resultsize 1000000 -activities 10 -runs 2 -backend sqlite -timeout 240s' -n 'sqlite-pr' './bench-pr -resultsize 1000000 -activities 10 -runs 2 -backend sqlite -timeout 240s'
101
+ cat bench-sqlite-l.md >> benchmark-sqlite.md
102
+
103
+ - name : Run large Redis benchmarks
104
+ if : github.event.issue.pull_request && !contains(github.event.comment.body, '!skipredis') && contains(github.event.comment.body, '!large')
105
+ run : |
106
+ echo "## Large Redis payload run (1MB)" >> benchmark-redis.md
86
107
hyperfine --show-output --warmup 1 --export-markdown bench-redis-l.md -n 'redis-main' './bench-main -resultsize 1000000 -activities 10 -runs 2 -backend redis -timeout 240s' -n 'redis-pr' './bench-pr -resultsize 1000000 -activities 10 -runs 2 -backend redis -timeout 240s'
87
- cat bench-mysql-l.md >> benchmark.md
88
- echo $'\n' >> benchmark.md
89
- cat bench-sqlite-l.md >> benchmark.md
90
- echo $'\n' >> benchmark.md
91
- cat bench-redis-l.md >> benchmark.md
92
-
93
- - name : Run very large benchmarks
94
- if : github.event.issue.pull_request && contains(github.event.comment.body, '!verylarge')
108
+ cat bench-redis-l.md >> benchmark-redis.md
109
+
110
+ - name : Run very large MySQL benchmarks
111
+ if : github.event.issue.pull_request && !contains(github.event.comment.body, '!skipmysql') && contains(github.event.comment.body, '!verylarge')
95
112
run : |
96
- echo "## Very Large payload run (5MB)" >> benchmark.md
113
+ echo "## Very Large MySQL payload run (5MB)" >> benchmark-mysql .md
97
114
hyperfine --show-output --warmup 1 --export-markdown bench-mysql-vl.md -n 'mysql-main' './bench-main -resultsize 5000000 -runs 2 -backend mysql -timeout 240s' -n 'mysql-pr' './bench-pr -resultsize 5000000 -runs 2 -backend mysql -timeout 240s'
115
+ cat bench-mysql-vl.md >> benchmark-mysql.md
116
+
117
+ - name : Run very large SQLite benchmarks
118
+ if : github.event.issue.pull_request && !contains(github.event.comment.body, '!skipsqlite') && contains(github.event.comment.body, '!verylarge')
119
+ run : |
120
+ echo "## Very Large SQLite payload run (5MB)" >> benchmark-sqlite.md
98
121
hyperfine --show-output --warmup 1 --export-markdown bench-sqlite-vl.md -n 'sqlite-main' './bench-main -resultsize 5000000 -runs 2 -backend sqlite -timeout 240s' -n 'sqlite-pr' './bench-pr -resultsize 5000000 -runs 2 -backend sqlite -timeout 240s'
122
+ cat bench-sqlite-vl.md >> benchmark-sqlite.md
123
+
124
+ - name : Run very large Redis benchmarks
125
+ if : github.event.issue.pull_request && !contains(github.event.comment.body, '!skipredis') && contains(github.event.comment.body, '!verylarge')
126
+ run : |
127
+ echo "## Very Large Redis payload run (5MB)" >> benchmark-redis.md
99
128
hyperfine --show-output --warmup 1 --export-markdown bench-redis-vl.md -n 'redis-main' './bench-main -resultsize 5000000 -runs 2 -backend redis -timeout 240s' -n 'redis-pr' './bench-pr -resultsize 5000000 -runs 2 -backend redis -timeout 240s'
100
- cat bench-mysql-vl.md >> benchmark.md
101
- echo $'\n' >> benchmark.md
102
- cat bench-sqlite-vl.md >> benchmark.md
103
- echo $'\n' >> benchmark.md
104
- cat bench-redis-vl.md >> benchmark.md
129
+ cat bench-redis-vl.md >> benchmark-redis.md
105
130
106
131
- name : Write a new comment
107
132
uses : peter-evans/create-or-update-comment@v2
0 commit comments