Skip to content

refactor: license resource and data source #2436

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

Merged
merged 1 commit into from
May 6, 2025
Merged

Conversation

tenthirtyam
Copy link
Contributor

@tenthirtyam tenthirtyam commented Apr 27, 2025

Description

Important

TESTED AND READY

Refactors r/license and d/license.

Introduces the use of hashicorp/terraform-plugin-log for logging.

And ensures that the license key is not leaked in logs by masking the key in the following form:

 License operation: Reading license data source: key_length=29 masked_key="XXXX*********************XXXX" tf_rpc=ReadDataSource @module=provider tf_data_source_type=vsphere_license tf_provider_addr=provider tf_req_id=06693533-cf1d-86bd-d167-dcd9189f212a @caller=F:/GitHub/terraform-provider-vsphere/vsphere/internal/helper/license/license_helper.go:36 timestamp="2025-05-01T20:58:11.962+0100"

@tenthirtyam tenthirtyam added technical-debt Technical Debt refactor Refactor labels Apr 27, 2025
@tenthirtyam tenthirtyam added this to the v2.13.0 milestone Apr 27, 2025
@tenthirtyam tenthirtyam self-assigned this Apr 27, 2025
@tenthirtyam tenthirtyam force-pushed the refactor/r-d-license branch 2 times, most recently from 5f77e46 to 25af67b Compare April 27, 2025 17:26
@tenthirtyam tenthirtyam removed this from the v2.13.0 milestone Apr 27, 2025
@tenthirtyam tenthirtyam requested a review from spacegospod April 29, 2025 16:24
@tenthirtyam tenthirtyam force-pushed the refactor/r-d-license branch 7 times, most recently from a43dc4e to 6d66166 Compare May 1, 2025 19:48
@tenthirtyam tenthirtyam added this to the v2.13.0 milestone May 1, 2025
@tenthirtyam tenthirtyam changed the title [wip] refactor: license resource and data source refactor: license resource and data source May 1, 2025
@tenthirtyam tenthirtyam requested a review from iBrandyJackson May 1, 2025 19:50
@tenthirtyam tenthirtyam marked this pull request as ready for review May 1, 2025 19:50
@tenthirtyam tenthirtyam requested a review from a team as a code owner May 1, 2025 19:50
@tenthirtyam tenthirtyam force-pushed the refactor/r-d-license branch from 6d66166 to 53e0158 Compare May 1, 2025 21:14
@tenthirtyam tenthirtyam force-pushed the main branch 2 times, most recently from 2d0d0cd to 3ebb159 Compare May 6, 2025 00:35
@tenthirtyam tenthirtyam added the needs-review Needs Review label May 6, 2025
@tenthirtyam tenthirtyam force-pushed the refactor/r-d-license branch from 53e0158 to 6b3f87e Compare May 6, 2025 01:36
@github-actions github-actions bot added dependencies Dependencies provider Provider chore Chore labels May 6, 2025
@tenthirtyam tenthirtyam force-pushed the refactor/r-d-license branch 2 times, most recently from ea8c9af to 5c545f8 Compare May 6, 2025 02:34
@tenthirtyam tenthirtyam force-pushed the refactor/r-d-license branch 4 times, most recently from 02febf5 to 45c6dfb Compare May 6, 2025 12:11
@tenthirtyam tenthirtyam marked this pull request as draft May 6, 2025 15:10
@tenthirtyam tenthirtyam marked this pull request as ready for review May 6, 2025 15:11
Copy link
Member

@dougm dougm left a comment

Choose a reason for hiding this comment

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

lgtm

Refactors `r/license` and `d/license` and introduces the use of `hashicorp/terraform-plugin-log` for logging.

Signed-off-by: Ryan Johnson <[email protected]>
@tenthirtyam tenthirtyam force-pushed the refactor/r-d-license branch from 45c6dfb to da01590 Compare May 6, 2025 21:34
@tenthirtyam tenthirtyam merged commit dea5add into main May 6, 2025
9 checks passed
@tenthirtyam tenthirtyam deleted the refactor/r-d-license branch May 6, 2025 21:38
@tenthirtyam tenthirtyam removed the needs-review Needs Review label May 6, 2025
Copy link

This functionality has been released in v2.13.0 of the Terraform Provider. Please see the Terraform documentation on provider versioning or reach out if you need any assistance upgrading.

For further feature requests or bug reports with this functionality, please create a new GitHub issue following the template. Thank you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
chore Chore dependencies Dependencies provider Provider refactor Refactor technical-debt Technical Debt
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants