soql – Is it expected that the results from LightningUsageByPageMetrics are delayed? If so, how much?

I have a SOQL query using LightningUsageByPageMetrics running daily using a query job submitted through the /services/data/vXX.X/jobs/query endpoint.

The WHERE clause of the query only has a statement for MetricsDate being equal to 2 days in the past.

SELECT Id,MetricsDate
FROM LightningUsageByPageMetrics WHERE MetricsDate = 2022-06-13

This commonly returns 0 results even though there is usage on that date. If I re-run the same SOQL a day or more in the future then it will return the records from that date. It appears that the data isn’t immediately available but I am not seeing this called out in documentation. Is this expected behavior? If so, what is the best practice for reliably querying the latest data available for this object?

Read more here: Source link