diff options
| author | Rick Harris <rick.harris@rackspace.com> | 2011-08-05 00:12:19 +0000 |
|---|---|---|
| committer | Rick Harris <rick.harris@rackspace.com> | 2011-08-05 00:12:19 +0000 |
| commit | 66916be1ad5bbc0cdc19928ee35e5e8f4e4a3915 (patch) | |
| tree | 779633e25525b96df110fc64a4e3296dcdc81902 /plugins | |
| parent | 0fea610a6918089c53cc33335a4db4557820675f (diff) | |
| download | nova-66916be1ad5bbc0cdc19928ee35e5e8f4e4a3915.tar.gz nova-66916be1ad5bbc0cdc19928ee35e5e8f4e4a3915.tar.xz nova-66916be1ad5bbc0cdc19928ee35e5e8f4e4a3915.zip | |
Read response to reset HTTPConnection state machine
Diffstat (limited to 'plugins')
| -rwxr-xr-x | plugins/xenserver/xenapi/etc/xapi.d/plugins/glance | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/plugins/xenserver/xenapi/etc/xapi.d/plugins/glance b/plugins/xenserver/xenapi/etc/xapi.d/plugins/glance index 17a5dbbfb..a06312890 100755 --- a/plugins/xenserver/xenapi/etc/xapi.d/plugins/glance +++ b/plugins/xenserver/xenapi/etc/xapi.d/plugins/glance @@ -261,6 +261,9 @@ def _upload_tarball(staging_path, image_id, glance_host, glance_port, os_type, if header.lower().startswith("x-image-meta-property-"): headers[header.lower()] = value + # Toss body so connection state-machine is ready for next request/response + resp.read() + # NOTE(sirp): httplib under python2.4 won't accept a file-like object # to request conn.putrequest('PUT', '/v1/images/%s' % image_id) |
