Skip to content

bench

bench #21

Workflow file for this run

name: bench
on: workflow_dispatch
jobs:
mix:
runs-on: ubuntu-latest
env:
MIX_ENV: bench
services:
clickhouse:
image: clickhouse/clickhouse-server:23.3.7.5-alpine
ports:
- 8123:8123
env:
options: >-
--health-cmd nc -zw3 localhost 8124
--health-interval 10s
--health-timeout 5s
--health-retries 5
steps:
- uses: actions/checkout@v3
- uses: erlef/setup-beam@v1
with:
elixir-version: "1.15"
otp-version: "26"
- uses: actions/cache@v3
with:
path: |
deps
_build
key: bench-ref-${{ github.head_ref || github.ref }}-mix-${{ hashFiles('**/mix.lock') }}
restore-keys: |
bench-ref-${{ github.head_ref || github.ref }}-mix-
bench-ref-refs/heads/master-mix-
- run: mix deps.get --only $MIX_ENV
- run: mix format --check-formatted
- run: mix compile --warnings-as-errors
- run: mkdir results
- run: mix run bench/insert.exs | tee results/insert.txt
- run: mix run bench/stream.exs | tee results/stream.txt
- uses: actions/upload-artifact@v3
with:
name: results
path: results/*.txt