esthesis Line Protocol (eLP)
The esthesis Line Protocol (eLP) is a simple, text-based protocol, allowing you to push data to the official device agent, or if you have a custom agent, to a data broker from which an esthesis Dataflow reads data form.
Specification
eLP consists of text-based messages conveying information that should be processed by esthesis Core. Each message may contain multiple lines, and each line may contain multiple values. Here is an overview of a line following the eLP format:
category, is an arbitrary, alphanumeric value, specifying the category the measurements belong to. It should start with a letter.
measurement, is an arbitrary, alphanumeric value, specifying the name of a measurement. It should start with a letter.
value, is an arbitrary, alphanumeric value, specifying the value of a measurement.
timestamp, should be expressed as a string, following ISO-8601. The timestamp value is shared between all measurements of the same line. If you need to send multiple measurements with each one having a unique timestamp, split them in different lines and specify a separate timestamp for each. If a timestamp value is not present, the time at the time of processing the message will be used as a timestamp.
Value typing
When an eLP message is received by an esthesis Dataflow, the dataflow will try to determine the type of the value using reasonable defaults. However, you may find cases where automatic value type discovery is not what you would expect. For those cases, you can specify the type of the value by using suffixes. Here is the list of prefixes you can use:
Integer: append a
ito the value, e.g. 123iFloat: append a
fto the value, e.g. 123.456fLong: append a
lto the value, e.g. 1234567890123456789lDouble: append a
dto the value, e.g. 123.456dShort: append a
sto the value, e.g. 123sByte: append a
bto the value, e.g. 123bBoolean:
true, orfalseString: enclose the value is single quotes, e.g. 'myval'