You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
As the number of metrics we store grows, getting the latest metrics can be costly. Spanner does not implement window functions[1][2].
We ran into this problem when we stored WPT Run metrics a lot sooner due to the vast number of metrics from WPT being stored. We solved it by doing option 2.
We should do the same with the usage data as well.
Definition of done:
Create a table, LatestDailyChromiumHistogramMetrics
Should have:
WebFeatureID (Primary Key and have it as a Foreign Key with WebFeatures(ID))
ChromiumHistogramEnumValueID (Foreign Key with DailyChromiumHistogramMetrics as it is the primary key part 1 from DailyChromiumHistogramMetrics)
Day (Foreign Key with DailyChromiumHistogramMetrics as it is the primary key part 1 from DailyChromiumHistogramMetrics)
Modify the base query to reduce the joins. It should be able to join with the existing wf.ID to the WebFeatureID in this new table and then return the rate.
Update the UpsertDailyChromiumHistogramMetric logic to conditionally update the Latest table. Similar to the WPT metrics
Inspiration can be taken from the Latest WPT Metrics table: #498
The text was updated successfully, but these errors were encountered:
As the number of metrics we store grows, getting the latest metrics can be costly. Spanner does not implement window functions[1][2].
We ran into this problem when we stored WPT Run metrics a lot sooner due to the vast number of metrics from WPT being stored. We solved it by doing option 2.
We should do the same with the usage data as well.
Definition of done:
Inspiration can be taken from the Latest WPT Metrics table: #498
The text was updated successfully, but these errors were encountered: