Skip to content

Grafana datasource to load JSON data over your arbitrary HTTP backend

License

Notifications You must be signed in to change notification settings

Wiseqube/wiseqube-json-datasource

Repository files navigation

Grafana data source plugin for arbitrary JSON HTTP backend

The JSON Datasource executes requests against arbitrary backends and parses JSON response into Grafana dataframes. The project is based upon the archived project https://github.com/simPod/GrafanaJsonDatasource/

Getting started

Backend

  1. Update Grafana plugin SDK for Go dependency to the latest minor version:

    go get -u github.com/grafana/grafana-plugin-sdk-go
    go mod tidy
  2. Build plugin backend binaries for Linux, Windows and Darwin:

    mage -v
  3. List all available Mage targets for additional commands:

    mage -l

Frontend

  1. Install dependencies

    npm install
  2. Build plugin in development mode and run in watch mode

    npm run dev
  3. Build plugin in production mode

    npm run build
  4. Run the tests (using Jest)

    # Runs the tests and watches for changes, requires git init first
    npm run test
    
    # Exits after running all the tests
    npm run test:ci
  5. Spin up a Grafana instance and run the plugin inside it (using Docker)

    npm run server
  6. Run the E2E tests (using Playwright)

    # Spins up a Grafana instance first that we tests against
    npm run server
    
    # If you wish to start a certain Grafana version. If not specified will use latest by default
    GRAFANA_VERSION=11.3.0 npm run server
    
    # Starts the tests
    npm run e2e
  7. Run the linter

    npm run lint
    
    # or
    
    npm run lint:fix

About

Grafana datasource to load JSON data over your arbitrary HTTP backend

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 2

  •  
  •