Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Optimization Detective should be further hardened to account for high traffic sites #1655

Open
westonruter opened this issue Nov 15, 2024 · 0 comments
Labels
[Plugin] Optimization Detective Issues for the Optimization Detective plugin [Type] Enhancement A suggestion for improvement of an existing feature

Comments

@westonruter
Copy link
Member

westonruter commented Nov 15, 2024

Originally discussed in #1496 (comment):

  • Do we add an endpoint for getting the which URL Metrics are needed. The problem is that the endpoint cache wouldn't be reliably flushed. But if it were reliably flushed,
  • Check what happens when there is a race condition between two requests to store a URL Metric from two application servers connected to the same database when there wasn't a od_url_metrics post that already existed.
  • Do we need a lock or throttling mechanism?
  • When a persistent object cache is available, perhaps the POST request would only write to the object cache and then WP Cron would read from the object cache to actually create the URL Metrics posts.

Already addressed as part of #1641:

To deal with the page cache stampede problem, we can schedule the clearing of the cache for a URL periodically via WP Cron.

So the page cache stampede problem is addressed, but what is not addressed is what to do with a stampede of database writes for potentially thousands (or millions) of visitors attempting to submit URL Metrics for storage via the REST API.

@github-project-automation github-project-automation bot moved this to Not Started/Backlog 📆 in WP Performance 2024 Nov 15, 2024
@westonruter westonruter added [Plugin] Optimization Detective Issues for the Optimization Detective plugin [Type] Enhancement A suggestion for improvement of an existing feature labels Nov 15, 2024
@westonruter westonruter moved this from Not Started/Backlog 📆 to Definition ✏️ in WP Performance 2024 Nov 15, 2024
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: Definition ✏️
Development

No branches or pull requests

1 participant