AnsweredAssumed Answered

Questions about RecordedValues bulk data delivery

Question asked by ritchiecarroll on Jan 7, 2015
Latest reply on Jan 8, 2015 by bshang

Using PIPointList.RecordedValues I can quickly get an enumeration of AFValues - i.e., all values for the specified time range for each PI point (as a collection of AFValues) in the PIPointList. I haven't stressed this function yet and I assume there are limits.


With my initial testing, it appears that all data points are received in bulk when the method returns as one big batch, i.e., I call RecordedValues method, I get "all" data. I just want to make sure this is expected behavior. I am not sure if this is a single RPC call or multiple ones behind the scenes to provide all expected data to the programmer.


In particular, what happens if I query a very large time-range or a very large number of points, i.e., will data continue to queue up in memory until all data is received before call to RecordedValues returns or is the RecordedValues function implemented as a "yielded return" such that it can continually provide data (per RPC return) as it is queried by the server in more of a streaming fashion, e.g., I will receive multiple AFValues for a given point over time?


I noticed this note in the documentation:


"The PI Server imposes a limit on the maximum number of events that can be returned with a single call. By default this is set at 150,000. This behavior can be changed on the server by editing the server's PITimeout table and adding or editing the value associated with the parameter ArcMaxCollect."


Does this mean no matter how much data I request I will only ever receive 150,000 (i.e., ArcMaxCollect) points from a RecordedValues call?


Also, does the PIPagingConfiguration control how the data is received from the RecordedValues function or is this a parameter to control server-side query behavior?


My goal is to know how to properly retrieve very large data sets using AF-SDK in a "streaming" fashion.


Thanks for any help in clarification on proper use of SDK to perform this task.


J. Ritchie Carroll