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

[FEATURE] Allow customizing dashboard UID #214

Open
sourcehawk opened this issue Sep 21, 2023 · 0 comments
Open

[FEATURE] Allow customizing dashboard UID #214

sourcehawk opened this issue Sep 21, 2023 · 0 comments
Assignees

Comments

@sourcehawk
Copy link

Is your feature request related to a problem? Please describe.

  • Knowing the dashboard UID beforehand can be useful when creating links to dashboards in alerts etc. Currently one has to upload the dashboards before the dashboard link can be determined.
  • Long hashes are only useful when you don't need to know the UID

Describe the solution you would like to see

  • Allow adding uid parameter to plugins to overwrite the default hash created in dashboard renderer.

How would you expect this feature to work

Within MyApp.PromEx module

@impl true
  def plugins do
    [
      # Injecting dashboard uid's 
      {Plugins.Application, dashboard_uid: "myapp_application"}
      {Plugins.PhoenixLiveView, dashboard_uid: "myapp_phoenix_liveview"}
      {Plugins.Ecto, dashboard_uid: "myapp_ecto"}
      {Plugins.Oban, dashboard_uid: "myapp_oban"}
      {Plugins.Beam, dashboard_uid: "myapp_beam"}
    ]
  end

Additional context

This is the main functionality that would have to be updated: https://github.com/akoutmos/prom_ex/blob/master/lib/prom_ex/dashboard_renderer.ex#L90C3-L90C3 (dashboard renderer)

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

No branches or pull requests

2 participants