grafana / grafana

The open and composable observability and data visualization platform. Visualize metrics, logs, and traces from multiple sources like Prometheus, Loki, Elasticsearch, InfluxDB, Postgres and many more.
https://grafana.com
GNU Affero General Public License v3.0
65.25k stars 12.17k forks source link

GeoMap Fit to data issue with International Date Line #95309

Open rpl-ian-lunam opened 1 month ago

rpl-ian-lunam commented 1 month ago

Why is this needed:

If "Fit to data" is enabled and the data points are not far either side of the International Date Line (ie: only two data points, one in Auckland, New Zealand (longitude: 174) and the other in Seattle (longitude: -122)) the map zooms out to the whole world (centred on South Sudan, longitude 26 I think) with Seattle top left, Auckland bottom right, and the whole rest of the world lays empty between them.

Image

What would you like to be added:

Somehow, determining the longitudinal spread based on circular separation instead of linear, so that in the above example it would centre on longitude -154. Obviously a reasonably easy calculation with just two data points, but a lot more complicated if there's more :)

Image

Who is this feature for?

Anyone with a more Pacific bias to their data.

swiffer commented 1 month ago

Duplicate of #89777

rpl-ian-lunam commented 4 weeks ago

Duplicate of #89777

Hi @swiffer

Sorry, but I don't think it is a duplicate of that ticket. It's not that it's zooming out, but that it centres the map wrong. If I have data all one side of the IDL it zooms fine.

One thing I forgot to mention is that this is cloud Grafana, not self hosted.

swiffer commented 4 weeks ago

yes, sorry. misunderstanding.