Merge lp:~cjwatson/launchpad/copy-lock-archive into lp:launchpad
Status: | Rejected |
---|---|
Rejected by: | Colin Watson |
Proposed branch: | lp:~cjwatson/launchpad/copy-lock-archive |
Merge into: | lp:launchpad |
Diff against target: |
136 lines (+57/-3) 3 files modified
lib/lp/services/database/locking.py (+5/-0) lib/lp/soyuz/model/packagecopyjob.py (+11/-3) lib/lp/soyuz/tests/test_packagecopyjob.py (+41/-0) |
To merge this branch: | bzr merge lp:~cjwatson/launchpad/copy-lock-archive |
Related bugs: |
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
William Grant | Needs Information | ||
Review via email: mp+279275@code.launchpad.net |
Commit message
Take an advisory lock on the target archive when copying packages.
Description of the change
Take an advisory lock on the target archive when copying packages; otherwise it's possible for multiple copies of the same package into different series in the same archive to race with the conflict checker and create conflicting builds.
The main potential downside that I can think of is that a large mass sync into the Ubuntu archive could potentially result in quite a few copies hitting the lock and needing to be retried repeatedly, taking those jobs over the retry limit. I *think* that the ten-minute delay on retries means that it's unlikely we'll hit the retry limit in practice, but it's possible. I'd welcome advice on whether this is a problem and if so what we might do about it.
Unmerged revisions
- 17861. By Colin Watson
-
Take an advisory lock on the target archive when copying packages.
I think this will be a terrible thundering herd problem when bulk copies are performed to a single archive.