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: add multiple account support for dashboard widget nrql block #2784

Open
wants to merge 3 commits into
base: main
Choose a base branch
from

Conversation

vagrawal-newrelic
Copy link
Contributor

@vagrawal-newrelic vagrawal-newrelic commented Dec 17, 2024

Description

Please include a summary of the change and which issue is fixed (if relevant).
Added multiple account_ids field instead of account_id field to support for multiple account id selection for dashboard nrql block in widget.
Jira story: https://new-relic.atlassian.net/browse/NR-343906

Fixes # (issue)

Type of change

Please delete options that are not relevant.

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • This change requires a documentation update

Checklist:

Please delete options that are not relevant.

  • My commit message follows conventional commits
  • My code is formatted to Go standards
  • I have performed a self-review of my own code
  • I have made corresponding changes to the documentation
  • I have added tests that prove my fix is effective or that my feature works
  • New and existing unit tests pass locally with my changes. Go here for instructions on running tests locally.

How to test this change?

Please describe how to test your changes. Include any relevant steps in the UI, HCL file(s), commands, etc

-Add a list of multiple accountIds in the account_ids field for nrql block of dashboard widget.

  • perform a terraform apply
  • in UI the multi-account should be selected with multiple account selected.

@pranav-new-relic
Copy link
Member

@vagrawal-newrelic 👋

we cannot be renaming account_id to account_ids straightaway; as this would be a breaking change for most customers running Terraform configs in CI/CD which we wouldn't want them to be changing because of this change :)

we might need to think of an alternate approach to keep both account_id and account_ids and conditionally vary what's being used (and also in the RawConfiguration struct in the Go Client)

let's talk about this in detail sometime

@pranav-new-relic
Copy link
Member

one idea to consider is if we can edit the string/int to list in the Go Client, change account_id to a list here, but see if HCL supports ingesting a single account ID too as a list (to keep the format unchanged for those who want to use one account ID, i.e. our existing customers, and also for those new experimenters who would want to use multiple account IDs). You can try something out in this direction before we next get to discuss :)

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.

2 participants