lp:~jaypipes/glance/bug768969

Created by Jay Pipes and last modified
Get this branch:
bzr branch lp:~jaypipes/glance/bug768969
Only Jay Pipes can upload to this branch. If you are Jay Pipes please log in for upload directions.

Branch merges

Related bugs

Related blueprints

Branch information

Owner:
Jay Pipes
Project:
Glance
Status:
Merged

Recent revisions

124. By Jay Pipes

Fix for LP Bug #768969.

Two things were happening that this patch corrects:

a) If adding an image fails, the glance add output says that
   adding the image failed, however, doing a glance index would
   show the image. This was because the call to get all public
   images was not correctly filtering the result for 'active'
   status images. The image failing to be added causes the image
   status to be 'killed', and so killed images should not appear
   in the output of glance index or glance detail.
b) glance show <ID> was not showing the status of the image, so
   it was not clear that the image, while not added successfully,
   was still in the registry, but in a 'killed' status.

I added a note to the output of the failed add command that the
Glance registry may still have an image record, but the status
would likely be in the 'killed' state.

Added a functional test case that verified the behaviour in the bug
and verified the fix, once coded.

123. By Joseph Suh <jsuh@bespin>

I modified documentation to show more first-time user friendly examples on using glance. With the previous examples, I followed it as a first-time user and had to spend more than necessary time to figure out how to use it. With this modification, other first-time users would make it work on their systems more quickly.

122. By Brian Waldon

- Require user confirmation for "bin/glance clear" and "bin/glance delete <id>"
- Allow for override with -f/--force command-line option

121. By Jay Pipes

Adds a test case for updating an image's Name attribute. glance update was not regarding 'name' as a top-level modifiable attribute...

120. By Dan Prince

Mark image properties as deleted when deleting images.
Added a unit test to verify public images and their properties get deleted when running a 'glance clear' command.

119. By Jay Pipes

Add log_file to example glance.conf

118. By Jay Pipes

Make sure we use get_option() when dealing with boolean values
read from configuration files...otherwise "False" is True :(

117. By Eldar Nugaev

Fixing tests.
Sorry for late response.

Rick Harris wrote on 2011-04-12
Really nice job, Eldar.

> 46 + image_swift = StringIO.StringIO("nevergonnamakeit")
> 47 + options = SWIFT_OPTIONS.copy()
> 48 + del options['swift_store_user']
> 49 + self.assertRaises(BackendException,
> 50 + SwiftBackend.add,
> 51 + 2, image_swift, options)

Might be better to DRY up the code some by adding a helper-method, like:

def assertOptionRequiredForSwift(self, key):
  image_swift = StringIO.StringIO("nevergonnamakeit")
  options = SWIFT_OPTIONS.copy()
  del options[key]
  self.assertRaises(BackendException,
    SwiftBackend.add,
    2, image_swift, options)

Marking as Needs Fixing, but if you don't like the idea, I'd be willing to set this as Approved (since the suggestion is so minor :-)

116. By Thierry Carrez

Open Diablo release.

115. By Soren Hansen

Fake merge with ancient trunk. This is only so that people who "accidentally" have been following lp:~hudson-openstack/glance/trunk will not have problems updating to this.

Branch metadata

Branch format:
Branch format 7
Repository format:
Bazaar repository format 2a (needs bzr 1.16 or later)
Stacked on:
lp:~hudson-openstack/glance/trunk
This branch contains Public information 
Everyone can see this information.

Subscribers