Jenis metrik mengikuti definisi jenis metrik Prometheus. Metrik Info Prometheus adalah jenis metrik Pengukur Prometheus khusus, yang selalu memiliki nilai 1 dan memiliki beberapa label yang membawa informasi penting tentang Resource Kustom operator Kubernetes AlloyDB Omni yang sesuai.
Semua metrik resource kustom memiliki label berikut yang menandai grup, versi, dan jenis CRD. Untuk mengetahui informasi selengkapnya, lihat
Konsep Kubernetes API.
Definisi dan penamaan label tercantum dalam tabel berikut:
Kunci
Deskripsi
Nilai Contoh
customresource_group
Grup CRD.
alloydbomni.dbadmin.goog
customresource_version
Versi CRD.
v1
customresource_kind
Jenis CRD.
DBCluster
Metrik DBCluster
Metrik DBCluster diekspos dari manifes resource DBCluster. Semua nama metrik DBCluster dimulai dengan alloydb_omni_dbcluster_. Semua metrik DBCluster memiliki label berikut:
Kunci
Nilai
namespace
Namespace tempat DBCluster berada.
dbcluster
Nama resource kustom DBCluster.
Label dalam tabel berikut akan memiliki nilai kosong —dan dianggap setara dengan label yang tidak ada per Nama dan label metrik Prometheus— jika kolom yang relevan tidak ada dalam manifes DBCluster.
Nama Metrik
Deskripsi
Label
Unit
Jenis
alloydb_omni_dbcluster_ha_ready
Kesiapan ketersediaan tinggi (HA) `DBCluster`:
1 jika ha-ready, jika tidak
0.
reason: Alasan mengapa DBCluster ini
(tidak) siap untuk HA.
1
Meteran
alloydb_omni_dbcluster_primary_ready
Kesiapan node utama DBCluster:
1 jika siap, atau 0. jika tidak
reason: Alasan mengapa node utama DBCluster ini (tidak) siap.
1
Meteran
alloydb_omni_dbcluster_status_info
Status DBCluster. saat ini
phase: fase DBCluster.
database_version: versi image AlloyDB Omni yang sedang berjalan, misalnya, 15.7.0.
controlplane_agents_version: versi image agen bidang kontrol yang sedang berjalan, misalnya, 1.3.0.
read_only_endpoint: endpoint hanya baca dari
DBCluster.
primary_phase: fase
DBCluster node utama.
haready_status: Status kondisi HAReady, True, atau False.
haready_reason: alasan kondisi
HAReady.
1
Info
alloydb_omni_dbcluster_spec_info
Konfigurasi DBCluster di kolom spec
manifes DBCluster.
num_standbys:jumlah node standby yang dikonfigurasi.
database_version: versi image AlloyDB Omni yang dikonfigurasi, misalnya, 15.7.0.
controlplane_agents_version: versi image agen bidang kontrol yang dikonfigurasi, misalnya, 1.3.0.
is_deleted: menunjukkan apakah
DBCluster ini ditandai untuk dihapus, ditetapkan ke true atau
false.
allow_external_incoming_traffic: menunjukkan apakah
DBCluster ini dikonfigurasi untuk mengizinkan traffic dari luar
cluster Kubernetes, true atau false.
1
Info
alloydb_omni_dbcluster_spec_num_standbys
Jumlah siaga yang ditentukan dalam spesifikasi DBCluster.
T/A
1
Meteran
alloydb_omni_dbcluster_critical_incident_info
Entri insiden kritis di bagian DBCluster manifest
status.criticalIncidents.
Waktu saat insiden kritis terjadi, dinyatakan dalam format waktu epoch Unix.
message: Pesan error insiden kritis.
code: Kode error insiden kritis.
dtk
Meteran
Metrik failover
Metrik failover adalah metrik yang diekspos dari manifes resource Failover. Semua nama metrik
pengalihan dimulai dengan alloydb_omni_failover_. Semua metrik Failover memiliki label berikut:
Kunci
Nilai
namespace
Namespace tempat Failover berada.
failover
Nama resource kustom Failover.
dbcluster
Nama resource kustom DBCluster yang menjadi target Failover.
Nilai ini sama dengan kolom spec.dbclusterRef dari
Failover.
Label dalam tabel berikut akan memiliki nilai kosong —dan dianggap setara dengan label yang tidak ada berdasarkan nama dan label metrik Prometheus— jika kolom yang relevan tidak ada dalam manifes Pengalihan.
Nama metrik
Deskripsi
Label
Unit
Jenis
alloydb_omni_failover_start_time
Waktu saat Failover ini dimulai, dinyatakan dalam
format waktu epoch Unix.
state: status Failover.
phase: fase Failover.
dtk
Meteran
alloydb_omni_failover_end_time
Waktu saat Failover selesai, dinyatakan dalam format waktu epoch Unix
state: status Failover
phase: fase Failover
dtk
Meteran
alloydb_omni_failover_status_info
Status Failover saat ini.
start_time: waktu saat Failover
dimulai.
end_time: waktu saat Failover
selesai.
new_primary: nama node utama setelah
Failover selesai.
old_primary: nama node utama sebelum
Failover dimulai
phase: fase Failover.
state: status Failover.
1
Info
Metrik PgBouncer
Metrik PgBouncer adalah metrik yang diekspos dari manifes resource PgBouncer. Semua nama metrik PgBouncer dimulai dengan alloydb_omni_pgbouncer_. Semua metrik
PgBouncer memiliki label berikut:
Kunci
Nilai
namespace
Namespace tempat PgBouncer berada.
pgbouncer
Nama resource kustom PgBouncer.
dbcluster
Nama resource kustom DBCluster yang ditargetkan
PgBouncer ini. Nilai ini sama dengan kolom spec.dbclusterRef dari PgBouncer.
Label dalam tabel berikut akan memiliki nilai kosong —dan dianggap setara dengan label yang tidak ada berdasarkan nama dan label metrik Prometheus— jika kolom yang relevan tidak ada dalam manifes PgBouncer.
Nama Metrik
Deskripsi
Label
Unit
Jenis
alloydb_omni_pgbouncer_status_info
Status PgBouncer saat ini.
endpoint: Endpoint yang diekspos oleh PgBouncer ini. Anda
terhubung ke endpoint ini untuk menjalankan kueri terhadap DBCluster yang ditargetkan
PgBouncer ini.
[[["Mudah dipahami","easyToUnderstand","thumb-up"],["Memecahkan masalah saya","solvedMyProblem","thumb-up"],["Lainnya","otherUp","thumb-up"]],[["Sulit dipahami","hardToUnderstand","thumb-down"],["Informasi atau kode contoh salah","incorrectInformationOrSampleCode","thumb-down"],["Informasi/contoh yang saya butuhkan tidak ada","missingTheInformationSamplesINeed","thumb-down"],["Masalah terjemahan","translationIssue","thumb-down"],["Lainnya","otherDown","thumb-down"]],["Terakhir diperbarui pada 2025-09-04 UTC."],[[["\u003cp\u003eThis page details the custom resource (CR) metrics exposed by the AlloyDB Omni Kubernetes operator, formatted for use with Prometheus and kube-state-metrics.\u003c/p\u003e\n"],["\u003cp\u003eCustom resource metrics provide insights into the group, version, and kind of the Custom Resource Definition (CRD) through specific labels like \u003ccode\u003ecustomresource_group\u003c/code\u003e, \u003ccode\u003ecustomresource_version\u003c/code\u003e, and \u003ccode\u003ecustomresource_kind\u003c/code\u003e.\u003c/p\u003e\n"],["\u003cp\u003eDBCluster metrics, prefixed with \u003ccode\u003ealloydb_omni_dbcluster_\u003c/code\u003e, reveal the status and configuration of DBCluster resources, including HA readiness, primary node readiness, and details about critical incidents.\u003c/p\u003e\n"],["\u003cp\u003eFailover metrics, starting with \u003ccode\u003ealloydb_omni_failover_\u003c/code\u003e, track the start and end times of failover events, along with the status of the failover process, including the new and old primary nodes.\u003c/p\u003e\n"],["\u003cp\u003ePgBouncer metrics, denoted by \u003ccode\u003ealloydb_omni_pgbouncer_\u003c/code\u003e, provide the current status of PgBouncer instances, such as its endpoint and phase, allowing users to monitor database connection pooling.\u003c/p\u003e\n"]]],[],null,["# Custom resource metrics for the AlloyDB Omni Kubernetes operator\n\nSelect a documentation version: 16.3.0keyboard_arrow_down\n\n- [Current (16.8.0)](/alloydb/omni/current/docs/reference/custom-resource-metrics-kubernetes-operator)\n- [16.8.0](/alloydb/omni/16.8.0/docs/reference/custom-resource-metrics-kubernetes-operator)\n- [16.3.0](/alloydb/omni/16.3.0/docs/reference/custom-resource-metrics-kubernetes-operator)\n- [15.12.0](/alloydb/omni/15.12.0/docs/reference/custom-resource-metrics-kubernetes-operator)\n- [15.7.1](/alloydb/omni/15.7.1/docs/reference/custom-resource-metrics-kubernetes-operator)\n- [15.7.0](/alloydb/omni/15.7.0/docs/reference/custom-resource-metrics-kubernetes-operator)\n\n\u003cbr /\u003e\n\nThis page describes the custom resource (CR) metrics for the AlloyDB Omni Kubernetes operator. The AlloyDB Omni Kubernetes operator exposes metrics constructed from custom resource manifests in a [Prometheus](https://prometheus.io/) format using [kube-state-metrics](https://kubernetes.io/docs/concepts/cluster-administration/kube-state-metrics/).\n\n\u003cbr /\u003e\n\n| **Note:** These metrics are only available on AlloyDB Omni Kubernetes operator version 1.3.0 and later.\n\nMetric types follow the definition of Prometheus metrics types. A Prometheus\nInfo metric is a special kind of Prometheus Gauge metric, which always has a\nvalue of 1 and has multiple labels carrying important information about the\ncorresponding AlloyDB Omni Kubernetes operator Custom Resource.\n\nTo learn how to enable custom resource metrics, see [Monitor AlloyDB Omni Kubernetes operator custom resources](/alloydb/omni/16.3.0/docs/monitor-kubernetes-operator-custom-resources).\n\nCustom Resource Definition (CRD) metadata labels\n------------------------------------------------\n\nAll custom resource metrics have the following labels that mark the group, version, and kind\nof the CRD. For more information, see\n[Kubernetes API concepts](https://kubernetes.io/docs/reference/using-api/api-concepts/).\nLabel definitions and naming are listed in the following table:\n\nDBCluster metrics\n-----------------\n\nDBCluster metrics are exposed from `DBCluster` resource manifests. All\nDBCluster metric names start with `alloydb_omni_dbcluster_`. All DBCluster\nmetrics have the following labels:\n\nThe labels in the following table will have an empty value ---and are\nconsidered equivalent to labels that don't exist per\n[Prometheus metric names and labels](https://prometheus.io/docs/concepts/data_model/#metric-names-and-labels)---\nif the relevant field isn't present in the DBCluster manifest.\n\nFailover metrics\n----------------\n\nFailover metrics are metrics exposed from the `Failover` resource manifest. All\nfailover metric names start with `alloydb_omni_failover_`. All Failover metrics\nhave the following labels:\n\nThe labels in the following table will have an empty value ---and are\nconsidered equivalent to labels that don't exist based on\n[Prometheus metric names and labels](https://prometheus.io/docs/concepts/data_model/#metric-names-and-labels)---\nif the relevant field isn't present in the Failover manifest.\n\nPgBouncer metrics\n-----------------\n\nPgBouncer metrics are metrics that are exposed from`PgBouncer` resource\nmanifests. All PgBouncer metric names start with `alloydb_omni_pgbouncer_`. All\nPgBouncer metrics have the following labels:\n\nThe labels in the following table will have an empty value ---and are\nconsidered equivalent to labels that don't exist based on\n[Prometheus metric names and labels](https://prometheus.io/docs/concepts/data_model/#metric-names-and-labels)---\nif the relevant field isn't present in the PgBouncer manifest..\n\nWhat's next\n-----------\n\n- [Monitor AlloyDB Omni Kubernetes operator custom resources](/alloydb/omni/16.3.0/docs/monitor-kubernetes-operator-custom-resources)."]]