Benchmark #7
This file contains hidden or 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
| name: Benchmark | |
| on: | |
| workflow_dispatch: | |
| jobs: | |
| benchmark: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Build MinIO image | |
| run: docker build -t s3cpp-minio:latest . | |
| - name: Start MinIO server | |
| run: | | |
| docker run -d -p 9000:9000 -p 9001:9001 \ | |
| -e "MINIO_ROOT_USER=minio_access" \ | |
| -e "MINIO_ROOT_PASSWORD=minio_secret" \ | |
| --name minio-server \ | |
| s3cpp-minio:latest \ | |
| server /data --console-address ":9001" | |
| timeout 30 bash -c 'until curl -f http://localhost:9000/minio/health/live 2>/dev/null; do sleep 1; done' | |
| - name: Install GCC 14 | |
| run: | | |
| sudo apt-get update | |
| sudo apt-get install -y software-properties-common | |
| sudo add-apt-repository ppa:ubuntu-toolchain-r/test -y | |
| sudo apt-get update | |
| sudo apt-get install -y gcc-14 g++-14 cmake libcurl4-openssl-dev pkg-config | |
| sudo update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-14 100 | |
| sudo update-alternatives --install /usr/bin/g++ g++ /usr/bin/g++-14 100 | |
| - name: Install brew dependencies | |
| run: | | |
| eval "$(/home/linuxbrew/.linuxbrew/bin/brew shellenv)" | |
| echo "$(brew --prefix)/bin" >> $GITHUB_PATH | |
| echo "LD_LIBRARY_PATH=$(brew --prefix)/lib" >> $GITHUB_ENV | |
| brew install aws-sdk-cpp google-benchmark go rust | |
| - name: Build s3cpp | |
| run: | | |
| cmake -B build -DCMAKE_BUILD_TYPE=Release -DCMAKE_POSITION_INDEPENDENT_CODE=ON | |
| cmake --build build -j$(nproc) | |
| - name: Build benchmark SDKs | |
| working-directory: benchmark | |
| run: make | |
| - name: Run benchmark tests | |
| working-directory: benchmark | |
| run: make test | |
| - name: Run benchmarks | |
| working-directory: benchmark | |
| run: make bench | |
| - name: Stop MinIO server | |
| if: always() | |
| run: docker stop minio-server |