Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Conversation

sasthana-ld
Copy link

@sasthana-ld sasthana-ld commented Sep 9, 2025

Adds archived boolean field to launchdarkly_metric resource to allow users to mark metrics as archived through Terraform.

added TO-DO comments for api client since ldapi.MetricPost does not support Archived field yet so when LD api client is merged I will uncomment the archived field code in create/update operations

made changes as we have discussed in Tech spec: https://docs.google.com/document/d/1HKRRgdSnHoXjrLnzRY9_7hQw4Q5pW9Q_AQdpO0wTm9w/edit?tab=t.0#heading=h.lcgpt7k0oisq

Jira Ticket: https://launchdarkly.atlassian.net/browse/MTRX-1308

DB PR: https://github.com/launchdarkly/gonfalon/pull/51985
Backend PR: https://github.com/launchdarkly/gonfalon/pull/51995

Wait!

  • Have you added comprehensive tests?
  • Have you updated relevant data sources as well as resources?
  • Have you updated the docs?

Testing

For any changes you make, please ensure your acceptance test conform to the following:

  • every single new attribute is tested
  • optional attributes revert to null or default values if removed
  • attributes that interact interact as expected
  • block values behave as expected when reordered
  • nested fields on maps or list/set items function as expected. Terraform does not actually enforce most schema attributes on nested items
  • each test step for a configuration is followed by a test step where ImportState and ImportStateVerify are set to true. ImportStateVerifyIgnore can be used if we explicitly expect a value to be different when imported, such as in the case of obfuscated values like API keys

LaunchDarkly Employees

For more information on how to build, test, and release, see the internal provider runbook.


Related Jira issue: MTRX-1308: Add archived field support to launchdarkly_metric Terraform resource

@sasthana-ld sasthana-ld requested review from a team as code owners September 9, 2025 10:25
@launchdarkly-upra launchdarkly-upra bot changed the title feat: Add archived field to launchdarkly_metrics resources feat: [MTRX-1308] Add archived field to launchdarkly_metrics resources Sep 9, 2025
@sasthana-ld sasthana-ld marked this pull request as draft September 9, 2025 10:42
@sasthana-ld sasthana-ld force-pushed the MTRX-1308-add-archived-field-support-to-launchdarkly-metric-terraform-resource branch from df4ce49 to 165ed1f Compare September 9, 2025 10:49
@sasthana-ld sasthana-ld force-pushed the MTRX-1308-add-archived-field-support-to-launchdarkly-metric-terraform-resource branch from 165ed1f to 5ced881 Compare September 9, 2025 13:47
launchdarkly/metrics_helper.go Outdated Show resolved Hide resolved
launchdarkly/metrics_helper.go Outdated Show resolved Hide resolved
Copy link
Contributor

@ldhenry ldhenry left a comment

Choose a reason for hiding this comment

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

Looking good so far. Feel free to request a review of myself or @sloloris when you are ready.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants

Morty Proxy This is a proxified and sanitized view of the page, visit original site.