EPTS

Endpoint Time Series service (EPTS) is a Kaa service that receives endpoint data samples and transforms them into time series. EPTS broadcasts newly received data points through the time series transmission interface and provides API for historical time series retrieval. EPTS also acts as a time series receiver, so you can ingest and save time series from other transmitters, such as EPL.

Endpoint data sample is a piece of endpoint-related data of an arbitrary structure. Data samples typically capture the state of a machine, entity, or process at a given moment. EPTS supports processing data samples encoded as flat or composite JSON records. For example:

{
    "ts": "2019-04-26T15:41:07+0000",
    "temp": 21,
    "humidity": 73,
    "location" : {
        "lat": 34.1340258,
        "lon": -118.3238652
    }
}

Data sample may or may not contain a timestamp. In the latter case, you can configure EPTS to apply the data sample receipt time when extracting data points.

Data point is a data structure consisting of a timestamp and one or more named values. Data point values can be of an arbitrary primitive or a composite data type. A data sample may contain one or more data points. For example, the data sample above can be split by EPTS into a couple of data points (represented as JSONs for simplicity):

{
    "timestamp": 1556293267,
    "values": {
        "temperature": 21,
        "humidity": 73
    }
}

and

{
    "timestamp": 1556293267,
    "values": {
        "latitude": 34.1340258,
        "longitude": -118.3238652
    }
}

Endpoint time series is a named series of endpoint-related data points. Time series names must be unique within a given Kaa application. For example, the first data point above can be saved to the weather time series, while the second—to location.

Interfaces

EPTS supports a number of interfaces to perform its functional role. The key supported interfaces are summarized in the following diagram.

EPTS interfaces diagram

For inter-service communication, Kaa services mainly use REST APIs and messaging protocols that run over NATS messaging system.

Data sample transmission

EPTS supports 13/DSTP and acts as a data sample receiver service by subscribing to data transmitters. You can use this interface to inject data samples from services such as DCX. See the configuration page for information on how to configure this interface.

Time series transmission

EPTS supports 14/TSTP both as a transmitter and a receiver.

Whenever a new data point is saved in EPTS, it is transmitted to downstream services for processing. You can use this feature to receive streaming time series data in your own services.

You can also configure EPTS to receive data points from other services such as EPL. This feature provides an alternative way of injecting time series data into EPTS.

Historical time series

EPTS exposes REST API for retrieving and pushing historical time series data.

Tekton integration

EPTS is integrated with the Kaa Tekton for centralized application configuration management. It receives configuration update messages from Tekton over 17/SCMP and uses Tekton REST API to retrieve current configs.

See configuration for more information.

Kaa Tenant Manager integration

EPTS supports multi-tenancy with each tenant using a separate OAuth 2.0 issuer for authentication, authorization, and resource management. The list of the existing tenants is managed by [the Kaa Tenant Manager][Tenant Manager], which provides REST API for retrieving tenant security configs.

See the security configuration for more details on how to enable multi-tenancy in EPTS.

Management interface

EPTS exposes an HTTP-based management interface with the following endpoints:

  • GET /health returns 200 OK if the service is up and running properly, and 500 Internal Server Error otherwise. In case of errors, the response payload contains their human-redable descriptions. This endpoint can be used by Kubernetes for liveness and readiness probing.
  • GET /metrics provides service metrics in Prometheus text-based format.