Condition based update in telegraf

How to do the If conditions like compare previous value and current value then based on result whether determine data need to update to influxdb2 or not?

Can be done via Starlark script, see an example

1 Like

@Janaki_RAMAN.S I’m not sure what you are trying to achieve? Do you want to avoid writing the same values for consecutive samples to the database twice?

If so, you can use the dedup processor which does exactly this! However, InfluxDB is usually quite efficient in storing duplicate entries without using a lot of disk space so I doubt the effort is worth it…