This is an automated email from the ASF dual-hosted git repository.

twice pushed a commit to branch unstable
in repository https://gitbox.apache.org/repos/asf/kvrocks.git


The following commit(s) were added to refs/heads/unstable by this push:
     new a81fd2f6 ci: add an alpine-based build & test workflow (#2760)
a81fd2f6 is described below

commit a81fd2f6b96428e92c21b4e2804db111da3d27d7
Author: Twice <[email protected]>
AuthorDate: Sun Feb 2 13:42:59 2025 +0800

    ci: add an alpine-based build & test workflow (#2760)
---
 .github/workflows/kvrocks.yaml | 15 +++++++++++++--
 src/storage/redis_metadata.h   |  1 +
 2 files changed, 14 insertions(+), 2 deletions(-)

diff --git a/.github/workflows/kvrocks.yaml b/.github/workflows/kvrocks.yaml
index 521508d3..cc441af3 100644
--- a/.github/workflows/kvrocks.yaml
+++ b/.github/workflows/kvrocks.yaml
@@ -443,6 +443,10 @@ jobs:
           - name: Debian 12
             image: debian:12
             compiler: gcc
+          - name: Alpine 3
+            image: alpine:3
+            compiler: gcc
+            disable_jemalloc: -DDISABLE_JEMALLOC=ON
 
     runs-on: ubuntu-22.04
     container:
@@ -498,6 +502,13 @@ jobs:
           apt install -y bash build-essential cmake curl git libssl-dev 
libtool python3 python3-pip wget
           echo "NPROC=$(nproc)" >> $GITHUB_ENV
 
+      - name: Setup Alpine
+        if: ${{ startsWith(matrix.image, 'alpine') }}
+        run: |
+          apk update
+          apk add bash cmake curl git python3 wget make gcc g++ autoconf 
linux-headers py3-pip py3-redis
+          echo "NPROC=$(nproc)" >> $GITHUB_ENV
+
       - name: Cache redis
         id: cache-redis
         uses: actions/cache@v4
@@ -533,7 +544,7 @@ jobs:
 
       - name: Build Kvrocks
         run: |
-          ./x.py build -j$NPROC --unittest --compiler ${{ matrix.compiler }}
+          ./x.py build -j$NPROC --unittest --compiler ${{ matrix.compiler }} 
${{ matrix.disable_jemalloc }}
 
       - name: Run Unit Test
         run: |
@@ -546,7 +557,7 @@ jobs:
           ./x.py test go build $GOCASE_RUN_ARGS
 
       - name: Install redis-py for openSUSE and Rocky
-        if: ${{ !startsWith(matrix.image, 'archlinux') && 
!startsWith(matrix.image, 'debian') }}
+        if: ${{ !startsWith(matrix.image, 'archlinux') && 
!startsWith(matrix.image, 'debian') && !startsWith(matrix.image, 'alpine') }}
         run: pip3 install redis==4.3.6
 
       - name: Install redis-py for Debian
diff --git a/src/storage/redis_metadata.h b/src/storage/redis_metadata.h
index cba9df80..69a0db1c 100644
--- a/src/storage/redis_metadata.h
+++ b/src/storage/redis_metadata.h
@@ -21,6 +21,7 @@
 #pragma once
 
 #include <rocksdb/status.h>
+#include <sys/time.h>
 
 #include <atomic>
 #include <bitset>

Reply via email to