mirror of
https://github.com/appwrite/appwrite
synced 2026-05-23 08:58:35 +00:00
feat: Adding ci/cd benchmark
This commit is contained in:
parent
62837eebbc
commit
4a265c52bd
1 changed files with 3 additions and 3 deletions
6
.github/workflows/benchmark.yml
vendored
6
.github/workflows/benchmark.yml
vendored
|
|
@ -18,19 +18,19 @@ jobs:
|
|||
sudo wget -O /usr/share/keyrings/azlux-archive-keyring.gpg https://azlux.fr/repo.gpg
|
||||
sudo apt update
|
||||
sudo apt install oha
|
||||
- name: Preparing environment
|
||||
- name: Prepare environment
|
||||
run: |
|
||||
sed -i 's/traefik/localhost/g' .env
|
||||
docker compose up -d
|
||||
sleep 10
|
||||
- name: Benchmark
|
||||
run: oha -z 180s http://localhost:9501/v1/health/version -j > benchmark.json
|
||||
run: oha -z 180s http://localhost/v1/health/version -j > benchmark.json
|
||||
- name: Prepare comment
|
||||
run: |
|
||||
echo '## :sparkles: Benchmark results' > benchmark.txt
|
||||
echo ' ' >> benchmark.txt
|
||||
echo "- :zap: Requests per second: $(jq -r '.summary.requestsPerSec|tonumber|floor' benchmark.json)" >> benchmark.txt
|
||||
echo "- :white_check_mark: Total 200 requests: $(jq -r '.statusCodeDistribution.200' benchmark.json)" >> benchmark.txt
|
||||
echo "- :white_check_mark: Total 200 requests: $(jq -r '.statusCodeDistribution."200"' benchmark.json)" >> benchmark.txt
|
||||
echo "- :top: 99 latency: $(jq -r '.latencyPercentiles.p99' benchmark.json )" >> benchmark.txt
|
||||
- name: Save results
|
||||
uses: actions/upload-artifact@v4
|
||||
|
|
|
|||
Loading…
Reference in a new issue