Thank you for you comments. Answers to all proposals and questions bellow: > what scm prilovider are you using?
At this point we support only GitHub, but we may support different SCM in the future too. > I fixed this by adding the only build matching branches to be 'master Stable-* PR-*' > Regexes can’t always help with this. This doesn't prevent building branches after the job creation. If I inform developers that only `ABC-*` branches and PR are build, then all branches will be called `ABC-`, because developers need CI results (it executes a lot of additional tools like: SonarQube or WhiteSource) > for GitHub at least you can address this directly SCM services are managed by other people. Even if all teams always delete old branches, the load is still quite huge. Example: Let's have 35 teams, every has 10 branches (develop, master, 5 features, 2 epic branches and 1 for previous release) and 2 PRs. Imagine an average build takes about 1 hour (monolit applications, some needs 20 minutes, other 2 hours). After a server creation (K8S environment, server fully provisioned). I have 35 * 12 = 420 builds. We have 120 dynamic slaves. 420 / 120 = 3.5. It means that the server is blocked for 3.5 hours. We also waste money, because the server is hosted on cloud. Of course it is a good idea to always ask developers to enable this option, just to keep repositories clean. > Untested, but looks promising: https://plugins.jenkins.io/github-scm-filter-aged-refs/ We cannot use it because: 1) If developers need to build an older version of any application, they should be able to do it (for many reasons, like execute deployment somewhere). I would like to not force them to push commits like "empty, show the branch on CI" 2) the application is under heavy development, even building branches and PRs not older than 1 week - kills the server -- You received this message because you are subscribed to the Google Groups "Jenkins Developers" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-dev/451daaf7-16da-48d3-a38c-63c874ed129c%40googlegroups.com.
