bluefrg / jira-grafana-json-datasource

Connect Grafana to Jira cloud to retrieve metrics on your Jira issues.
MIT License
72 stars 27 forks source link

The value 'undefined' does not exist for the field 'filter' #1

Closed jbartko closed 5 years ago

jbartko commented 5 years ago

Hello!

Thank you for sharing this project! It looks promising, but when attempting to use it calls to /test-jira appear to succeed, then when configuring a Grafana panel to use the datasource, I see errors like the following:

(node:24) UnhandledPromiseRejectionWarning: {
  "statusCode": 400,
  "body": {
    "errorMessages": [
      "The value 'undefined' does not exist for the field 'filter'."
    ],
...
  "request": {
    "uri": {
      "hostname": "JIRA.EXAMPLE.COM",
      "pathname": "/rest/api/2/search",

Current Jira version is 7.3.8. Might this project be expected to work with that version?

bluefrg commented 5 years ago

Which version of Grafana are you running? I suspect Grafana isn't passing an array of targets in to the /query endpoint.

https://github.com/bluefrg/jira-grafana-json-datasource/blob/master/server.js#L109

jbartko commented 5 years ago

Currently deployed Grafana version for me is 5.2.1

bluefrg commented 5 years ago

Exception was being thrown when adding a panel. Grafana was querying without a target. Grafana version was irrelevant. Give it a try now.