Giter Site home page Giter Site logo

orchestracities / map-panel Goto Github PK

View Code? Open in Web Editor NEW
23.0 6.0 12.0 30.04 MB

This plugin extends Grafana Geomap panel with several functionalities: Support for GeoJSON shapes, Support for icons, Support for pop up visualizations of data from a specific point, Multiple layers for the different queries.

Home Page: https://grafana.com/grafana/plugins/orchestracities-map-panel/

License: GNU Affero General Public License v3.0

JavaScript 0.81% CSS 9.44% Shell 7.42% TypeScript 82.32%
grafana grafana-plugin grafana-panel-plugin grafana-panel grafana-map geo geodata geojson map-visualization

map-panel's People

Contributors

bulletfactory avatar chicco785 avatar daniellee avatar dependabot[bot] avatar ftcardoso avatar linkslice avatar modulartaco avatar moooji avatar samhatchett avatar taliaga avatar valecant avatar whitesteindevelopment avatar wt-jb avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar

map-panel's Issues

geoJson polygons: Color not changing with change in timerange

Hello, and thank you for making this awsome plugin. I have been in the need of a map panel that can draw polygons and color them by data for a while now and stumbled upon this one yesterday.

The issue is that the color of polygons doesn't change when i change the timerange (and in return the "color by" attribute). The attributes of the polygons does change and is correctly shown when hovering over a feature, but in order to redraw the polygons with the correct color from the new data i need to do a full page refresh.

This seems to only be an issue with the polygon type from geoJson. (and maybe linestring type, haven't testet that).
When i use either points from lat/lon or type point from geoJson, the points are re-rendered with new colors on change in timerange as expected.

Tested with:
Grafana 8.3.0
Postgres13 (with postgis and timescale extensions)
Browser: Chrome

Best regards,

Eivind

Make feature stroke width configureable

Having many polygons next to each other makes the stroke overlap. When zoomed out, only the top rendered polygons appear. That makes it look like only the top rendered polygon is there.
One way to fix this would be to make the stroke width of polygons configureable. So you would be able to set it to zero.
Another way might be to make the stroke width smaller when the view is zoomed out.

Screenshots:
Zoomed in area:
image
Same area, zoomed out: (the green polygons "disappeared")
image

HowTo install...

Hi

Your screenshots locks great ;-)

I am looking for a Grafana Map which can show some JSON values.
The Metric Key Value is a string in my case. Not a number.
It would also be cool to setup dynamic links to the map points.
I really like to test your solution. But I don't see an install instruction.

Thanks for any advice
Manfred

Input format required for geojson shapes?

Based on the documentation, it seems you need a column called "geojson" in your dataset that would contains a json object of a shape (as ST_AsGeoJSON from PostGIS would return).

Instead of using a database as the source, I want to present a geojson document I get from an HTTP GET request. I used the Grafana Infinity plugin and managed to parse a geojson document to get each features as an entry:

image

Here's an example of the content of one row:

{
	"geometry": {
		"coordinates": [
			-82.32861328125,
			27.946462631225587
		],
		"type": "Point"
	},
	"id": "fd3c336a-c877-415a-8321-f371d20c3444",
	"properties": {
		"dynamic_message_function": "speed-limit",
		"dynamic_message_text": "60",
		"static_sign_text": "SPEED LIMIT"
	},
	"type": "Feature"
}

This way, I would have expected OrchestraCities map to be able to parse and display it, but nothing shows up on the map.
I tried to manually add a "data layer" and select the query and geojson field, but it doesn't help.

image

What am I missing?

Displaying negative values in IDW+marker layer

Hi,
I'm using Orchestra Cities - Map Panel 1.4.4 (installed in Grafana 9.1.7).

I want to display a IDW heatmap for reception strength values (RSSI). These are usually negative (e.g. -90dBm), the legend has to show some custom threshold colors (e.g. -100dBm = red, -75dBm= orange, -50dBm = green). Over the heatmap I want to add a marker layer with the exact locations and values of the measurement with the same colors, the marker data source is the same query as for the IDW layer.

Unfortunately I cannot make the IDW layer to honor the negative value range for the threshold colors. The "min" weight value must be at least 0. So I end up with a "doubled" threshold table (-100 to -50 for the marker layer, 0 to eg. 50 for the IDW layer with weight 0 to 50). Works, but the double threshold setup is tedious and the legend also shows the confusing positive values for the IDW layer.

Is there a way to display negative values in the IDW and marker layers with only one color setup?

Popup dialog kept when leaving the map without crossing an empty zone

Hello,

When I leave the map showing a popup dialog, it is kept forever. It looks like the popup is hidden only when I move over an area without elements. If I zoom or move the map in such a way the panel border cuts a polygon, when I move the move over that panel border, the popup persists.

image

It happens either during edit or normal usage, even covering the content of another panel in the same dashboard.

I'm using c0d3a19

Custom Gazetter JSON Mapping

Hi everybody,

since my datasource does not allow me a "useful" query for rendering a world map, and the transformations that are already available in grafana can only help me partially, I would like to know, if I can add a custom json that maps a field to a location (joining e.g. a csv using grafana does unfortunately not work). If I modify the jsons in place, the plugin won't load due to a checksum failure.
Maybe you can help me, as this would solve my case completely :)

Best regards

Daniel

Use "Value Mapping" colors

A mapped value color should be used instead the one from color scheme. This is how grafana geomap works.

Multiple Data points using Lookup only shows one value

Pulling in data that can have multiple values per location only shows on on the map. I am using a lookup to gather lon/lat and have multiple values per one point on the layer. The map will only show one instead of a drop down of all data at that location.

https://community.grafana.com/t/orchestra-cities-multiple-events-per-marker-using-lookup/88385

Am I missing something to get all values to show up per location?

Grafana: 9.5.2
Plugin: 1.4.4

How to display (multi)polygons?

Hey guys, @amotl made me aware of your plugin.

I have a PostGIS database with polygon data based on postal codes. I want to display them together with additional data of my Postgres database.

At first I made a query based on PostGIS geometry data. After that I tried to convert the geometry data into GeoJSON and finally my 3rd try was to convert the whole query into json with the additional data as properties. But in every case the polygons weren't displayed. Is there any documentation or code snippets you can share with me to help me get that running?

Multiple Layers are slowing down the map performance

I have 6 layers of zip code data points, upwards of 35000 data points. Then 2 layers of Geojson geometries. The Geojson layers work at an expected speed. Once i start enabling the data point layers, performnce really slows down.

Compared to the Grafana GeoMap it works reasonable well.

I get a lot of errors in Consolee

image

MAybe that would help.

This map panel is perfect for what i've been looking for with the Geojson variables.

click event

Greetings

Love this plugin! Does this plugin have a click event by location?

Thanks

Auto center not working

I was happy to find this plugin as we've been looking for a way to render GeoJSON from queries onto maps. Unfortunately it seems that the Auto-center option for "Map view" is not working correctly. It seems that it works when I select it the first time, and after that the map is locked in the same starting view. We were hoping that the view would automatically adapt to the query result every time the data is updated.

Is this a bug, or am I just doing it wrong?

from map panel original plugin -> data_layer -> GeoJSON layer type missing in Orchestracities plugin

Hello,

not sure this is the right place to ask, so let me know.

It seems to me the GeoJSON data layer type is not available in the Orchestracities map panel. This data layer type is available in the original Grafana Map panel. Is there any reason it is so ?

I've seen in the code that could be just delayed as in the index.ts file, it is said "geojsonMapper, // dummy for now"

what would the current status ? and then what would be the guided line to activate it?

Also, I would be really interested how you have been able to extend the Orchestracities plugin the Grafana Map panel ? I've tried myself but bumped into a lot of dependency issues. any clue on that point ?

Thanks,

br,

Olivier Paviot

Rotate markers

Hello,

I would like to know how to rotate markers like on the original geomap pluggin. Could you give me guidance on how to implement it ?
Best regards

ambroise

Build failure

Yarn dev failure building from master with clean repo

⠦ Bundling plugin in dev mode  ERROR in ./src/GeomapPanel.tsx(194,35):
  TS2554: Expected 1 arguments, but got 0.
  ERROR in ./src/types.ts(1,1):
  TS6133: 'Units' is declared but its value is never read.
  ERROR in ./grafana-map-plugin/src/types.ts(17,16):
  TS2709: Cannot use namespace 'Units' as a type.

no data points are shown in the map if any column contains a empty value

Hey,

since the latest commits the panel won't show any points in the map anymore if some column contains empty (not NULL) values.

E.g.

SELECT name AS id, location AS geojson, time_index as created_at, foo, bar, 'none' as type
FROM foo.bar

With foo.bar as

name location time_index foo bar
"name1" valid geojson valid timestamp "value" "value"
"name2" valid geojson valid timestamp "" "value"

-> The map is empty. No points are drawn, no error is logged to the console or shown in the UI. Grafana query inspector looks good, query works as expected.

Env where this worked as expected:
Grafana: 7.0.6
Map Plugin commit sha: f19381d

Env where it does not work anymore:
Grafana: 7.4.0
Map plugin commit sha: 317b0be

Workaround:

SELECT name AS id, location AS geojson, time_index as created_at,
CASE
    WHEN foo = '' THEN 'EMPTY'
    ELSE foo
END AS foo,
bar, 'none' as type
FROM foo.bar

Data Field

Hi

i am using your awesome plugin!!

it would be very interesting display values ​​and texts in the map without using the tooltip function

My goal it would be display values ​​and texts at specific coordinates ...
perhaps it might be a good idea to see these text and numerical values ​​beyond a certain settable zoom level

Is it possible ?

Elasticsearch as datasource

Hey!

is there also the possibility to use Elasticsearch as datasource?
So far, i could not find out how to attach the Plugin to data coming from Elastic.

We want to visualise filled geo-shapes and hope to achieve that with your map-panel.

Thanks and all the best,
Sebastian.

Hello from Grafana Map Panel

Dear Rui André Costa, @ftcardoso, @chicco785, @WT-JB, @taliaga, @modularTaco and @WhitesteinDevelopment,

I have just now become aware of what you are doing here and wanted to take the chance to humbly point out our fork of the original Grafana Worldmap Panel at https://github.com/panodata/grafana-map-panel.

We've put in some reasonable amount of work in order to keep it alive, have been able to collect some contributions from the community and add other things from our own pen.

At [1], we outlined the development process. At [2], there is a summary about all the features and at [3], we came back to the Grafana community in order to announce our work.

While I recognize the code bases might have diverged significantly, I wanted to at least step by in order to eventually get in touch with you.

Keep up the spirit and with kind regards,
Andreas.

[1] https://community.hiveeyes.org/t/developing-grafana-worldmap-ng/1824
[2] https://community.panodata.org/t/grafana-map-panel/121
[3] https://community.grafana.com/t/giving-the-grafana-worldmap-panel-some-love/17210

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.