Skip to content

filter_multiline: Reset group metadata buf on flush - Fixes 9262,8925,9337,8567 #10185

filter_multiline: Reset group metadata buf on flush - Fixes 9262,8925,9337,8567

filter_multiline: Reset group metadata buf on flush - Fixes 9262,8925,9337,8567 #10185

Workflow file for this run

name: Run unit tests
on:
push:
branches:
- master
- 2.1
- 2.0
- 1.9
- 1.8
pull_request:
paths-ignore:
- '.github/**'
- 'dockerfiles/**'
- 'docker_compose/**'
- 'packaging/**'
- '.gitignore'
- 'appveyor.yml'
- '**.sh'
- 'examples/**'
branches:
- master
- 2.1
- 2.0
- 1.9
- 1.8
types: [opened, reopened, synchronize]
workflow_dispatch:
jobs:
run-ubuntu-unit-tests:
runs-on: ubuntu-20.04
timeout-minutes: 60
strategy:
fail-fast: false
matrix:
flb_option:
- "-DFLB_JEMALLOC=On"
- "-DFLB_JEMALLOC=Off"
- "-DFLB_SMALL=On"
- "-DSANITIZE_ADDRESS=On"
- "-DSANITIZE_UNDEFINED=On"
- "-DFLB_COVERAGE=On"
- "-DFLB_SANITIZE_MEMORY=On"
- "-DFLB_SANITIZE_THREAD=On"
compiler:
- gcc
- clang
exclude:
- flb_option: "-DFLB_COVERAGE=On"
compiler: clang
permissions:
contents: read
steps:
- name: Setup environment
run: |
sudo apt-get update
sudo apt-get install -y gcc-7 g++-7 clang-6.0 libsystemd-dev gcovr libyaml-dev
sudo ln -s /usr/bin/llvm-symbolizer-6.0 /usr/bin/llvm-symbolizer || true
- uses: actions/checkout@v4
- uses: actions/checkout@v4
with:
repository: calyptia/fluent-bit-ci
path: ci
- name: ${{ matrix.compiler }} - ${{ matrix.flb_option }}
run: |
echo "CC = $CC, CXX = $CXX, FLB_OPT = $FLB_OPT"
sudo update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-7 90
sudo update-alternatives --install /usr/bin/g++ g++ /usr/bin/g++-7 90
sudo update-alternatives --install /usr/bin/clang clang /usr/bin/clang-6.0 90
sudo usermod -a -G systemd-journal $(id -un)
sudo -E su -p $(id -un) -c "PATH=$PATH ci/scripts/run-unit-tests.sh"
env:
CC: ${{ matrix.compiler }}
CXX: ${{ matrix.compiler }}
FLB_OPT: ${{ matrix.flb_option }}
run-macos-unit-tests:
# We chain this after Linux one as there are costs and restrictions associated
needs:
- run-ubuntu-unit-tests
runs-on: macos-latest
timeout-minutes: 60
strategy:
fail-fast: false
matrix:
flb_option:
- "-DFLB_JEMALLOC=Off"
- "-DFLB_SANITIZE_MEMORY=On"
- "-DFLB_SANITIZE_THREAD=On"
permissions:
contents: read
steps:
- uses: actions/checkout@v4
- uses: actions/checkout@v4
with:
repository: calyptia/fluent-bit-ci
path: ci
- name: ${{ matrix.flb_option }}
run: |
echo "CC = $CC, CXX = $CXX, FLB_OPT = $FLB_OPT"
brew update
brew install bison flex openssl || true
ci/scripts/run-unit-tests.sh
env:
CC: gcc
CXX: g++
FLB_OPT: ${{ matrix.flb_option }}
# Required check looks at this so do not remove
run-all-unit-tests:
if: always()
runs-on: ubuntu-latest
name: Unit tests (matrix)
permissions:
contents: none
needs:
- run-macos-unit-tests
- run-ubuntu-unit-tests
steps:
- name: Check build matrix status
# Ignore MacOS failures
if: ${{ needs.run-ubuntu-unit-tests.result != 'success' }}
run: exit 1