Bug 1560579 - Tarball extraction fails but Swift API returns status 200
Summary: Tarball extraction fails but Swift API returns status 200
Keywords:
Status: CLOSED NOTABUG
Alias: None
Product: Red Hat OpenStack
Classification: Red Hat
Component: openstack-swift
Version: 13.0 (Queens)
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
: ---
Assignee: Thiago da Silva
QA Contact: Mike Abrams
Kim Nylander
URL:
Whiteboard:
Depends On:
Blocks: 1546122
TreeView+ depends on / blocked
 
Reported: 2018-03-26 13:24 UTC by Ana Krivokapic
Modified: 2018-03-26 13:53 UTC (History)
4 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2018-03-26 13:53:42 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)

Description Ana Krivokapic 2018-03-26 13:24:07 UTC
Description of problem:
Trying to run tarball extraction API call with a malformed tarball (e.g. another file type just renamed to .tar.gz) fails, but the failure is not reported via the status code, i.e. 200 is returned. 

The problem manifested while using the TripleO UI and trying to execute a deployment plan update with a bad tarball.

Version-Release number of selected component (if applicable):
$ rpm -qa | grep swift
python-swift-2.15.2-0.20180118220641.449d83f.el7.centos.noarch
puppet-swift-12.2.0-0.20180119083117.de58ee9.el7.centos.noarch
openstack-swift-container-2.15.2-0.20180118220641.449d83f.el7.centos.noarch
openstack-swift-object-2.15.2-0.20180118220641.449d83f.el7.centos.noarch
python2-swiftclient-3.4.0-0.20171114141753.e1945ea.el7.centos.noarch
openstack-swift-account-2.15.2-0.20180118220641.449d83f.el7.centos.noarch
openstack-swift-proxy-2.15.2-0.20180118220641.449d83f.el7.centos.noarch


How reproducible:
Always

Steps to Reproduce:
Using the TripleO UI, navigate to the plan page and attempt a plan update using a tarball - supply a malformed tarball (e.g. a different file type renamed as .tar.gz)

Actual results:
The Swift API call for tarball extraction returns 200 even though the tarball extraction failed.

Expected results:
Swift returns an error status code.

Comment 1 Thiago da Silva 2018-03-26 13:53:42 UTC
This is the expected behavior according to the API[0], user must parse the response body for the actual results.

[0] - https://docs.openstack.org/swift/latest/middleware.html#response


Note You need to log in before you can comment on or make changes to this bug.