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

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

Merged

Conversation

jingyih
Copy link
Collaborator

@jingyih jingyih commented Oct 22, 2024

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
Copy link
Collaborator Author

jingyih commented Oct 22, 2024

/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
Collaborator

/lgtm

Deferring the approval to @cheftako .

@jingyih
Copy link
Collaborator Author

jingyih commented Oct 22, 2024

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
Collaborator

/lgtm
/approve

Copy link
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

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
15 checks passed
@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