

本文為英文版的機器翻譯版本，如內容有任何歧義或不一致之處，概以英文版為準。

# 使用 AWS Distro for OpenTelemetry 將高可用性資料傳送至 Amazon Managed Service for Prometheus
<a name="Send-high-availability-data-ADOT"></a>

AWS Distro for OpenTelemetry (ADOT) 是 OpenTelemetry 專案的安全且可供生產使用的分佈。ADOT 為您提供來源 API、程式庫和代理程式，因此您可以收集分散式追蹤和指標以進行應用程式監控。如需 ADOT 的相關資訊，請參閱[關於 AWS Distro for Open Telemetry](https://aws-otel.github.io/about)。

若要使用高可用性組態設定 ADOT，您必須設定 ADOT 收集器容器映像，並將外部標籤`cluster`和 `__replica__` 套用至 AWS Prometheus 遠端寫入匯出程式。此匯出程式會透過 `remote_write` 端點將您抓取的指標傳送到 Amazon Managed Service for Prometheus 工作區。當您在遠端寫入匯出程式上設定這些標籤時，可避免在執行備援複本時保留重複的指標。如需 AWS Prometheus 遠端寫入匯出器的詳細資訊，請參閱[適用於 Amazon Managed Service for Prometheus 的 Prometheus 遠端寫入匯出器入門](https://aws-otel.github.io/docs/getting-started/prometheus-remote-write-exporter)。

**注意**  
某些版本的 Kubernetes (1.28 和 1.29) 可能會發出自己的指標和`cluster`標籤。這可能會導致 Amazon Managed Service for Prometheus 重複資料刪除的問題。如需詳細資訊，請參閱[高可用性常見問答集](HA_FAQ.md#HA_FAQ_cluster-label)。