It's not the same without you

Join the community to find out what other Atlassian users are discussing, debating and creating.

Atlassian Community Hero Image Collage

Grafana with Jira

Hi,

Does it possible to use Grafana with Jira ?

 

I would like to get some statistics (number of issues and so on... ) in Grafana.

 

I try with plugin "SimpleJSON" and REST API Jira but it doesn't work...

 

 

2 answers

Thanks, but not really...

With this, you monitor the JVM and i want to have more statistics with REST and JQL.

Like # people like this

We had the same struggles and never found a solution so I built one. You can use this project to accomplish what you need; https://github.com/bluefrg/jira-grafana-json-datasource

Hi Mike,

The reference is good,but when I try to validate (http://localhost:3000/test-jira) it returns Unauthorized (401) and when I run docker-compose.yml it returns

ERROR: for jira-grafana Cannot start service jira-grafana: driver failed programming external connectivity on endpoint jira-grafana-json-datasource-master_jira-grafana_1 (b8c1646130d2e5a850575dd5c1570a7e5bd570238236a7b835045c469dfd82f1): Bind for 0.0.0.0:3000 failed: port is already allocated
ERROR: Encountered errors while bringing up the project.

Hey nimmakayala!

You must have something already using port 3000 on your computer as the error is stating that, it's a common port for many other Docker projects using HTTP;

Bind for 0.0.0.0:3000 failed: port is already allocated

It's working thank you Mike

Is this a common error? I've tried both dev and prod Dockerfiles

 

jira-grafana_1 |
jira-grafana_1 | > jira-grafana-json-datasource@1.0.0 start /app
jira-grafana_1 | > node server.js
jira-grafana_1 |
jira-grafana_1 | internal/modules/cjs/loader.js:584
jira-grafana_1 | throw err;
jira-grafana_1 | ^
jira-grafana_1 |
jira-grafana_1 | Error: Cannot find module 'express'
jira-grafana_1 | at Function.Module._resolveFilename (internal/modules/cjs/loader.js:582:15)
jira-grafana_1 | at Function.Module._load (internal/modules/cjs/loader.js:508:25)
jira-grafana_1 | at Module.require (internal/modules/cjs/loader.js:637:17)
jira-grafana_1 | at require (internal/modules/cjs/helpers.js:22:18)
jira-grafana_1 | at Object.<anonymous> (/app/server.js:1:79)
jira-grafana_1 | at Module._compile (internal/modules/cjs/loader.js:701:30)
jira-grafana_1 | at Object.Module._extensions..js (internal/modules/cjs/loader.js:712:10)
jira-grafana_1 | at Module.load (internal/modules/cjs/loader.js:600:32)
jira-grafana_1 | at tryModuleLoad (internal/modules/cjs/loader.js:539:12)
jira-grafana_1 | at Function.Module._load (internal/modules/cjs/loader.js:531:3)
jira-grafana_1 | npm ERR! code ELIFECYCLE
jira-grafana_1 | npm ERR! errno 1
jira-grafana_1 | npm ERR! jira-grafana-json-datasource@1.0.0 start: `node server.js`
jira-grafana_1 | npm ERR! Exit status 1
jira-grafana_1 | npm ERR!
jira-grafana_1 | npm ERR! Failed at the jira-grafana-json-datasource@1.0.0 start script.
jira-grafana_1 | npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
jira-grafana_1 | npm WARN Local package.json exists, but node_modules missing, did you mean to install?
jira-grafana_1 |
jira-grafana_1 | npm ERR! A complete log of this run can be found in:
jira-grafana_1 | npm ERR! /root/.npm/_logs/2020-02-20T19_55_04_953Z-debug.log
jiragrafanajsondatasource_jira-grafana_1 exited with code 1

Hello. 

 

I've been trying to get your solution to work. But metrics in grafana doesn't come up. It just says "Bad Gateway" when i use query inspector. 

 

BadGateway.PNG

When I try the localhost it seems to work fine:

 

LocalHo.PNG

Suggest an answer

Log in or Sign up to answer
TAGS

Community Events

Connect with like-minded Atlassian users at free events near you!

Find an event

Connect with like-minded Atlassian users at free events near you!

Unfortunately there are no Community Events near you at the moment.

Host an event

You're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events

Events near you