Skip to content

Commit

Permalink
Collect core dumps and broker executable on failure
Browse files Browse the repository at this point in the history
Signed-off-by: Dmitrii Petukhov <[email protected]>
  • Loading branch information
bbpetukhov authored and pniedzielski committed Nov 7, 2024
1 parent 7b97a18 commit 859b2aa
Showing 1 changed file with 21 additions and 0 deletions.
21 changes: 21 additions & 0 deletions .github/workflows/build.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -211,6 +211,11 @@ jobs:
run: |
./venv/bin/python3 -m pip install --upgrade pip
./venv/bin/python3 -m pip install -r requirements-dev.txt
- name: Setup Core Dumps config
run: |
sudo mkdir /cores
sudo chmod 777 /cores
echo "/cores/%e.%p.%s.%t" | sudo tee /proc/sys/kernel/core_pattern
- name: Run tests with coverage
env:
BMQ_BROKER_URI: tcp://localhost:30114
Expand All @@ -220,6 +225,8 @@ jobs:
run: |
mkdir -p bmq/logs
mkdir -p bmq/storage/archive
# Allow core dumps
ulimit -c unlimited
./blazingmq_artifacts/bin/bmqbrkr.tsk ./tests/broker-config &
(sleep 5; make coverage-install && make coverage)
- name: Output code coverage summary
Expand All @@ -234,3 +241,17 @@ jobs:
path: ./bmq/logs
retention-days: 5
compression-level: 9
- name: Upload broker core dump as artifacts
if: failure()
uses: actions/upload-artifact@v4
with:
name: core_dumps
path: /cores
retention-days: 5
- name: Upload broker executable as artifacts to debug the core
if: failure()
uses: actions/upload-artifact@v4
with:
name: bmqbrkr
path: ./blazingmq_artifacts/bin/bmqbrkr.tsk
retention-days: 5

0 comments on commit 859b2aa

Please sign in to comment.