~jaypipes/glance/checksum

Viewing all changes in revision 80.

  • Committer: jaypipes at gmail
  • Date: 2011-03-08 15:22:44 UTC
  • Revision ID: jaypipes@gmail.com-20110308152244-pw6gzbsxt39f2mxj
Adds checksumming to Glance.

When adding an image (or uploading an image during PUT operations),
you may now supply an optional X-Image-Meta-Checksum header. When
storing the uploaded image, the backend image stores now are required
to return a checksum of the data they just stored. The optional
X-Image-Meta-Checksum header is compared against this generated checksum
and returns a 409 Bad Request if there is a mismatch.

The ETag header is now properly set to the image's checksum now
for all GET /images/<ID>, HEAD /images/<ID>, POST /images and
PUT /images/<ID> operations.

Adds unit tests verifying the checksumming behaviour in the API, and
in the Swift and Filesystem backend stores.

expand all expand all

Show diffs side-by-side

added added

removed removed

Lines of Context: