I want to keep track of active repositories and track there should be minimum 2 code contributors over time of 12 month. Any repositories with 0 commits in a an year will be marked as stale and archived.
Is it possible to create a custom metric on compass which can track minimum commits in an year and pass/fail the component based on this criteria.
Hi, @upendra_singh !
As you probably have already noticed, Compass comes with some built-in metrics that use some activity / time-based conditions, but it's true that they don't exactly match numbers of commits per year - we use deployment frequency over the last 4 weeks to identify stale or riskier repositories.
It is possible to create a custom metric in Compass to track something similar to what you're suggesting - for example, the number of commits during the last year - considering that in such case, the service pushing that metric would have to do the math and send the exact number to set the metric to, and continue updating (which it could be possible to orchestrate from your CI/CD pipeline).
Once you have your custom metric defined, you can assign it to components, and start pushing metric values for each one of them, typically via the REST API. Then, it is possible to create a scorecard that references such metric, and its associated success threshold, to score against that specific metric and assess compliance.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.