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

feat(fgs/function): new LTS parameter is supported and other LTS parameters supports update #6441

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

Lance52259
Copy link
Contributor

@Lance52259 Lance52259 commented Mar 3, 2025

What this PR does / why we need it:
New parameter is supported: lts_custom_tag
Currently, only cn-north-7, cn-north-9 and cn-east-3 are available.
And the LTS parameters (log_group_name, log_group_id, log_stream_name, log_stream_id) does not supports update logic.

Which issue this PR fixes:
(optional, in fixes #<issue number>(, fixes #<issue_number>, ...) format, will close that issue when PR gets merged)
fixes #xxx

Special notes for your reviewer:

Release note:

1. resource supports lts_custom_tag parameter.
2. old LTS parameters supports update logic.

PR Checklist

  • Tests added/passed.
./scripts/coverage.sh -o fgs -f TestAccFunction_logConfig
Prepare to calculate the coverage the following command:
TF_ACC=1 go test "./huaweicloud/services/acceptance/fgs" -v -coverprofile="./huaweicloud/services/acceptance/fgs/fgs_coverage.cov" -coverpkg="./huaweicloud/services/fgs" -run TestAccFunction_logConfig -timeout 360m -parallel 10
=== RUN   TestAccFunction_logConfig
=== PAUSE TestAccFunction_logConfig
=== CONT  TestAccFunction_logConfig
--- PASS: TestAccFunction_logConfig (25.00s)
PASS
coverage: 14.3% of statements in ./huaweicloud/services/fgs
ok      github.com/huaweicloud/terraform-provider-huaweicloud/huaweicloud/services/acceptance/fgs       25.052s coverage: 14.3% of statements in ./huaweicloud/services/fgs
  • Documentation updated.
  • Schema updated.
  • CheckDeleted.

@github-ci-robot
Copy link
Collaborator

[APPROVALNOTIFIER] This PR is APPROVED

This PR has been approved by: @Lance52259

@github-ci-robot github-ci-robot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Mar 3, 2025
@Lance52259 Lance52259 force-pushed the br_fgs_function_log_tags branch from 39bb997 to 46e28bb Compare March 3, 2025 08:28
@github-actions github-actions bot added size/M and removed size/XS labels Mar 3, 2025
@Lance52259 Lance52259 changed the title feat(fgs/function): resource supports lts_custom_tag parameter feat(fgs/function): new LTS parameter is supported and other LTS parameters supports update Mar 3, 2025
@Lance52259 Lance52259 force-pushed the br_fgs_function_log_tags branch from 46e28bb to a6c02c3 Compare March 3, 2025 09:28
@Lance52259 Lance52259 force-pushed the br_fgs_function_log_tags branch from a6c02c3 to a7de022 Compare March 5, 2025 01:53
@@ -1598,6 +1615,7 @@ func resourceFunctionRead(_ context.Context, d *schema.ResourceData, meta interf
function, make(map[string]interface{})).(map[string]interface{}))),
d.Set("gpu_type", utils.PathSearch("gpu_type", function, nil)),
d.Set("gpu_memory", utils.PathSearch("gpu_memory", function, nil)),
d.Set("lts_custom_tag", utils.PathSearch("lts_custom_tag", function, nil)),
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

According to the latest specifications, it is required to add an all map attribute field, and the original map field will not be backfilled.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. feature needs-rebase size/M
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants