Skip to content

APPZ-2108 AccoundId based datasource - migration support#3

Merged
Gavriel-M merged 1 commit intomain-logziofrom
APPZ-2108-renaming-account-breaks-dashboards
Mar 2, 2026
Merged

APPZ-2108 AccoundId based datasource - migration support#3
Gavriel-M merged 1 commit intomain-logziofrom
APPZ-2108-renaming-account-breaks-dashboards

Conversation

@Gavriel-M
Copy link

This pull request addresses an issue where renaming an account (datasource) could break dashboards by improving how datasource variables are resolved and matched. The changes enhance the robustness of datasource selection by ensuring that both display names and selector names are considered when resolving variables, making the component more resilient to renames.

Improvements to datasource variable resolution:

  • Updated the logic for mapping variable values to datasources in DatasourceSelect to check both the display name and the selector name, ensuring that dashboards continue to function even if a datasource is renamed.
  • Modified the datasourceSelectValueToSelector function to match datasource variables using both the datasource's display name and selector name, improving reliability when resolving selectors from variables.

Code cleanup:

  • Removed the unused parseVariables import from DatasourceSelect.tsx.

Signed-off-by: gavriel-m <MGavrielG@Gmail.com>
Copy link
Collaborator

@galangel galangel left a comment

Choose a reason for hiding this comment

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

Some questions that you need to be able to answer before merging:

  • What happens when there are two accounts with the same name? Is it possible?
  • Are you comparing case sensitive? ( regarding prev question )
  • Is this a one-time pass, or every visit will require this?

@Gavriel-M Gavriel-M merged commit 960cc5a into main-logzio Mar 2, 2026
14 checks passed
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.

4 participants