Tempest failures in tempest.api.volume.test_volumes_list.VolumesListTestJSON

Bug #1713732 reported by Dr. Jens Harbott
12
This bug affects 2 people
Affects Status Importance Assigned to Milestone
Cinder
Incomplete
Undecided
Unassigned

Bug Description

After fixing the broken devstack SSL setup in https://review.openstack.org/498435, I am seeing these tempest failures which seems to indicate some broken behaviour in the way cinder-api generates the links within the volume list API:

2017-08-29 11:41:16.887787 | tempest.api.volume.test_volumes_list.VolumesListTestJSON.test_volume_list_details_pagination[id-e9138a2c-f67b-4796-8efa-635c196d01de]
2017-08-29 11:41:16.887840 | -------------------------------------------------------------------------------------------------------------------------------------
2017-08-29 11:41:16.887853 |
2017-08-29 11:41:16.887872 | Captured traceback:
2017-08-29 11:41:16.887890 | ~~~~~~~~~~~~~~~~~~~
2017-08-29 11:41:16.887914 | Traceback (most recent call last):
2017-08-29 11:41:16.887955 | File "tempest/api/volume/test_volumes_list.py", line 350, in test_volume_list_details_pagination
2017-08-29 11:41:16.887991 | self._test_pagination('volumes', ids=self.volume_id_list, detail=True)
2017-08-29 11:41:16.888027 | File "tempest/api/volume/test_volumes_list.py", line 320, in _test_pagination
2017-08-29 11:41:16.888059 | self.assertEqual(next, response.response['content-location'])
2017-08-29 11:41:16.888107 | File "/opt/stack/new/tempest/.tox/tempest/local/lib/python2.7/site-packages/testtools/testcase.py", line 411, in assertEqual
2017-08-29 11:41:16.888135 | self.assertThat(observed, matcher, message)
2017-08-29 11:41:16.888183 | File "/opt/stack/new/tempest/.tox/tempest/local/lib/python2.7/site-packages/testtools/testcase.py", line 498, in assertThat
2017-08-29 11:41:16.888204 | raise mismatch_error
2017-08-29 11:41:16.888230 | testtools.matchers._impl.MismatchError: !=:
2017-08-29 11:41:16.888290 | reference = u'https://104.239.168.36/volume//volume/v2/a65a453cefee4c23a680047d75d4d50a/volumes/detail?limit=1&marker=0d00ccd2-4f62-4918-9275-ea1c420d83be'
2017-08-29 11:41:16.888355 | actual = 'https://104.239.168.36/volume/v2/a65a453cefee4c23a680047d75d4d50a/volumes/detail?limit=1&marker=0d00ccd2-4f62-4918-9275-ea1c420d83be'

See also https://bugs.launchpad.net/devstack/+bug/1713731

Revision history for this message
Linda Wang (lindamy) wrote :

When I run tempest, 2 tests failed in https supported deployment:

tempest.api.volume.v2.test_volumes_list.VolumesV2ListTestJSON.test_volume_list_details_pagination[id-e9138a2c-f67b-4796-8efa-635c196d01de]
tempest.api.volume.v2.test_volumes_list.VolumesV2ListTestJSON.test_volume_list_pagination[id-af55e775-8e4b-4feb-8719-215c43b0238c]

Which complained that:
testtools.matchers._impl.MismatchError: !=:
    reference = u'http://192.16.1.222:8776/v2/f98f4256c5894b1fbd798c0b8d56995e/volumes/detail?limit=1&marker=e414444e-8e6a-4fda-a888-d18042297721'
    actual = 'https://192.16.1.222:8776/v2/f98f4256c5894b1fbd798c0b8d56995e/volumes/detail?limit=1&marker=e414444e-8e6a-4fda-a888-d18042297721'

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to cinder (master)

Fix proposed to branch: master
Review: https://review.openstack.org/499129

Changed in cinder:
assignee: nobody → Dr. Jens Harbott (j-harbott)
status: New → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote :

Fix proposed to branch: master
Review: https://review.openstack.org/499196

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to cinder (master)

Reviewed: https://review.openstack.org/499129
Committed: https://git.openstack.org/cgit/openstack/cinder/commit/?id=6bb387ec141ca758929387afcc31dc846e9ac54c
Submitter: Jenkins
Branch: master

commit 6bb387ec141ca758929387afcc31dc846e9ac54c
Author: Jens Harbott <email address hidden>
Date: Wed Aug 30 12:24:32 2017 +0000

    Make sure that versions are applied as relative URLs

    When urljoining a base_url with a version, the path in the base_url will
    be dropped if the version string starts with a "/". This will lead to
    issues when the base_url looks like "https://HOSTIP/volume/" like in the
    devstack tls-proxy setup.

    Change-Id: Ia2060066330d8e7dd40f37392db4d6b7b9a6fa8e
    Partial-Bug: 1713732

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Change abandoned on cinder (master)

Change abandoned by Jens Harbott (frickler) (<email address hidden>) on branch: master
Review: https://review.openstack.org/499196
Reason: I'm not sure anymore that this is what is really needed.

The devstack setup is working fine after my latest patch without setting public_endpoint at all, so maybe we can completely get rid of that option instead.

Changed in cinder:
status: In Progress → Incomplete
assignee: Dr. Jens Harbott (j-harbott) → nobody
Revision history for this message
Dr. Jens Harbott (j-harbott) wrote :

@Linda: If you want to continue with this issue, please provide further information about your setup that allows to reproduce it. With https://review.openstack.org/498828 applied, there are no more tempest failures in devstack for me.

Revision history for this message
Syed Armani (dce3062) wrote :

@lindamy Were you able to resolve this issue? I am facing this problem as well.

Revision history for this message
Linda Wang (lindamy) wrote :

@Syed Armani Not yet, the issue is still there for me.

Revision history for this message
wutianwei (wutianwei) wrote :

@Syed Armani,@Linda Wang; I fix this issue,just like https://review.openstack.org/498828, add the section
[oslo_middleware]
enable_proxy_headers_parsing = True in cinder.conf.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.