Still a few +translate timeouts
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Launchpad itself |
Fix Released
|
Medium
|
Jeroen T. Vermeulen |
Bug Description
We're still getting a few timeouts on translation pages, because finding external suggestions is so expensive. Chances are these will go away when message-sharing migration completes (both because load goes down and because the TranslationMessage table gets smaller).
But if not, or if we simply want more performance, there's another thing we could do: cache the ids of POTemplates that external suggestions can come from. This simplifies the search query from an 8-way join to a more straightforward 3-way one. Thus it also reduces the number of rows touched (and so the number of locks it might be sensitive to, potential disk reads etc.). Updating the cache would be cheap enough that we could afford to update it the easy way: clear it out and rewrite. Even doing it as a temp table inside the request might help, given that we typically dig up the same information up to 300× (or more realistically, "several times") per page otherwise.
Related branches
- Guilherme Salgado (community): Approve
- Canonical Launchpad Engineering: Pending (code) requested
-
Diff: 754 lines (+279/-94)14 files modifiedlib/lp/translations/browser/tests/test_baseexportview.py (+3/-2)
lib/lp/translations/doc/poexport-queue.txt (+6/-5)
lib/lp/translations/doc/poexport-request-productseries.txt (+3/-2)
lib/lp/translations/doc/poexport-request.txt (+8/-3)
lib/lp/translations/doc/poexportqueue-replication-lag.txt (+89/-0)
lib/lp/translations/doc/potmsgset.txt (+12/-8)
lib/lp/translations/interfaces/poexportrequest.py (+23/-7)
lib/lp/translations/interfaces/potmsgset.py (+14/-8)
lib/lp/translations/model/poexportrequest.py (+68/-31)
lib/lp/translations/model/potmsgset.py (+8/-1)
lib/lp/translations/scripts/po_export_queue.py (+10/-24)
lib/lp/translations/tests/test_potmsgset.py (+23/-1)
lib/lp/translations/tests/test_suggestions.py (+8/-1)
lib/lp/translations/tests/test_translatablemessage.py (+4/-1)
tags: | added: timeout |
Changed in rosetta: | |
milestone: | none → 10.03 |
assignee: | nobody → Jeroen T. Vermeulen (jtv) |
importance: | Undecided → Medium |
status: | New → In Progress |
Changed in rosetta: | |
status: | In Progress → Fix Committed |
Changed in rosetta: | |
status: | Fix Committed → Fix Released |
Okay, maybe for this page we dig up those POTemplate ids only up to 50×. But then again that limit is in place mainly because this lookup is so expensive in the first place.
OOPS-1522EA217, OOPS-1522EA218, OOPS-1522ED184