OpenStack Image Management (Glance)
Go to file
Eoghan Glynn c4f97dfa6e Fix uniqueness constraint on image_members table.
Fixes bug #1098700.

Previously, deleting then re-creating an image member failed with
500 ServerError due to the registry service failing to commit
the update to the image_members table.

The problem arose because the declared uniqueness constraint on that
table only spanned the image_id and member columns, but did not take
into account that deleted rows are left in situ with the deleted_at
and deleted columns set as appropriate. Hence the unique constraint
was violated by the addition of the new row.

We modify the uniqueness constraint via a migration script to take
account of the deleted_at column also (NULL for live memberships).

Note that the new ability to recreate an image membership cannot be
be asserted in a functional test, as these tests are based on sqlite
which does not support 'ALTER TABLE DROP CONSTRAINT'.

Change-Id: I175801ba95ecd9295791bb12e9096f59efa19c02
2013-03-13 16:03:12 -07:00
bin Use oslo-config-2013.1b3 2013-02-19 10:19:36 +00:00
doc/source Update documentation to reflect API v2 image sharing 2013-03-04 15:39:32 +00:00
etc Removed controversial common image property 'os_libosinfo_shortid' 2013-02-26 20:55:58 +00:00
glance Fix uniqueness constraint on image_members table. 2013-03-13 16:03:12 -07:00
tools Switch to final 1.1.0 oslo.config release 2013-03-12 16:31:35 +00:00
.coveragerc Update .coveragerc 2013-02-06 16:47:06 +02:00
.gitignore Move to tag-based versioning. 2012-08-12 16:10:03 +00:00
.gitreview Add .gitreview config file for gerrit. 2011-10-24 11:02:16 -04:00
.mailmap Clean up pep8 E502, E711 violations 2012-09-18 10:10:01 +08:00
HACKING.rst Update HACKING.rst per recent changes 2013-02-04 10:23:11 +08:00
LICENSE Add a LICENSE file. 2012-01-03 10:14:01 -05:00
MANIFEST.in Update version code from oslo. 2013-01-13 14:27:48 -08:00
README.rst Replace README with links to better docs 2012-09-20 09:33:40 -07:00
babel.cfg Added first step of babel-based translations. 2012-02-28 02:00:37 -08:00
openstack-common.conf Use oslo-config-2013.1b3 2013-02-19 10:19:36 +00:00
pylintrc Packaging fixups 2010-10-21 15:51:44 -04:00
run_tests.sh Add an update option to run_tests.sh 2013-02-15 15:52:41 -05:00
setup.cfg Stop using detailed-errors plugin for nose. 2013-01-31 10:50:36 +11:00
setup.py Update version code from oslo 2013-01-21 21:17:51 -06:00
tox.ini Use oslo-config-2013.1b3 2013-02-19 10:19:36 +00:00

README.rst

Glance

Glance is a project that defines services for discovering, registering, retrieving and storing virtual machine images. Use the following resources to learn more: