K8s Cluster
Overview
K8s Cluster collects cluster-level state metrics from the Kubernetes API server. It provides visibility into node conditions, resource allocation, workload states, and metadata across your cluster. It is ideal for monitoring cluster health, scheduling behavior, and infrastructure-level signals.
Supported platforms
- Kubernetes:
Metrics
Workload Configuration
| Parameter | Type | Default | Required | Description |
|---|---|---|---|---|
| kind | string | Deployment | Yes | The source runs as a Deployment. |
| enable_leader_election | boolean | true | No | Ensures only one pod scrapes the API at a time (HA mode). |
| replica_scaling_type | string | manual | No | Scaling mode: manual or auto. |
| replicas | integer | 2 | Conditional | Required when replica_scaling_type = manual. |
| priorityClass | boolean | false | No | Assign priority class to pods. |
| priorityClassName | string | — | Conditional | Required when priorityClass = true. |
| apply_tolerations | boolean | false | No | Allow scheduling on control-plane nodes. |
Metric & Metadata Configuration
| Parameter | Type | Default | Required | Description |
|---|---|---|---|---|
| collection_interval | string | 10s | No | Frequency at which cluster metrics are collected. |
| resource_attributes | array | ["container.id", "k8s.pod.uid"] | No | Additional resource attributes attached to metrics. |
| node_conditions_to_report | array | ["Ready"] | No | Node conditions emitted as metrics (supported options: Ready, MemoryPressure, DiskPressure, PIDPressure, NetworkUnavailable). |
| allocatable_types_to_report | array | [] | No | Node allocatable resources to track (options: cpu, memory, pods, ephemeral-storage). |
Advanced Settings
| Parameter | Type | Default | Required | Description |
|---|---|---|---|---|
| distribution | string | kubernetes | No | Kubernetes distribution (kubernetes or openshift). |
| namespaces | array | [] | No | Limit metrics to specific namespaces. |
| metadata_collection_interval | string | 5m | No | Interval for refreshing metadata. |
Example Configuration
{
// Workload Configuration
"kind": "Deployment",
"enable_leader_election": true,
"replica_scaling_type": "manual",
"replicas": 2,
"priorityClass": false,
"priorityClassName": "",
"apply_tolerations": false,
// Metric & Metadata Configuration
"collection_interval": "10s",
"resource_attributes": ["container.id", "k8s.pod.uid", "k8s.node.uid"],
"node_conditions_to_report": ["Ready", "MemoryPressure", "DiskPressure"],
"allocatable_types_to_report": ["cpu", "memory", "pods"],
// Advanced Settings
"distribution": "kubernetes",
"namespaces": ["production", "staging"],
"metadata_collection_interval": "5m",
}