Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

monitoring_config and logging_config broken on new clusters: Error: googleapi: Error 400: Cannot specify logging_config or monitoring_config together with logging_service or monitoring_service., badRequest #1144

Closed
thomas-riccardi opened this issue Feb 3, 2022 · 6 comments · Fixed by #1240
Labels
bug Something isn't working

Comments

@thomas-riccardi
Copy link

TL;DR

monitoring_config and logging_config fail on new cluster.

Since 19.0.0, #1028 added monitoring_config and logging_config replacing notably cluster_telemetry_type.

It worked great when upgrading an existing cluster that previously used cluster_telemetry_type; but it failed when creating a new cluster from scratch.

Expected behavior

cluster is created successfully with defined monitoring & logging config.

Observed behavior

on a new cluster:

Error: googleapi: Error 400: Cannot specify logging_config or monitoring_config together with logging_service or monitoring_service., badRequest
with module.gke_cluster.google_container_cluster.primary
on .terraform/modules/gke_cluster/modules/beta-public-cluster-update-variant/cluster.tf line 22, in resource "google_container_cluster" "primary":

(it did work when upgrading an existing cluster from cluster_telemetry_type with module v17 to monitoring_config and logging_config with module v19)

Terraform Configuration

module "gke_cluster" {
  source  = "terraform-google-modules/kubernetes-engine/google//modules/beta-public-cluster-update-variant"
  version = "19.0.0"
  ...
  # cluster_telemetry_type = "SYSTEM_ONLY"
  logging_enabled_components    = ["SYSTEM_COMPONENTS"]
  monitoring_enabled_components = ["SYSTEM_COMPONENTS", "WORKLOADS"]
}

Terraform Version

Terraform v1.1.4
on linux_amd64
+ provider registry.terraform.io/hashicorp/external v2.2.0
+ provider registry.terraform.io/hashicorp/google v4.9.0
+ provider registry.terraform.io/hashicorp/google-beta v4.9.0
+ provider registry.terraform.io/hashicorp/kubernetes v2.7.1
+ provider registry.terraform.io/hashicorp/null v3.1.0
+ provider registry.terraform.io/hashicorp/random v3.1.0

Additional information

I'm not alone to have reported it: #1028 (comment)

@thomas-riccardi thomas-riccardi added the bug Something isn't working label Feb 3, 2022
@skakauridze-clgx
Copy link

We are also experiencing the exact same issue +1

f2049312e72c] 11:11:48 ╷ 11:11:48 │ Error: googleapi: Error 400: Cannot specify logging_config or monitoring_config together with logging_service or monitoring_service., badRequest 11:11:48 │

Also there is another probably related issue: hashicorp/terraform-provider-google#10361

@github-actions
Copy link

This issue is stale because it has been open 60 days with no activity. Remove stale label or comment or this will be closed in 7 days

@github-actions github-actions bot added the Stale label Apr 10, 2022
@thomas-riccardi
Copy link
Author

(commenting to make @github-actions happy)

I have not tested recently, but didn't see any movement regarding this issue; I assume it's still there.

@awx-fuyuanchu
Copy link

Any updates?

@BrettNWoods
Copy link

Any progress on this one?

@night-gold
Copy link

Removing the logging_service and monitoring_service fields is the only way I found to make it work as the default options is what I use anyway and I want to manage the configuration.
Would be a lot more problematic if you want to use the none default loging but in that cas removing the config field associated may do the trick.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
5 participants