Skip to content

Update Grafana to 9.5 #596

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

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

NikolayActionEngine
Copy link

Updating bundled Grafana to 9.5.21

I've been running this for a week and it looks that there are no degradation in the functionality of the dashboards.
Tesla animation works as before.

image

@NikolayActionEngine
Copy link
Author

@jasonacox FYI

@jasonacox
Copy link
Owner

Thanks @NikolayActionEngine - I'm running tests. So far so good...

What are your observations as to the benefits or enhancements of this upgrade?

@NikolayActionEngine
Copy link
Author

NikolayActionEngine commented Mar 3, 2025

If you look at when the original 9.1.2 image was built and published at Docker Hub - https://hub.docker.com/r/grafana/grafana/tags?name=9.1.2-ubuntu - it's 2 years old. I really don't like to run old SW if I don't have to, so moving it forward makes it much newer and a bit modern. 9.5.21 image is 7 months old: https://hub.docker.com/r/grafana/grafana/tags?name=9.5.21-ubuntu

Going to Grafana 10 might be a big jump, so going a bit forward (9.1 -> 9.5) seems like a reasonable upgrade path.
Shortcuts, a bit of navigation niceties, more release notes at https://grafana.com/docs/grafana/latest/whatsnew/whats-new-in-v9-5/ but realistically, making it more than a year newer and potentially not being affected by any glitches or bugs what people will never fix in 9.1 as it's EOL

@jasonacox
Copy link
Owner

Yes, the release upgrade benefits are a given from a bug fix aspect. I wanted to list any user experience improvements in the release notes and highlight any feature removals or breaking changes.

Shortcuts, a bit of navigation niceties, more release notes at https://grafana.com/docs/grafana/latest/whatsnew/whats-new-in-v9-5/

I looked at 9.2 - 9.5 - From what I can see the relevant highlights are:

New

New Navigation: Grafana's navigation has been updated with a new design and structure to make it easier to access data. The new navigation is generally available in all editions of Grafana.

Dashboards and Visualizations: The empty dashboard state has been redesigned to make it easier to start building from scratch. The dashboard panel has also been redesigned to improve accessibility and make it easier to understand the status of a panel.

Search and Navigation: Improved command palette for efficient navigation. New navigation design for easier access to features. Support for keyboard shortcuts (cmd + K on Mac, ctrl + K on Linux/Windows)

Language Support: Grafana now supports four new languages: Spanish, French, German, and Simplified Chinese. This will make it more accessible to a wider audience.

Overall, Grafana v9.5 includes several updates and improvements to make it easier to use and navigate, as well as new features to improve performance and usability.

Breaking Changes (future)

I flagged this as something we may need to address with the setup auto-provisioning:

InfluxDB Plugin Database Field Deprecation: The database field in the provisioning file has been deprecated, and the database field will be removed in the future.

Removal

Likely not impacting any of our community, but this is a removal:

API Key Deprecation: The creation of new API keys through the Grafana UI has been removed, and only service accounts can be created. This is part of Grafana's long-term strategy to sunset API keys.

@NikolayActionEngine
Copy link
Author

All highlighted points above are about what I would indicate as something worth checking (if people are interested in those). Navigation/shortcuts are probably most visible but they are optional (like a shortcuts) where people don't have to use them if not interested. Nothing which breaks the current stuff as far as I can see. Once we get to that 9.5 version, if there is an interest, we might attempt to go to Grafana 10/11 to get it up-to-date.

@hulkster
Copy link

hulkster commented Mar 6, 2025

As the person who started #371 in late/2023 about using a more recent version of Grafana, I gave this a shot after first upgrading to the latest 4.6.4 Powerwall.

9.5.21 appears to work fine ... EXCEPT ... it has a text-centering issue - see this thread that I referenced in #371 ... LOL that this not a bug, it's a feature! ;-) Ironically, several people created accounts over there just to chime that they wished there was a solution to easily provide centering. Note that I have customized my dashboard, so this may be specific to me ... just a heads-up to look closely and try wider screen widths which would make it easier to see left versus center justified.

Having said that, I agree with @NikolayActionEngine comments that it's generally better to run "newer" software (with reason) and would certainly welcome an eventual migration to Grafana 11.x.

@NikolayActionEngine
Copy link
Author

LOL that this not a bug, it's a feature!

Yes, it's unfortunate where upstream makes such decisions.

I don't mind that text is being left vs centered for the most part. It does seems like that might have been a simple feature for Grafana to make it an option to just let people decide which way to do it. However, they haven't done it and it doesn't seems like it's a hill to die on (so to speak). I'd say we get this 9.5.x into the code base, which will give a goodwill in that area and more incentive to people to push this forward to get Grafana eventually upgraded all the way through to the latest one (and fix whatever issues might be along the way).

@hulkster
Copy link

hulkster commented Mar 7, 2025

Roger all that @NikolayActionEngine - just pointing out a possible issue for people to watch out for ... so maybe worth mentioning when @jasonacox pushes to 9.5.x ... or higher! ;-)

Again, I've been running 9.4.x for a while and seems to work great ... and the only thing that looked amiss with 9.5.x was the text centering.

@jasonacox
Copy link
Owner

Testing grafana/grafana:9.4.15-ubuntu (9.4.17 fails to run on RPi) - Doesn't alter text centering issue (I agree, the left justify makes the meters look ugly). This is still a newer version. I do think I'll see if I can submit a PR to grafana to make the text placement an option. :)

@NikolayActionEngine
Copy link
Author

NikolayActionEngine commented Mar 7, 2025

Getting back centered titles without Grafana cooperating with us is not that hard (if you are ok with using a plugin for Chrome/Firefox like a "TamperMonkey" which allows to run scripts, https://chromewebstore.google.com/detail/tampermonkey/dhdgffkkebhmkfjojejmpbldmpobfkfo?pli=1).

If you install it, and create a new script (very simple), like this:

// ==UserScript==
// @name         Powerwall - centered titles
// @namespace    http://tampermonkey.net/
// @version      2025-03-07
// @description  try to take over the world!
// @author       You
// @match        http://powerwall.local:9000/*
// @icon         data:image/gif;base64,R0lGODlhAQABAAAAACH5BAEKAAEALAAAAAABAAEAAAICTAEAOw==
// @grant        none
// ==/UserScript==


function addGlobalStyle(css) {
    var head, style;
    head = document.getElementsByTagName('head')[0];
    if (!head) { return; }
    style = document.createElement('style');
    style.type = 'text/css';
    style.innerHTML = css;
    head.appendChild(style);
}

addGlobalStyle('[class*=\'-panel-title\'] { width: 100%; text-align: center; }');

With specifying @match the FQDN on where it shall apply (or a particular dashboard). Note in this case, it's http://powerwall.local:9000/* - so adjust it to have your own relevant IP/hostname.

Once it's working (you can test if it's working or not by using window.alert('test me'); inside of the script, temporarily), the titles will be centered again.

Like this:
image

Note that it's using the matcher for CSS to match any class which ends with -panel-title, so using the same approach anyone can change any bit of stying in a sort of "piecemeal" style without changing the overall theme or messing with Grafana.

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