Monitoring / Open Source / Tools

Grafana 7.5: Controversial Pie Charts and Loki Alerts

12 Apr 2021 12:19pm, by

Grafana Labs has introduced a number of features to its popular observability platform ahead of what will be perhaps its most major release of the year when it launches Grafana 8.0 in June.

The updates were made in large part from the feedback of the active Grafana open source community. “The usability improvements, the tighter integration with Grafana and third-party software and the query caching all address frustration points that can be found out there in the wild,” Torsten Volk, an analyst for Enterprise Management Associates (EMA), told The New Stack. “While this is an incremental release, it might generally increase end-user happiness, and that’s what is key for Grafana to stay ahead in the observability race.

Users should particularly appreciate the new updates around Loki, including the ability to create alerts on Loki metric queries, as well as a new logs browser that lets users search based on specific labels and values, Daniel Lee, a team lead for Grafana Labs, told The New Stack. “In particular, the Logs browser eliminates scrolling through potentially hundreds of labels to identify a log stream, replacing a time-intensive process with an intuitive search process,” Lee told The News Stack.

As for the introduction of the pie charts among other new features, there is some background associated with the feature — some of which is not without controversy. Grafana Labs, in fact, already acknowledged a large number of requests on GitHub and at conferences to offer pie charts in a 2015 blog post. However, in many cases, these requests were seen as a way to appease the business folks and were not that important for Grafana’s main reason of being in the first place: to offer very accessible metrics for application performance observability. The risk, Matt Toback wrote in 2015, is that pie charts “can get in the way of the data.”

Among the reasons why “pie charts are bad,” Toback described the following drawback in the context of observability: visual CPU overload, over-reliance on color, ineffectiveness  for time series data and how “pies aren’t meant to grow.”

“Pie charts obstruct data when there are more than 2-3 clearly defined segments,” Toback wrote. “Anything more and it becomes nearly impossible to quickly discern the differences in values.”

Meanwhile, while noting that pie charts have been continued to be a commonly requested feature for Grafana since the early days of its creation and pie charts have “been much aligned,” the option to visual metrics data in this way is one of the key new capabilities Grafana 7.5, Lee wrote in a blog post.

“While we introduced a basic pie chart panel a few years ago, it was never a built-in visualization option for Grafana,” Lee wrote. “With 7.5, we’re introducing a new and improved pie chart panel (beta), and it’s now a first-class citizen in the Grafana visualization library. The panel is a complete rewrite, with standard styling, legends, overrides, and fields in line with the other built-in visualizations.”

While pie charts might look nice and are not critical for observability metrics, they could still be useful, Volk said. “While I’m not overly passionate one way or the other, I believe pie charts can have their place when used sparingly and within the right context,” Volk said. “I haven’t seen the ‘guardrails’ they built into the current implementation, but let’s leave it to the dashboard designers whether or not to go down the piechart rabbit hole.”

Other new capabilities Lee communicated that Grafana 7.5 offers include:

  • Alerting support for Loki: LogQL, the Loki query language, “allows you to create metrics out of logs, and 7.5 enables you to create alerts on these Loki metric queries.”
  • Loki label browse: Instead of having to manually scroll through a drop-down list of labels to find a log stream in a query editor, a new logs browser allows users to “construct a query with labels and values of your choice.”
  • Grafana Tempo Added as a Backend Data Source: a distributed-tracing backend.
  • Tempo has been converted “to a backend data source.” “This means that there is no longer support for tempo-query’s Jaeger response,” Lee wrote. “Simply point to the port that is set in the Tempo configuration file to configure the data source.”
  • Query caching in Grafana Enterprise: Grafana now temporarily stores the results of data source queries. This capability enables faster dashboard load times, reduces API costs, and lowers the likelihood that APIs will rate-limit or throttle requests,” Lee wrote.

“These and other new capabilities are especially helpful to the community because they continue to make Grafana both easier to use and more powerful, as well as lowering the barrier of entry to the platform and helping to bring more people into the Grafana community,” Lee said.

A newsletter digest of the week’s most important stories & analyses.