Class InfluxdbDataPointSerializer
- java.lang.Object
-
- com.elastisys.autoscaler.systemhistorians.influxdb.serializer.InfluxdbDataPointSerializer
-
- All Implemented Interfaces:
java.util.function.Function<com.elastisys.autoscaler.core.api.types.MetricValue,java.lang.String>
public class InfluxdbDataPointSerializer extends java.lang.Object implements java.util.function.Function<com.elastisys.autoscaler.core.api.types.MetricValue,java.lang.String>AFunctionthat serializesMetricValues to the line protocol representation required when submitting data points to InfluxDB. See the InfluxDB documentation for details.
-
-
Constructor Summary
Constructors Constructor Description InfluxdbDataPointSerializer()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.Stringapply(com.elastisys.autoscaler.core.api.types.MetricValue value)Serializes a givenMetricValueto the line protocol format prescribed by InfluxDB.
-
-
-
Method Detail
-
apply
public java.lang.String apply(com.elastisys.autoscaler.core.api.types.MetricValue value)
Serializes a givenMetricValueto the line protocol format prescribed by InfluxDB.<measurement>,<tag1>=<value1>,<tag2>=<value2> <fieldKey>=<value> <timestamp>- Specified by:
applyin interfacejava.util.function.Function<com.elastisys.autoscaler.core.api.types.MetricValue,java.lang.String>- Parameters:
value- aMetricValue- Returns:
- The line protocol representation of the
MetricValue.
-
-