Skip to content

Conversation

@westonruter
Copy link
Member

Ever since the incorporation of page state into the URL Metric ETag (#1722), the freshness TTL of 1 day has been excessively frequent. Before the ETag, the freshness TTL needed to be a day since there was no mechanism to know whether a recent URL Metric actually corresponded to the current state of the page. This is now changed as the ETag will change whenever a post on the page is updated, the theme is changed, and (new in this PR) a plugin is activated/deactivated.

This PR also adds 3 getter methods which were missing from OD_URL_Metric_Group_Collection to access the its private properties.

@westonruter westonruter added [Type] Enhancement A suggestion for improvement of an existing feature [Plugin] Optimization Detective Issues for the Optimization Detective plugin labels Feb 10, 2025
@codecov
Copy link

codecov bot commented Feb 10, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 66.64%. Comparing base (6459571) to head (fd98d76).
Report is 6 commits behind head on trunk.

Additional details and impacted files
@@            Coverage Diff             @@
##            trunk    #1854      +/-   ##
==========================================
+ Coverage   66.55%   66.64%   +0.09%     
==========================================
  Files          88       88              
  Lines        6999     7015      +16     
==========================================
+ Hits         4658     4675      +17     
+ Misses       2341     2340       -1     
Flag Coverage Δ
multisite 66.64% <100.00%> (+0.09%) ⬆️
single 37.27% <5.88%> (-0.09%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@github-actions
Copy link

github-actions bot commented Feb 10, 2025

The following accounts have interacted with this PR and/or linked issues. I will continue to update these lists as activity occurs. You can also manually ask me to refresh this list by adding the props-bot label.

If you're merging code through a pull request on GitHub, copy and paste the following into the bottom of the merge commit message.

Co-authored-by: westonruter <[email protected]>
Co-authored-by: felixarntz <[email protected]>

To understand the WordPress project's expectations around crediting contributors, please review the Contributor Attribution page in the Core Handbook.

Copy link
Member

@felixarntz felixarntz left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Changing the TTL LGTM, but a few questions about the other changes.

Copy link
Member

@felixarntz felixarntz left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the updates, LGTM!

@westonruter westonruter merged commit 6a7952a into trunk Feb 10, 2025
16 checks passed
@westonruter westonruter deleted the update/default-freshness-ttl branch February 10, 2025 22:47
@westonruter westonruter mentioned this pull request Feb 12, 2025
5 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

[Plugin] Optimization Detective Issues for the Optimization Detective plugin [Type] Enhancement A suggestion for improvement of an existing feature

Projects

Status: Done 😃

Development

Successfully merging this pull request may close these issues.

3 participants