Skip to content

Commit

Permalink
HIVE-28359: Discard old builds in Jenkins to avoid disk space exhaustion
Browse files Browse the repository at this point in the history
Currently Jenkins retains the builds from all active branches/PRs leading to disk space exhaustion and CI failures requiring manual intervention to restore the services.
  • Loading branch information
zabetak committed Jul 3, 2024
1 parent b15ce91 commit 8e75449
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions Jenkinsfile
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,9 @@
*/

properties([
// For master keep all builds for one year
// For other branches/PRs keep at most 5 builds for at most two months
buildDiscarder(logRotator(daysToKeepStr: env.BRANCH_NAME=='master'?'365':'60', numToKeepStr: env.BRANCH_NAME=='master'?'':'5')),
// max 5 build/branch/day
rateLimitBuilds(throttle: [count: 5, durationName: 'day', userBoost: true]),
// do not run multiple testruns on the same branch
Expand Down

0 comments on commit 8e75449

Please sign in to comment.