> [!WARNING]
>
> **Preview**
>
>
> This product is
>
> subject to the "Pre-GA Offerings Terms" in the General Service Terms section of the
> [Service Specific
> Terms](https://docs.cloud.google.com/terms/service-terms#1).
>
> Pre-GA products are available "as is" and might have limited support.
>
> For more information, see the
> [launch stage descriptions](https://cloud.google.com/products/#product-launch-stages).

This document describes the metrics and metadata labels that Network Services Monitoring
uses to visualize service communication paths, identify high-throughput
services, and analyze connection health.

## Network metrics

Network Services Monitoring uses the following network metrics (Layer 4).

| Metric | Kind | Description |
|---|---|---|
| `networkservices.googleapis.com/proxy.network.connection.count` | UpDownCounter | Number of network connections managed by the proxy |
| `networkservices.googleapis.com/proxy.network.connection.duration` | Histogram | Distribution of connection duration, from establishment to closure |
| `networkservices.googleapis.com/proxy.network.connection.resets` | Counter | Cumulative count of connections terminated through a reset (RST) packet |
| `networkservices.googleapis.com/proxy.network.connection.timeouts` | Counter | Cumulative count of network connections terminated by the proxy due to a timeout |
| `networkservices.googleapis.com/proxy.network.errors` | Counter | Cumulative count of internal errors detected by the proxy |
| `networkservices.googleapis.com/proxy.network.io` | Counter | Cumulative number of bytes transmitted and received by the proxy |
| `networkservices.googleapis.com/proxy.network.tls.handshake.errors` | Counter | Cumulative count of failed TLS handshakes |

Use the following strategies to analyze network metrics:

- To determine network throughput for a resource, monitor the `proxy.network.io` metric.
- To identify network errors, timeouts, resets, or failed TLS handshakes, monitor the `proxy.network.errors`, `proxy.network.connection.timeouts`, `proxy.network.connection.resets`, and `proxy.network.tls.handshake.errors` metrics.

## App Hub metadata labels

If a resource is registered in App Hub,
the following labels are automatically added to the preceding metrics to
identify the source and destination resources:

- **Source metadata:**
  - `apphub_source_application_container`
  - `apphub_source_application_id`
  - `apphub_source_application_location`
  - `apphub_source_service_criticality_type`
  - `apphub_source_service_environment_type`
  - `apphub_source_service_id`
  - `apphub_source_workload_criticality_type`
  - `apphub_source_workload_environment_type`
  - `apphub_source_workload_id`
- **Destination metadata:**
  - `apphub_destination_application_container`
  - `apphub_destination_application_id`
  - `apphub_destination_application_location`
  - `apphub_destination_service_criticality_type`
  - `apphub_destination_service_environment_type`
  - `apphub_destination_service_id`
  - `apphub_destination_workload_criticality_type`
  - `apphub_destination_workload_environment_type`
  - `apphub_destination_workload_id`

## What's next

- Register services and workloads in [App Hub](https://docs.cloud.google.com/app-hub/docs/overview)
- [Investigate applications, services, and workloads](https://docs.cloud.google.com/monitoring/docs/application-monitoring) in Application Monitoring