Jenkinsfile.sonar: 컴파일 전 생성 소스 정리
eapim-portal CI / build (push) Has been cancelled
eapim-portal Test / test (push) Has been cancelled

clean 이 build/generated 잠금으로 실패하는 사례가 있어 rm -rf 를 선행한다.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
This commit is contained in:
Rinjae
2026-08-13 15:32:15 +09:00
parent 92589530d1
commit 1a95f015dc
+8 -3
View File
@@ -104,11 +104,16 @@ pipeline {
}
}
// clean 을 반드시 붙인다. build/generated 잔여 산출물이 남으면
// MapStruct Impl / QueryDSL Q클래스가 중복 생성되어 컴파일이 깨진다.
// build/generated 잔여 산출물이 남으면 MapStruct Impl / QueryDSL Q클래스가
// 중복 생성되어 컴파일이 깨진다. clean 이 파일 잠금 등으로 실패하는 경우가 있어
// 생성 소스 디렉터리는 별도로 먼저 지운다.
stage('Compile') {
steps {
sh 'gradle clean classes testClasses --no-daemon'
sh '''
set -eu
rm -rf build/generated build/classes
gradle clean classes testClasses --no-daemon
'''
}
}