Skip to content

Commit 8fbcef7

Browse files
committed
[UNDERTOW-2587] Fix the linux script
Signed-off-by: Flavia Rainone <frainone@redhat.com>
1 parent d0c7b57 commit 8fbcef7

File tree

1 file changed

+10
-2
lines changed

1 file changed

+10
-2
lines changed

.github/workflows/ci.yml

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -112,7 +112,11 @@ jobs:
112112
- name: Run Tests
113113
if: matrix.os != 'windows-latest'
114114
run: |
115-
timeout 5400s mvn -U -B -fae test -Pproxy '-DfailIfNoTests=false' -pl ${{ matrix.module }} || jstack -l $(jps | awk '$2 ~ /surefirebooter/ {print $1}') > thread-dump.txt && exit 1)
115+
mvn -U -B -fae test -Pproxy '-DfailIfNoTests=false' -pl ${{ matrix.module }} > output.txt &
116+
sleep 180
117+
cat output.txt
118+
$hanging_test_pid=$(jps | awk '$2 ~ /surefirebooter/ {print $1}'
119+
[ ! -z "$hanging_test_pid" ] && echo "Hanging test found. Pid is $hanging_test_pid" && jstack -l $(jps | awk '$2 ~ /surefirebooter/ {print $1}') | tee thread-dump.txt && exit 1
116120
- uses: actions/upload-artifact@v4
117121
if: failure()
118122
with:
@@ -172,7 +176,11 @@ jobs:
172176
- name: Run Tests
173177
if: matrix.os != 'windows-latest'
174178
run: |
175-
timeout 5400s mvn -U -B -fae test ${{ matrix.proxy }} '-DfailIfNoTests=false' -pl ${{ matrix.module }} -Dtest.ipv6=true || jstack -l $(jps | awk '$2 ~ /surefirebooter/ {print $1}') > thread-dump.txt && exit 1)
179+
timeout 5400s mvn -U -B -fae test ${{ matrix.proxy }} '-DfailIfNoTests=false' -pl ${{ matrix.module }} -Dtest.ipv6=true
180+
sleep 180
181+
cat output.txt
182+
$hanging_test_pid=$(jps | awk '$2 ~ /surefirebooter/ {print $1}'
183+
[ ! -z "$hanging_test_pid" ] && echo "Hanging test found. Pid is $hanging_test_pid" && jstack -l $(jps | awk '$2 ~ /surefirebooter/ {print $1}') | tee thread-dump.txt && exit 1
176184
- uses: actions/upload-artifact@v4
177185
if: failure()
178186
with:

0 commit comments

Comments
 (0)