A way to specify within the analyses if input values should be retrieved from the Data Archive or the PIAF Cache. Thereby preventing different results during real-time calculation and for instance backfills and decreasing the execution time of analyses.
This change would solve multiple problems.
The easiest to understand is the ‘counter’-problem described below.
When creating a simple counter that adds ‘one’ every minute.
The periodic triggered analysis has the following functionality:
Retrieve the previous counter value
Add 1 to the retrieved value
Write the result to the counter PI-point
When calculating in real-time the result will be written to the snapshot of the PI-point and therefore also added to the PIAF cache.
Note that the previous value is retrieved from the PIAF Cache because the latest event is less than 5 minutes ago (The Analysis Service Configuration parameter ‘CacheTimeSpanInMinutes’ has a default value of 5 minutes).
After checking that the analysis works as expected a backfill is initiated. During a backfill the snapshot is bypassed and data is written to the archive directly.
After the backfill is finished the analysis will continue to be triggered in real-time.
The first time the analysis is triggered in real-time it will retrieve the previous value from the PIAF-cache, which was NOT updated by the backfill, resulting in an incorrect outcome.
In cases such as these it would be great to be able to specify where the data should retrieved (PIAF cache or Data archive).