dapperlabs-platform / terraform-confluent-official-kafka-cluster

Apache License 2.0
1 stars 2 forks source link

Fix issue where ccloud_exporter can't fetch Confluent Cloud metrics #14

Closed vpolikarpov closed 2 years ago

vpolikarpov commented 2 years ago

ccloud exporter doesn't work currently. Here is an error from log:

Received status code 403 instead of 200 for GET on https://api.telemetry.confluent.cloud/v2/metrics/cloud/descriptors/resources.
{"error":{"code":403,"message":"invalid API key: make sure you're using a Cloud API Key and not a Cluster API Key: https://docs.confluent.io/cloud/current/api.html#section/Authentication"}}

According to this message Cloud API Key should be used to fetch metrics instead of Kafka API Key.

Confluent Cloud Terraform Provider docs say that we should omit managed_resource block in confluent_api_key definition in order to create Cloud API Key.