-
Notifications
You must be signed in to change notification settings - Fork 33
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
Make meta data converter mapping generic and populate provisioner meta info #380
Conversation
Codecov ReportAttention:
Additional details and impacted files@@ Coverage Diff @@
## main #380 +/- ##
=======================================
Coverage 25.36% 25.36%
=======================================
Files 195 195
Lines 16810 16810
=======================================
Hits 4264 4264
Misses 12328 12328
Partials 218 218 ☔ View full report in Codecov by Sentry. |
9e90b90
to
c178b75
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
…a info Signed-off-by: Shobha M <mshobha@vmware.com>
c178b75
to
8aaa942
Compare
@shobha2626 - Does the state file dump given in description captures the state file info with LIST or GET datasource? If it's just GET can you add the LIST too? As there are changes to common meta converter code have you validated the automation against your change? |
@ramya-bangera I have captured only GET because the result for LIST is huge. I have verified the LIST as well, if needed I can run again and share the same. |
Thanks for confirming , since these details was missing I just wanted to be sure that it is validated. |
I'm going to lock this pull request because it has been closed for 30 days. This helps our maintainers find and focus on the active issues. If you have found a problem that seems related to this change, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further. |
Make meta data converter mapping generic and populate provisioner meta info
Meta converter was not supporting the array format as that of a provisioner resource. As a result, meta was not getting populated for provisioner because the model path was not including the entire path. In Provisioner resource scenario the meta should be
provisioner.meta
.Made changes to accomodate this change not just for provisioner but any resource that follows this structure
{ "version": 4, "terraform_version": "1.6.4", "serial": 1, "lineage": "2dcd02f2-3dcc-d8a3-42b1-f05b03f9e9fe", "outputs": {}, "resources": [ { "mode": "data", "type": "tanzu-mission-control_provisioner", "name": "read_provisioner", "provider": "provider[\"vmware/devd/tanzu-mission-control\"]", "instances": [ { "schema_version": 0, "attributes": { "id": "prvn:01HQ2DV4SAY0C5G832WHZ4TBST", "provisioners": [ { "management_cluster": "eks", "meta": [ { "annotations": {}, "description": "Create provisioner through terraform", "labels": { "key1": "value1", "key2": "value2" }, "resource_version": "4965", "uid": "prvn:01HQ2DV4SAY0C5G832WHZ4TBST" } ], "name": "mshobha-test", "org_id": "" } ] }, "sensitive_attributes": [] } ] } ], "check_results": null }
Additional information
Special notes for your reviewer