Skip to content

Fix reconciliation error for empty kubeletConfig with externally set subfields - #2973

Merged
google-oss-prow[bot] merged 1 commit into
GoogleCloudPlatform:masterfrom
jingyih:patch_kubelet_config
Oct 22, 2024
Merged

Fix reconciliation error for empty kubeletConfig with externally set subfields#2973
google-oss-prow[bot] merged 1 commit into
GoogleCloudPlatform:masterfrom
jingyih:patch_kubelet_config

Conversation

@jingyih

@jingyih jingyih commented Oct 22, 2024

Copy link
Copy Markdown
Contributor

Cherry pick the fix in GoogleCloudPlatform/magic-modules#11971.

This resolves the reconciliation error that occurs when kubeletConfig is empty in the user's configuration, but a subfield under kubeletConfig is set externally outside of KCC.

{"severity":"error","timestamp":"2024-10-21T23:33:23.865Z","logger":"containernodepool-controller","msg":"error applying desired state","resource":{"name":"test-b-374795345-10212024-pool","namespace":"default"},"error":"summary: googleapi: Error 400: At least one of ['node_version', 'image_type', 'updated_node_pool', 'locations', 'workload_metadata_config', 'upgrade_settings', 'kubelet_config', 'linux_node_config', 'tags', 'taints', 'labels', 'node_network_config', 'gcfs_config', 'gvnic', 'confidential_nodes', 'logging_config', 'fast_socket', 'resource_labels', 'accelerators', 'windows_node_config', 'machine_type', 'disk_type', 'disk_size_gb', 'storage_pools', 'containerd_config', 'resource_manager_tags', 'performance_monitoring_unit', 'queued_provisioning', 'max_run_duration'] must be specified.\nDetails:\n[\n  {\n    \"@type\": \"type.googleapis.com/google.rpc.RequestInfo\",\n    \"requestId\": \"0x19bb67b615f44eff\"\n  }\n]\n, badRequest"}

Tested locally in b/374795345.

…les/pull/11971

This should fix the reconciliation error when a subfield under
kubeletConfig is set outside of KCC/TF.
@jingyih

jingyih commented Oct 22, 2024

Copy link
Copy Markdown
Contributor Author

/cc @maqiuyujoyce @cheftako

@jingyih jingyih changed the title fix: cherry pick the fix in Terraform 11971 fix: mark "node_config[0].kubelet_config" as "computed" Oct 22, 2024
@maqiuyujoyce

Copy link
Copy Markdown
Collaborator

/lgtm

Deferring the approval to @cheftako .

@jingyih

jingyih commented Oct 22, 2024

Copy link
Copy Markdown
Contributor Author

Presubmit / tests-e2e-samples failed with

2024-10-22T16:59:35.0672593Z         --- FAIL: TestAllInSeries/samples/workerpool-with-peered-network (240.48s)

Tested locally the test passed. Will trigger a rerun.

@cheftako

Copy link
Copy Markdown
Collaborator

/lgtm
/approve

@google-oss-prow

Copy link
Copy Markdown
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: cheftako

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@google-oss-prow
google-oss-prow Bot merged commit f0a6e54 into GoogleCloudPlatform:master Oct 22, 2024
@jingyih jingyih changed the title fix: mark "node_config[0].kubelet_config" as "computed" fix: fix reconciliation error for empty kubeletConfig with externally set subfields Oct 23, 2024
@jingyih jingyih changed the title fix: fix reconciliation error for empty kubeletConfig with externally set subfields Fix reconciliation error for empty kubeletConfig with externally set subfields Oct 23, 2024
@yuwenma yuwenma added this to the 1.124 milestone Oct 25, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants