Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add a
logging_variant
field to GKE node pools and to node pool defa…
…ults for GKE clusters. (#6744) (#13049) This PR implements the feature request from [Add GKE logging variant field for increasing log agent throughput #12667](#12667). By adding a logging_variant field within the node_pool_defaults, GKE users will be able to select a cluster-wide default value for the logging agent of the node pools in a cluster. For example, by specifying ```terraform resource "google_container_cluster" "with_logging_variant_node_pool_default" { name = "example-cluster" location = "us-central1-f" initial_node_count = 1 node_pool_defaults { node_config_defaults { logging_variant = "MAX_THROUGHPUT" } } } ``` every newly created node pool in the cluster will have the max throughput logging agent unless this is explicitly overridden at the node pool level (see the [GKE docs](https://cloud.google.com/stackdriver/docs/solutions/gke/managing-logs#high_throughput_for_all_nodes_in_a_cluster) for more information). GKE users will also be able to select a logging variant at the node pool level. For example, by specifying ```terraform resource "google_container_cluster" "with_logging_variant_node_pool_default" { name = "example-cluster" location = "us-central1-f" initial_node_count = 1 node_pool_defaults { node_config_defaults { logging_variant = "DEFAULT" } } } resource "google_container_node_pool" "with_high_throughput_logging_variant" { name = "example-node-pool-0" cluster = google_container_cluster.with_logging_variant_node_pool_default.name } resource "google_container_node_pool" "with_high_throughput_logging_variant" { name = "example-node-pool-1" cluster = google_container_cluster.with_logging_variant_node_pool_default.name node_config { logging_variant = "MAX_THROUGHPUT" } } ``` example-node-pool-0 (as well as the default node pool) will have the default logging agent (see the [GKE docs](https://cloud.google.com/stackdriver/docs/solutions/gke/managing-logs#high_throughput_for_all_nodes_in_a_cluster) for more information), but example-node-pool-1 will have the max throughput agent. Signed-off-by: Modular Magician <magic-modules@google.com> Signed-off-by: Modular Magician <magic-modules@google.com>
- Loading branch information
1 parent
7c98257
commit eca88a2
Showing
7 changed files
with
382 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
```release-note:enhancement | ||
container: Added `node_pool_defaults.node_config_defaults.logging_variant`, `node_pool.node_config.logging_variant`, and `node_config.logging_variant` to `google_container_cluster`. | ||
``` | ||
```release-note:enhancement | ||
container: Added `node_config.logging_variant` to `google_container_node_pool`. | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.