Reviewed:  https://review.openstack.org/229312
Committed: 
https://git.openstack.org/cgit/openstack/glance/commit/?id=e7d4e81f5b3daf924a294e439f434c193d53313e
Submitter: Jenkins
Branch:    master

commit e7d4e81f5b3daf924a294e439f434c193d53313e
Author: Darja Shakhray <dshakh...@mirantis.com>
Date:   Wed Sep 30 12:04:58 2015 +0300

    Unallowed request PATCH when work with blob
    
    Added check property when updating artifacts with request PATCH.
    
    ApiImpact
    FastTrack
    Change-Id: I2407522d9d764545f0897d7dc4cf0a64c526a9bc
    Closes-bug: #1490505
    Closes-bug: #1490511


** Changed in: glance
       Status: In Progress => Fix Released

-- 
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to Glance.
https://bugs.launchpad.net/bugs/1490511

Title:
  Glance returned 500 status code when we download removed blob property

Status in Glance:
  Fix Released

Bug description:
  ENVIRONMENT: devstack, Glance (master, 30.08.2015)

  STEPS TO REPRODUCE:
  We tried dowload element to blob property on artifact.
  We have the artifact:
  {"description": null, "published_at": null, "tags": [], "depends_on": null, 
"created_at": "2015-08-31T10:30:24.000000", "type_name": "MyArtifact", 
"updated_at": "2015-08-31T10:30:24.000000", "visibility": "private", "id": 
"3f931cb3-8715-4dff-9d79-639a6853ed14", "type_version": "2.0", "state": 
"creating", "version": "11.0.0", "references": [], "prop1": null, "prop2": 
null, "owner": "a82a48dc05df447baab0afe1770c2be8", "image_file": null, 
"deleted_at": null, "screenshots": [], "int_list": null, "name": "art"}

  Send request:
  curl -H "X-Auth-Token: 7df867f7b5ae42778b355a74b6d5d76c" -H 
"Content-Type:application/octet-stream" -X PATCH -d '[{"op": "remove", "path": 
"/image_file"}]' 
http://172.18.76.44:9292/v3/artifacts/myartifact/v2.0/3f931cb3-8715-4dff-9d79-639a6853ed14
 -i

  Get response:
  HTTP/1.1 200 OK
  Content-Length: 640
  Content-Type: application/json; charset=UTF-8
  X-Openstack-Request-Id: req-42927006-cdaa-4a67-9143-8427830a1228
  Date: Mon, 31 Aug 2015 10:34:39 GMT

  {"description": null, "published_at": null, "tags": [], "depends_on":
  null, "created_at": "2015-08-31T10:30:24.000000", "type_name":
  "MyArtifact", "updated_at": "2015-08-31T10:30:24.000000",
  "visibility": "private", "id": "3f931cb3-8715-4dff-9d79-639a6853ed14",
  "type_version": "2.0", "state": "creating", "version": "11.0.0",
  "references": [], "prop1": null, "prop2": null, "owner":
  "a82a48dc05df447baab0afe1770c2be8", "image_file": {"checksum": null,
  "download_link": "/artifacts/myartifact/v2.0/3f931cb3-8715-4dff-
  9d79-639a6853ed14/image_file/download", "size": 0}, "deleted_at":
  null, "screenshots": [], "int_list": null, "name": "art"}

  We tried to download the "image_file" link above, send request:
  curl -H "X-Auth-Token: 7df867f7b5ae42778b355a74b6d5d76c" -H 
"Content-Type:application/octet-stream" -X GET 
http://172.18.76.44:9292/v3/artifacts/myartifact/v2.0/3f931cb3-8715-4dff-9d79-639a6853ed14/image_file/download
 -i

  ACTUAL RESULT:
  HTTP/1.1 500 Internal Server Error
  Content-Type: text/plain
  Content-Length: 0
  Date: Mon, 31 Aug 2015 10:43:51 GMT
  Connection: close

To manage notifications about this bug go to:
https://bugs.launchpad.net/glance/+bug/1490511/+subscriptions

-- 
Mailing list: https://launchpad.net/~yahoo-eng-team
Post to     : yahoo-eng-team@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yahoo-eng-team
More help   : https://help.launchpad.net/ListHelp

Reply via email to