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
Send grafana link with dashboard data #85
Conversation
If the URL for the engine's grafana instance is available from the `database_data` fetch, render the link in the upper right hand side of the dashboard. This allows the user to click directly to the monitoring portal without jumping back to the welcome page first. Bug-Url: https://bugzilla.redhat.com/show_bug.cgi?id=1991482 Require ovirt-engine PR: oVirt/ovirt-engine#85
If the URL for the engine's grafana instance is available from the `dashboard_data` fetch, render the link in the upper right hand side of the dashboard. This allows the user to click directly to the monitoring portal without jumping back to the welcome page first. If no URL is provided from the `dashboard_data` fetch, no link is rendered. Bug-Url: https://bugzilla.redhat.com/show_bug.cgi?id=1991482 Require ovirt-engine PR: oVirt/ovirt-engine#85
This PR is a requirement for oVirt/ovirt-engine-ui-extensions#33. |
If the URL for the engine's grafana instance is available from the `dashboard_data` fetch, render the link in the upper right hand side of the dashboard. This allows the user to click directly to the monitoring portal without jumping back to the welcome page first. If no URL is provided from the `dashboard_data` fetch, no link is rendered. Bug-Url: https://bugzilla.redhat.com/show_bug.cgi?id=1991482 Require ovirt-engine PR: oVirt/ovirt-engine#85
...ontend/src/main/java/org/ovirt/engine/ui/frontend/server/dashboard/DashboardDataServlet.java
Outdated
Show resolved
Hide resolved
...ontend/src/main/java/org/ovirt/engine/ui/frontend/server/dashboard/DashboardDataServlet.java
Outdated
Show resolved
Hide resolved
...ontend/src/main/java/org/ovirt/engine/ui/frontend/server/dashboard/DashboardDataServlet.java
Outdated
Show resolved
Hide resolved
c465563
to
d706144
Compare
The URL lookup now only considers the URL config key and does not report any error if it is missing. Reporting error like this to the server log duplicates what is done in the |
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.
The URL lookup now only considers the URL config key and does not report any error if it is missing. Reporting error like this to the server log duplicates what is done in the
BrandingManager
.
There is one problem with that approach of avoid validating the conf file:
If the 10-setup-grafana-access.conf file doesn't include the ENGINE_GRAFANA_FQDN parameter for some reason or the parameter exists but no value is set, then branding will raise an error and "Monitoring Portal" entry won't be added to welcome page, but it will be added to oVirt dashboard and point to https:///ovirt-engine-grafana/ which is always a wrong url.
Maybe worth just checking that those 2 parameters are set to something.
d706144
to
92d12a7
Compare
The code now checks to make sure both of the grafana keys are not blank before returning the URL. |
If the URL for the engine's grafana instance is available from the `dashboard_data` fetch, render the link in the upper right hand side of the dashboard. This allows the user to click directly to the monitoring portal without jumping back to the welcome page first. If no URL is provided from the `dashboard_data` fetch, no link is rendered. Bug-Url: https://bugzilla.redhat.com/show_bug.cgi?id=1991482 Require ovirt-engine PR: oVirt/ovirt-engine#85
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.
Please see my comment.
...ontend/src/main/java/org/ovirt/engine/ui/frontend/server/dashboard/DashboardDataServlet.java
Outdated
Show resolved
Hide resolved
If the URL for the engine's grafana instance is available from the `dashboard_data` fetch, render the link in the upper right hand side of the dashboard. This allows the user to click directly to the monitoring portal without jumping back to the welcome page first. If no URL is provided from the `dashboard_data` fetch, no link is rendered. Bug-Url: https://bugzilla.redhat.com/show_bug.cgi?id=1991482 Require ovirt-engine PR: oVirt/ovirt-engine#85
51a8049
to
b7e16ef
Compare
@avlitman We are passing engine FQDN into remote DWH installation, but do we have some where engine stored the information about remote DWH FQDN so we can provide a link to remote Grafana installation in webadmin dashboard? |
Hi, yes we are passing engine FQDN into DWH in all cases (remote or local). To sum it up I think the best way is to use those 2 parameters, and as Sharon said check that those 2 parameters are set to something. |
To be able to display a link to the Montioring Portal on the dashboard on `ovirt-engine-ui-extensions`, the link needs to be passed along with the rest of the dashboard info. If grafana is not configured on the engine, `null` is returned. Bug-Url: https://bugzilla.redhat.com/show_bug.cgi?id=1991482
4d7890b
to
e64377b
Compare
@sjd78 +1 Thank you, much appreciated! so should I open a second bug for that? |
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
* Add link to Monitoring Portal on Dashboard If the URL for the engine's grafana instance is available from the `dashboard_data` fetch, render the link in the upper right hand side of the dashboard. This allows the user to click directly to the monitoring portal without jumping back to the welcome page first. If no URL is provided from the `dashboard_data` fetch, no link is rendered. Bug-Url: https://bugzilla.redhat.com/show_bug.cgi?id=1991482 Require ovirt-engine PR: oVirt/ovirt-engine#85 * remove unused styles * adjust monitoring link styles to PF4 CSS vars
* Add link to Monitoring Portal on Dashboard If the URL for the engine's grafana instance is available from the `dashboard_data` fetch, render the link in the upper right hand side of the dashboard. This allows the user to click directly to the monitoring portal without jumping back to the welcome page first. If no URL is provided from the `dashboard_data` fetch, no link is rendered. Bug-Url: https://bugzilla.redhat.com/show_bug.cgi?id=1991482 Require ovirt-engine PR: oVirt/ovirt-engine#85 * remove unused styles * adjust monitoring link styles to PF4 CSS vars
To be able to display a link to the Montioring Portal on the
dashboard on
ovirt-engine-ui-extensions
, the link needs to bepassed along with the rest of the dashboard info. If grafana is
not configured on the engine, null is returned.
Bug-Url: https://bugzilla.redhat.com/show_bug.cgi?id=1991482