{"repo":"portothree/grafana-datasource-mongodb","free":true,"listed":false,"github":"https://github.com/portothree/grafana-datasource-mongodb","clone":"git clone https://github.com/portothree/grafana-datasource-mongodb.git","description":"MongoDB datasource plugin for Grafana","language":"JavaScript","stars":13,"topics":["grafana","mongodb"],"license":"MIT","category":"analytics","readme_excerpt":"MongoDB to Grafana Visualize data from MongoDB in Grafana. This project is based on simple-json-datasource and mongodb-grafana which both seems to be discontinued at the moment. We are creating a backend that implements 4 endpoints that is necessary to implement custom grafana datasource: - / Used for test the connection with the datasource - /search Used by the query tab in panels - /query Return metrics based on input - /annontations Return annotations Inside the server folder there's a express server that exposes these endpoints and make the proxy to the mongodb. The src folder contains some html partials, css and images that will be used to create the configuration page of the custom datasource in the grafana project. The gulp build task will use these files to create the final dist folder. The plugin.json is mandatory for the plugin, grafana will scan for this file inside the directory. I'm following the schema recommended by the grafana documentation here. The datasource.js should contain 4 funcions: The API is expecting values from the query with the following fields: name , value and ts . To accomplish that we are using the Mongo aggregation pipeline. Prerequisites - Grafana 6.x.x - Node 10.x Installation 1. Run the server with npm run server or node server/mongo-proxy.js , its defaults to port 3000 . 2. Clone the project in the /usr/local/var/lib/grafana/plugins folder 3. Build the plugin front end with npm run build or npx gulp 4. Make sure the dist folder was creat","default_branch":null,"files":null,"tree":[],"storefront":"/r/portothree","claimed":false,"request_supported":{"post":"https://gitbuyer.com/r/portothree/grafana-datasource-mongodb/request-supported","requests":0},"note":"indexed from public GitHub; nothing is for sale on this page. Clone it from GitHub. Paid listings live at /search."}