Giter Site home page Giter Site logo

promqtt's People

Contributors

jwalzer avatar sh0rez avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

promqtt's Issues

Series closing

Currently, when an actor stops sending messages to MQTT, promqtt will export the last received value forever.

How shall we deal with this?

  1. Not. Leave as is. This appears to be what the Pushgateway does as well.
  2. Add a timeout (e.g. 5m, etc).
  3. Use special topics to "close" series, which makes promqtt remove them from its output. This could play well with LWT (Last will & testament), so that devices that disconnect from the broker are automatically removed.

I personally like (3), because it could leverage the quite unique MQTT property of LWT.

Thoughts? @RichiH?

JSON mode?

JSON can already parsed using the regex support, but only if the actors emit JSON in a strict way (same ordering, etc).

We could possibly add a native JSON mode that turns all fields into series

/mqtt target doesn't start

./promqtt 10.8.0.2:1883 
2021/12/17 10:10:39 listening at :9337
2021/12/17 10:10:39 subscribed to '#'

mosquitto_pub -h localhost -t diox/06FE2A3/co2 -m "42.0"

mosquitto_sub -t '#' --host 10.8.0.2
42.0

wget http://localhost:9337/mqtt
--2021-12-17 10:13:25--  http://localhost:9337/mqtt
Resolving localhost (localhost)... ::1, 127.0.0.1
Connecting to localhost (localhost)|::1|:9337... connected.
HTTP request sent, awaiting response... 400 Bad Request
2021-12-17 10:13:25 ERROR 400: Bad Request.

/mqtt target doesn't start

why? How to check it?

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.