Attempt to get list ofusers by passing non existant tenant id is not raising exception

Bug #1006344 reported by Rajalakshmi Ganesan
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
OpenStack Identity (keystone)
Fix Released
Low
Dolph Mathews

Bug Description

Attempt to get list ofusers by passing non existant tenant id is not raising exception, instead an empty list is returned.

Expected Result:

Message stating Tenant ID not found should be raised. i.e 404 error code should be returned.

Actual Result:

code 220 is returned and an empty list is displayed

LOG:
------------

rajalakshmi_ganesan@pshys0183~json:-)>keystone --debug user-list asd88
connect: (10.233.52.27, 5000)
send: 'POST /v2.0/tokens HTTP/1.1\r\nHost: 10.233.52.27:5000\r\nAccept-Encoding: identity\r\nContent-Length: 102\r\ncontent-type: application/json\r\nuser-agent: python-keystoneclient\r\n\r\n{"auth": {"tenantName": "admin", "passwordCredentials": {"username": "admin", "password": "muralik"}}}'
reply: 'HTTP/1.1 200 OK\r\n'
header: Content-Type: application/json
header: Vary: X-Auth-Token
header: Content-Length: 2229
header: Date: Wed, 30 May 2012 16:40:44 GMT
connect: (10.233.52.27, 35357)
send: u'GET /v2.0/tenants/asd88/users HTTP/1.1\r\nHost: 10.233.52.27:35357\r\nx-auth-token: 85a47527e6704ab68e1df183bd8a5e4a\r\naccept-encoding: gzip, deflate\r\nuser-agent: python-keystoneclient\r\n\r\n'
reply: 'HTTP/1.1 200 OK\r\n'
header: Content-Type: application/json
header: Vary: X-Auth-Token
header: Content-Length: 13
header: Date: Wed, 30 May 2012 16:40:44 GMT
+----+---------+-------+------+
| id | enabled | email | name |
+----+---------+-------+------+
+----+---------+-------+------+

affects: tempest → keystone
Revision history for this message
Dolph Mathews (dolph) wrote :

This is fixed by a patch already in review: https://review.openstack.org/#/c/6875/

After applying above patch: http://paste.openstack.org/raw/18236/

Changed in keystone:
assignee: nobody → Dolph Mathews (dolph)
importance: Undecided → Low
status: New → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to keystone (master)

Reviewed: https://review.openstack.org/6875
Committed: http://github.com/openstack/keystone/commit/23ca656927947dada40591bdd1badd5a531c2983
Submitter: Jenkins
Branch: master

commit 23ca656927947dada40591bdd1badd5a531c2983
Author: Dolph Mathews <email address hidden>
Date: Wed Mar 28 10:37:16 2012 -0700

    Refactor 404's into managers & drivers (bug 968519)

    The goal is to move the responsibility of reference checks away from
    controllers and into the underlying managers & drivers, which can
    handle the task with equal or greater efficiency.

    - Tenant references from create_user/update_user are NOT tested
      due to inconsistencies between backends
    - Additional test coverage improvements

    Also fixes bug 999209, bug 999608, bug 1006029, bug 1006055, bug 1006287,
    bug 1006334, and bug 1006344.

    Change-Id: I7de592e7dd4518038436b9a9fdaab559b00a0537

Changed in keystone:
status: In Progress → Fix Committed
Thierry Carrez (ttx)
Changed in keystone:
milestone: none → folsom-2
status: Fix Committed → Fix Released
Thierry Carrez (ttx)
Changed in keystone:
milestone: folsom-2 → 2012.2
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.