Raw Valuew Views

In EOS, unlike other logging systems, you cannot directly access measured raw values writen in underlying database. This raw values data is offen recorded unrasterized or in different time rasters thats makes it unefficient to make matematical operations among them becouse of unsynchronized timestamps. Since EOS system hardly focus on complex computations we wollow approatch to bring all this underlying data to same time raster for specific purposes of usage. That is where Raw Values Views comes in. One Raw Values View is a view on raw values in one consistent time raster.

1. Raw Values View Types

There is always at least two Raw Values Views: GlobalView and RealtimeView.

  • RealtimeView is adressed to make computations in high time resolution to control realtime enviroment. Usialy it have the data in finest time raster and contains ony latest realtime values to reduce amount of data to handle.

  • GlobalView is adressed to get overview of whole time since begining of measurements recording and can even contain future data as forecast to upcomming future time period. Usialy it is setup to have data in a much bigger time raster than in RealtimeView.

Additionaly, if some one needs to analyze data in a past period of time that is not covered by RealtimeView and the underlying time raster of GlobalView is to big, than he ca extract raw measurements data in a needed raster and create a CustomView for some selected period of time.

  • CustomView is an optional view on underlying data for a short period of time in a raster needed for analysis purposes. Every CustomView occupy hardware resourses of EOS server and need to be deleted if there is no more need to hold this view to free server resources.

2. API

GET Raw Values Views Information

You can list infos of all views of given type by:

// list all raw values view of view type
rawvalues/view/get/view_type=[VIEW_TYPE]
// list info of one view type
rawvalues/view/get/view_type=[VIEW_TYPE]&view_index=[*VIEW_INDEX]
- VIEW_TYPE: RealtimeView | GlobalView | CustomView
- VIEW_INDEX: number // needed for custom views. leave empty for RealtimeView or CustomView

// You can leave optional fields amrked with `*` empty.

JSON Response of one Raw Values View Info:

{
        "id": 0, // View Index
        "type": "CustomView", // View Type
        "name": "{}", // Name of Rasterized View
        "raster": "Second_1", // Underlying Raster of View
        "ram_size": 3368687, // Ocupied RAM size on server side in bytes
        "hdd_size": 10490003, // Ocupied HDD size on server side in bytes
        "time_range_begin": "2021-11-04T02:12:01Z", // Time range begin of underlying data as UTC Timestamp
        "time_range_end": "2021-11-04T15:47:57Z" // Time range end of underlying data as UTC Timestamp
}

GET archive values time range

To get time range of undelying archive data use folowing reqeust:

// Only archive data. This time range cannot contain future period of time
server/get_values_view_archive_timerange/view_type=[VIEW_TYPE]&view_index=[*VIEW_INDEX]

To get overall time range of view:

// Overall time range. This time range can contain future period of time, usualiy for `GlobalView` type
server/get_values_timerange/view_type=[VIEW_TYPE]&view_index=[*VIEW_INDEX]view_type=[VIEW_TYPE]&view_index=[*VIEW_INDEX]

GET or SET future time range

GlobalView and RealtimeView can have forecast functionality to make computations for future time period.

You can request currently set future time range by:

rawvalues/future_time_range/get/view_type=[VIEW_TYPE]

an get response like:

{
        "view_type": "GlobalView",
        "future_type": "FixedRange",
        "future_range_raster": "Hour",
        "future_range_raster_count": 48,
        "future_end_timestamp": null,
        "enabled": true
}

Or you can set new future time range over POST request:

rawvalues/future_time_range/set

by passing folowing JSON Object:

{
        "view_type": "GlobalView", // GlobalView or RealtimeView. RealtimeView is currently unsupported but will be implemented in future
        "future_type": "FixedRange", // Type of future. Either "FixedRange" or "FixedEndTimestamp"
        "future_range_raster": "Hour", // Base raster for "FixedRange"
        "future_range_raster_count": 48, // Count of rasters for "FixedRange"
        "future_end_timestamp": null, // Fixed end timestamp as milliseconds since 1970-0-0 00:00:00 as LONG value
        "enabled": true // enable status
}