View GitOps Agent metrics in Harness
View GitOps Agent metrics for CPU, memory, and latency on the Metrics tab in Harness, and use them to decide when to scale.
The GitOps Agent runs on your infrastructure and sends a small snapshot of its own process metrics to Harness. Harness displays these metrics for all four GitOps Agent components on the Metrics tab of the agent, so you can check whether an agent is under pressure, decide when to scale a component, and compare the agent with itself from the same time last week. Harness AI and Harness Support read the same data, so Support can review agent load without access to your cluster.
You can also scrape the full set of agent metrics with Prometheus. This topic covers the Harness UI method. Go to GitOps Agent metrics with Prometheus to use the Prometheus method.
The snapshot is built from the same metrics that the agent exposes on port 2112, so the scrape endpoint is unchanged. Sending metrics is a best effort and runs separately from GitOps tasks, reconciliation, and agent health. If Harness is unreachable, the agent keeps working and tries again at the next interval.
What you will learn from this topic
How the agent reports metrics to Harness, and how often.
How to access the Metrics tab at project, organization, and account scope.
How to use the tab controls and read the tab sections.
How to use the metrics to scale the agent and ask Harness AI about them.
The permissions required and how long Harness retains the data.
Before you begin
Before you begin, make sure you have the following:
GitOps Agent version: To view metrics on the Metrics tab in Harness, the agent must run version 0.129.1 or later. You can find the agent version in the Version field on the Agent Details tab.
Latest Helm chart: To see Application Controller metrics on the Metrics tab, install or upgrade the agent with the latest GitOps Agent Helm chart.
Permissions: You need the
gitops_agent_viewpermission for the agent. Go to Permissions for details.
Metrics and reporting behavior
The metrics on the tab are aggregated from the agent's Prometheus registry. The agent sends a fixed, Harness-managed list of metrics, such as process CPU, process memory, and latency for tasks, reconciliation, and HTTP requests. The agent downloads this list from Harness and sends nothing until it has it. Because the list is managed by Harness, updates do not require an agent upgrade, restart, or Helm change.
Each metric is reported for the entire component. The agent combines all label sets of a metric, so you do not see per-application or per-task breakdowns. Single-value metrics, such as Prometheus gauges and counters, are reported as they are. For example, CPU is reported as a percentage of one core, and memory is the resident memory of the agent process, not the pod. Histogram metrics, such as latency, are aggregated over a five-minute window and report the 50th, 95th, and 99th percentiles, plus a count and a sum.
The agent reports metrics every minute.
Access the Metrics tab
Perform the following steps to view the metrics for an agent:
Go to Project Settings, Organization Settings, or Account Settings -> GitOps Agents, depending on the scope of your agent.
Select your agent, then select the Metrics tab.

Metrics tab controls
Use the controls at the top of the tab to change what you see:
Components: Select the components to show. The dropdown lists GitOps Agent, Repo Server, Application Controller, and ApplicationSet Controller. All four are selected by default, and the badge shows how many are selected.
Refresh interval: Select how often the page reloads the data. The default is Off. The options are Off, 30s, 1m, 5m, 15m, and 30m.
Time range: Select a preset such as Yesterday or Past week, or pick start and end dates and times on the calendar. The default is Last 24 hours.
On the right side of the controls, the tab shows when the agent Started and when it last Reported, for example, "Started 19 minutes ago" and "Reported a minute ago". Use these values to confirm that the agent is sending metrics.
Harness keeps 14 days of history, so choose a range of up to one week to compare the current load with the same time last week.
Metrics tab sections
The tab has a Live section followed by one section for each selected component.
The Live section shows the current CPU and memory for each selected component as value cards by default. To change the metrics shown in this section, click the eye icon on a chart to show or hide the card with its current value.
Each component section shows charts for the selected time range. Latency charts include a percentile dropdown with p50, p95, and p99. The default is p99. A chart displays No Data when no metrics are available for the selected time range.
The following table lists the metrics that each component section shows.
GitOps Agent
CPU, Memory, Task execution, Task Receiver Channel Blocked Time, Task Response Sender Channel Blocked Time, Task Complete Processing Time, Reconciler, HTTP request
Repo Server
CPU, Memory, Git request
Application Controller
CPU, Memory, App reconcile, Workqueue depth
ApplicationSet Controller
CPU, Memory
Use the metrics to scale the agent
Watch the latency charts of the GitOps Agent component for spikes. The task charts show where a task spends its time within the agent, so they indicate which worker pool to scale. For example, a spike in Task Response Sender Channel Blocked Time means that completed tasks wait to send results to Harness, so you can increase GITOPS_AGENT_NUM_RESPONDERS.
Go to Task metrics to review how the task metrics relate to each other and to the worker pools. Go to Performance considerations to review scaling guidance for the Application Controller and Repo Server.
Ask Harness AI about agent metrics
Harness AI is aware of the agent metrics through a Model Context Protocol (MCP) tool. In the Harness AI chat, ask about an agent, for example, whether its metrics look healthy. Harness AI reads the metrics, summarizes resource usage, flags high latency, and tells you whether you should scale and which component to scale.
Permissions
You need the gitops_agent_view permission for the agent to view its metrics. No new permission is required.
Data retention
Harness keeps the latest values and 14 days of history for each agent. If an agent stops reporting, the latest values are shown as stale, and history ages out after 14 days.
Next steps
GitOps Agent metrics with Prometheus: Expose and scrape the agent metrics endpoint with Prometheus, and review the full list of available metrics.
Performance considerations: Review scaling guidance for the Application Controller and Repo Server.
Last updated
Was this helpful?