GET messages on a non existing queue returns 204

Bug #1243752 reported by Malini Kamalambal
10
This bug affects 2 people
Affects Status Importance Assigned to Milestone
zaqar
Won't Fix
Low
Unassigned

Bug Description

USER FEEDBACK:

GET messages on a non existing queue returns a 204.
The API should return a 404 in this case, to reflect resource not found

GET /v1/queues/affffrafafafa/messages?echo=True
Expected Response : 404
Actual Response: 204

NOTE: Claim messages on a non existing queue also returns 204. This also needs to be updated to return a 404

Revision history for this message
Kurt Griffiths (kgriffs) wrote :

let's try to get it done without sacrificing performance.

Changed in marconi:
status: New → Triaged
importance: Undecided → High
milestone: none → icehouse-1
Zhihao Yuan (zyuan)
Changed in marconi:
assignee: nobody → Zhihao Yuan (zyuan)
description: updated
description: updated
description: updated
Revision history for this message
Zhihao Yuan (zyuan) wrote :

This will be an important API change; I suggest to wait for Flavio back and we vote on this.

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

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

description: updated
Revision history for this message
Kurt Griffiths (kgriffs) wrote :

If we do it, use oslo.cache to check queue exists.

Revision history for this message
Kurt Griffiths (kgriffs) wrote :

Wait to see if we get more complaints from users before we decide whether to fix this.

Changed in marconi:
importance: High → Low
Revision history for this message
Kurt Griffiths (kgriffs) wrote :

On second thought, take a look at tests/functional/wsgi/v1/test_queues.py - the 204's do seem a bit odd when viewed next to all those 404's.

Revision history for this message
Kurt Griffiths (kgriffs) wrote :

One more thought - if we are going to be lazy, we should be lazy all the way. Let's choose which way to go and be consistent.

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

Reviewed: https://review.openstack.org/53691
Committed: http://github.com/openstack/marconi/commit/e515053dd16219babda80de21e49320821f8885f
Submitter: Jenkins
Branch: master

commit e515053dd16219babda80de21e49320821f8885f
Author: Malini Kamalambal <email address hidden>
Date: Thu Oct 24 12:57:19 2013 -0400

    Add Tests for non-existing resources

    This patch adds tests for action on non-existing queues, messages & claims.

    Change-Id: I68517b1b98f668eff86a0bcad19dc9ed8d01267c
    Tests-Bug: #1243752

Thierry Carrez (ttx)
Changed in marconi:
milestone: icehouse-1 → icehouse-2
Revision history for this message
Kurt Griffiths (kgriffs) wrote :

Let's do this as part of the v1.1 API...

Changed in marconi:
assignee: Zhihao Yuan (zyuan) → nobody
Revision history for this message
Seif Lotfy (seif) wrote :

Hey guys, I am also getting 204s on GET messages on non-existing queues. I am not sure this makes sense. Any objections if I hack a fix?

Revision history for this message
Kurt Griffiths (kgriffs) wrote :

I was thinking of only changing that behavior in the v1.1 API - if you would like to tackle it there, and leave 1.0 as-is, that would be cool. Thanks!

Changed in marconi:
assignee: nobody → Victoria Martínez de la Cruz (vkmc)
Changed in marconi:
assignee: Victoria Martínez de la Cruz (vkmc) → nobody
Revision history for this message
Victoria Martinez de la Cruz (vkmc) wrote :

This bug will be no longer relevant when the support for lazy queues creation gets merged in v1.1. Following the lazy creation criteria, if it is possible to send messages to a queue that doesn't exist, then it's also possible to retrieve messages for a queue that doesn't exist.

It is still valid, though, for v1.0.

Changed in marconi:
assignee: nobody → Victoria Martínez de la Cruz (vkmc)
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to marconi (master)

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

Changed in marconi:
status: Triaged → In Progress
Kurt Griffiths (kgriffs)
no longer affects: marconi/icehouse
Revision history for this message
Kurt Griffiths (kgriffs) wrote :

Do to lack of complaints from customers, and the fact that this behavior is actually "correct" in v1.1, we decided as a team that fixing this bug would be more trouble than it is worth.

Thierry Carrez (ttx)
no longer affects: marconi/juno
Kurt Griffiths (kgriffs)
Changed in marconi:
status: In Progress → Won't Fix
Changed in marconi:
assignee: Victoria Martínez de la Cruz (vkmc) → nobody
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Change abandoned on marconi (master)

Change abandoned by Victoria Martínez de la Cruz (<email address hidden>) on branch: master
Review: https://review.openstack.org/95593
Reason: Won't fix - https://launchpad.net/bugs/1243752

Thierry Carrez (ttx)
Changed in marconi:
milestone: juno-2 → none
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.