Giter Site home page Giter Site logo

andershz / mqtt-datasource Goto Github PK

View Code? Open in Web Editor NEW

This project forked from grafana/mqtt-datasource

0.0 0.0 0.0 3.91 MB

MQTT Datasource for Grafana allows streaming data from any MQTT broker running either locally or remotely.

License: Apache License 2.0

JavaScript 7.39% Go 64.84% TypeScript 27.77%

mqtt-datasource's Introduction

Build Status

MQTT data source for Grafana

The MQTT data source plugin allows you to visualize streaming MQTT data from within Grafana.

This datasource is under active development, all feedback and help is encouraged!

Requirements

The MQTT data source has the following requirements:

  • Grafana user with a server or organization administration role; refer to Permissions.
  • Access to a MQTT broker.

Known limitations

  • The plugin currently does not support all of the MQTT CONNECT packet options.
  • The plugin currently does not support TLS.
  • Including multiple topics in a panel is not yet well supported.
  • This plugin automatically supports topics publishing very simple JSON formatted messages. Note that only the following structure is supported as of now:
{
    "value1": 1.0,
    "value2": 2,
    "value3": 3.33,
    ...
}

In addition also a simple numerical value is supported:

1.0

We do plan to support more complex JSON data structures in the upcoming releases. Contributions are highly encouraged!

  • This plugin currently attaches timestamps to the messages when they are received, so there is no way to have custom timestamp for messages.

Install the plugin

Installation Pre-requisites

Refer to: Building a Streaming Datasource Backend Plugin

Details: Ubuntu Windows

Meet compatibility requirements

This plugin currently supports MQTT v3.1.x.

Note: Since this plugin uses the Grafana Live Streaming API, make sure to use Grafana v8.0+

Installation Steps

  1. Clone the plugin to your Grafana plugins directory.
  2. Build the plugin by running yarn install and then yarn build.

NOTE: The yarn build command above might fail on a non-unix-like system, like Windows, where you can try replacing the rm -rf command with rimraf in the ./package.json file to make it work.

  1. Run mage reloadPlugin or restart Grafana for the plugin to load.

Verify that the plugin is installed

  1. In Grafana from the left-hand menu, navigate to Configuration > Data sources.
  2. From the top-right corner, click the Add data source button.
  3. Search for MQTT in the search field, and hover over the MQTT search result.
  4. Click the Select button for MQTT.

Configure the data source

Add a data source by filling in the following fields:

Basic fields

Field Description
Name A name for this particular AppDynamics data source
Host The hostname or IP of the MQTT Broker
Port The port used by the MQTT Broker (default 1883)

Authentication fields

Field Description
Username (Optional) The username to use when connecting to the MQTT broker
Password (Optional) The password to use when connecting to the MQTT broker

Query the data source

The query editor allows you to specify which MQTT topics the panel will subscribe to. Refer to the MQTT v3.1.1 specification for more information about valid topic names and filters.

mqtt dashboard

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.