Skip to main content

Azure DevOps( Server) –Check repository health and usage

Azure DevOps offers a repository health feature, which allows to monitor multiple metrics that contribute to the health of your Git repositories. If you are using Azure DevOps services, you maybe already know this feature. But with the latest release of Azure DevOps server (December 2025) , it finally arrived on-premise as well. Reasons enough to have a deeper look at it and write this post.

Let’s dive in!

Why is this feature relevant for my team?

Think of your Git repository like a living organism. As it grows with more commits, blobs, branches, and objects, it can become sluggish and unwieldy. Large repositories increase the load on Azure DevOps infrastructure, affecting performance and user experience. Without proper maintenance, your team could face slower clone times, degraded git operations, and even service disruptions.

The repository health feature now provides visibility into key health metrics and offers actionable recommendations before problems escalate.

Getting to your repository's health dashboard is straightforward. Navigate to your Azure Repos Git repository, select Repo > Files, and choose "Health and usage" from the ellipsis menu.

This opens the Repository health and usage panel, where you'll find a comprehensive overview of your repository's vital statistics.

The interface uses a traffic light system: factors highlighted in red indicate unhealthy conditions that need immediate attention, while amber warnings suggest you're approaching problematic thresholds.

Key metrics

The health feature tracks the following key metrics:

Repository size

Microsoft recommends keeping your repository size under 100 GB for optimal performance. Smaller repositories clone faster and are easier to manage. If you're exceeding this threshold, consider using Git Large File Storage (Git-LFS), or Scalar to manage large repositories.

Binary and large files

Storing large binary files like images, videos, or compiled artifacts directly in Git is problematic. Different versions of these files don't compress efficiently through Git's delta compression, meaning each version consumes substantial disk space. The health dashboard helps you identify when these files are becoming a problem.

Object counts

Azure Repos has a hard limit of 100 million objects in a single repository. The health panel tracks several object types:

  • Reachable blobs: The total size of file content stored in your repository. These should stay well under 100 GB, leaving room for other object types.
  • Reachable trees: Tree objects represent directory structures. They grow as you add directories and files, and Git creates copies of trees whenever files change. Distributing files across multiple subdirectories rather than having flat directory structures helps keep tree counts manageable.
  • Reachable commits: The total number of commit objects in your repository. While commits are smaller than blobs, a large number can slow down history traversal operations.

Reference count

If your Git repository contains more than 10,000 refs, you should consider enabling Limited Refs. As reference counts increase, so does the data that needs to be negotiated between client and server, potentially degrading user experience.

Best practices for repository health

Based on the health metrics Azure DevOps monitors, here are some best practices to keep your repositories in top shape:

  1. Regularly review your health dashboard: Make repository health checks part of your routine maintenance, especially for high-activity repositories.
  2. Refactor large files: Move binary assets, build artifacts, and other large files to appropriate storage solutions like Azure Artifacts or Git-LFS.
  3. Maintain reasonable directory structures: Avoid deep nesting or overly flat hierarchies. A balanced approach reduces tree object proliferation.
  4. Archive stale branches: Old feature branches and experimental work can be archived or deleted to reduce ref counts.
  5. Consider repository splitting: If a repository has grown beyond manageable size, evaluate whether it makes sense to split it into multiple repositories organized by logical boundaries.

More information

Repository health - Azure Repos | Microsoft Learn

Azure DevOps Server Release Notes - Azure DevOps Server & TFS | Microsoft Learn

Limited Refs - Azure DevOps Server & TFS | Microsoft Learn

Work with large files in your Git repo - Azure Repos | Microsoft Learn

Popular posts from this blog

Podman– Command execution failed with exit code 125

After updating WSL on one of the developer machines, Podman failed to work. When we took a look through Podman Desktop, we noticed that Podman had stopped running and returned the following error message: Error: Command execution failed with exit code 125 Here are the steps we tried to fix the issue: We started by running podman info to get some extra details on what could be wrong: >podman info OS: windows/amd64 provider: wsl version: 5.3.1 Cannot connect to Podman. Please verify your connection to the Linux system using `podman system connection list`, or try `podman machine init` and `podman machine start` to manage a new Linux VM Error: unable to connect to Podman socket: failed to connect: dial tcp 127.0.0.1:2655: connectex: No connection could be made because the target machine actively refused it. That makes sense as the podman VM was not running. Let’s check the VM: >podman machine list NAME         ...

Cache stampede: when our cache turned against us

While investigating some performance issues, we ran into an ASP.NET Core API that cached a fairly expensive aggregation query for 60 seconds. Under normal load, that was fine: one request rebuilds the cache, everyone else reads from it. Under peak load, dozens of requests would arrive in that same expiry window, all see a cache miss, and all fire the same expensive query in parallel. The database didn't like that. That was the moment when our caching layer stopped helping and started hurting. A burst of requests comes in at the same time, all miss the cache, and all go hammer the database or the downstream API at once. That's a cache stampede . The cache was supposed to protect our backend, and for a few hundred milliseconds it did the opposite. Why this happens IMemoryCache.GetOrCreate (and its async sibling) looks like it protects you, but it doesn't add any locking on its own. Look at the naive version: public async Task<Report> GetReportAsync(string key) ...

A complex system designed from scratch never works

A few years ago, I worked as an architect on a big mainframe rewrite. I still count it as one of my failures. Not because the technology was wrong, but because I couldn't convince the management team to simplify the approach. Years later, the organization is still struggling to get the new system up and running. I left the project at the time, because I couldn't put my name behind an approach that would take very long and cost a lot of money without a working system to show for it along the way. Gall’s Law That memory keeps coming back to me, because it's a textbook case of Gall's Law playing out in real life. Gall's Law , from John Gall's Systemantics , states it plainly: A complex system that works is invariably found to have evolved from a simple system that worked. A complex system designed from scratch never works, and it cannot be patched to make it work. You have to start over with a simple system that works. What does that mean in practice,...