webdevops / azure-devops-exporter

Prometheus exporter for Azure DevOps (VSTS) including agent pools, builds, releases, deployments, pullrequests and repo stats
MIT License
147 stars 57 forks source link

Closed pull requests #27

Open jpreese opened 4 years ago

jpreese commented 4 years ago

It looks like the pull request collector is hard coded to only pull back active pull requests. Any objection to also including closed? Would be useful to be able to capture how many pull requests have been completed, time to complete, etc.

mblaschke commented 3 years ago

The goal is only to get opened PRs (eg. display them in grafana). Otherweise the exporter would pull the hole database inside Prometheus which he should not do it.

Statistics would be another goal.

andrew-gropyus commented 2 years ago

I will chime in here if it is ok. One thing I am interested in getting visibility on is how long it takes a commit to go from 'git push' to deployed on a production system, a lead time essentially.

Tracking this per commit might be a bit much, so I think pull requests are a nice alternative. Being able to know how long a PR was open before being merged would help me in this calculation. I would be able to do something like 'avg time to close PR + avg build duration'.

Another approach might be to track just the PR creation times, and somehow carry the PR info into the build info metric. Then I also look at build_completed_time - pr_created_time.

mblaschke commented 2 years ago

will have a look