Comment 2 for bug 901534

Submitter: Jenkins
Branch: master

 status fixcommitted

commit 5620ddff24ecf783f37922aa435d71d301b27269
Author: Jay Pipes <email address hidden>
Date: Thu Dec 8 17:20:50 2011 -0500

    Fixes LP Bug#901534 - Lost properties in upload

    Adds test cases that verify the bug behaviour.

    Adds some logic to the main API images controller
    update() method that does the following:

    * If an image file is being uploaded, do not purge
      existing properties when updating metadata. The idea
      behind this change is that a very common scenario is
      to register an image entry with Glance with some
      properties (like instance_uuid, instance_type, etc) and
      then immediately upload an image (usually snapshots).
      We don't want to mark deleted the originally-registered
      properties during the image upload, which was what was

    * Add ability to force Glance NOT to purge properties
      when calling PUT /images/<IMAGE_ID> if the
      X-Glance-Registry-Purge-Props: false
      header is passed.

    Change-Id: Ie66af8f052ab40d5dca7a3235fdbbb7de20372de