I am in the middle of building weather station based on Raspberry Pi and couple of sensors.
I succesfully sent logs from RPi to logstash and logstash resend them to elasticsearch.
First of all I am configuring temperature and humidity. I send them to elasticsearch as float type:
First problem is: this avarage from temperature. Is it possible to display last temperature field from message? Not avarage from timeframe but last value from temperature field from latest message received?
Second problem: why I cannot set -25? Temperature can be below 0*C
Could you help me with solving my problems?
Appreciate your help!
Displaying the latest value in the bucket is a bit non-intuitive, but it can be done like this:
Metric Aggregation: Top Hit
Field: temperature
Aggregate with: concatenate
Size: 1
Sort on: @timestamp
Order: Descending
As for allowing negative values in the Goal/Gauge visualizations I am surprised that it isn't allowed. You should add an enhancement request here: https://github.com/elastic/kibana
I will follow up on it as well, as it seems like a low hanging fruit and it should be a quick fix.
Another thing that you could do for the last value is to have logstash write to 2 indices.
One of those indices is the time-based index you are currently using which has values and a timestamp and each new doc is inserted into the index.
The other one would be a non-time-based index and it would only hold 1 doc that has the current temp and humidity and logstash would just do an update on that single doc.
Fair enough. I didn't know how your documents look like. I've added an issue for negative numbers support here: https://github.com/elastic/kibana/issues/15987 and also made the developer of this viz aware of this issue.
Apache, Apache Lucene, Apache Hadoop, Hadoop, HDFS and the yellow elephant
logo are trademarks of the
Apache Software Foundation
in the United States and/or other countries.