Uses SERIALIZABLE isolation on PostgreSQL 9.1
Bug #973159 reported by
William Grant
This bug affects 1 person
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Launchpad itself |
Fix Released
|
Critical
|
William Grant |
Bug Description
Appservers currently ask psycopg2 for SERIALIZABLE isolation. In PostgreSQL 9.1 this uses SSI, which is far more expensive than 8.4's implementation. 9.1's REPEATABLE READ is equivalent to 8.4's SERIALIZABLE, so we should use that instead.
Unfortunately, our old psycopg2 doesn't know about 9.1 -- requesting REPEATABLE READ gets you SERIALIZABLE anyway. So we need to upgrade to psycopg2 2.4.2 or later.
Related branches
lp:~wgrant/launchpad/psycopg2-2.4.4
- Stuart Bishop (community): Approve
-
Diff: 53 lines (+5/-5)3 files modifiedlib/lp/code/model/branch.py (+1/-1)
lib/lp/services/database/bulk.py (+2/-2)
versions.cfg (+2/-2)
lp:~wgrant/launchpad/9.1-serializable-is-special
- Stuart Bishop (community): Approve
-
Diff: 146 lines (+17/-9)8 files modifiedlib/lp/registry/doc/convert-person-to-team.txt (+1/-1)
lib/lp/services/config/schema-lazr.conf (+1/-1)
lib/lp/services/config/tests/test_database_config.py (+2/-2)
lib/lp/services/database/multitablecopy.py (+1/-1)
lib/lp/services/database/sqlbase.py (+2/-0)
lib/lp/services/database/tests/script_isolation.py (+1/-1)
lib/lp/services/database/tests/test_isolation_changes.py (+6/-2)
lib/lp/services/webapp/adapter.py (+3/-1)
tags: |
added: qa-ok removed: qa-needstesting |
Changed in launchpad: | |
status: | Fix Committed → Fix Released |
To post a comment you must log in.
The changes to Insert expressions are needed because the version of my bulk insert branch that landed on trunk is slightly different from the early one we were using.