Incorrect error when put item in nonexistent table

Bug #1297247 reported by Oleksandr Minakov
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
MagnetoDB
Fix Released
Medium
Oleksandr Minakov

Bug Description

2014-03-25 14:10:36,114 Request: POST http://127.0.0.1:8080/v1/testtenantid/data/tables/nonexistent_table/put_item
2014-03-25 14:10:36,114 Request Headers: {'Content-Type': 'application/json', 'Accept': 'application/json'}
2014-03-25 14:10:36,114 Request Body: {"item": {"message": {"S": "message_text"}, "author": {"S": "Bob"}}}
2014-03-25 14:10:36,121 Response Status: 500
2014-03-25 14:10:36,121 Response Headers: {'date': 'Tue, 25 Mar 2014 12:10:36 GMT', 'content-length': '149', 'content-type': 'application/x-amz-json-1.0'}
2014-03-25 14:10:36,122 Response Body: {"__type":"com.amazonaws.dynamodb.v20111205#InternalServerError","message":"The server encountered an internal error trying to fulfill the request."}

Expected response status: 404

Expected response body:

{
    "explanation": "The resource could not be found."
    "code": 404
    "error":
       {
          "message": "Table 'nonexistent_table' does not exists",
          "traceback": null,
          "type": "TableNotExistsException"
      }
}

Tags: data-api
description: updated
description: updated
tags: added: data-api
Changed in magnetodb:
milestone: none → 2.0.3
Changed in magnetodb:
assignee: nobody → Oleksandr Minakov (oleksandr-minakov)
description: updated
Revision history for this message
Openstack Gerrit (openstack-gerrit) wrote : Fix proposed to magnetodb (master)

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

Changed in magnetodb:
status: New → In Progress
Changed in magnetodb:
milestone: 2.0.3 → 2.0.4
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to magnetodb (master)

Reviewed: https://review.openstack.org/90718
Committed: https://git.openstack.org/cgit/stackforge/magnetodb/commit/?id=6acf96b719a7e8bb85f774117c4349382e6eb17a
Submitter: Jenkins
Branch: master

commit 6acf96b719a7e8bb85f774117c4349382e6eb17a
Author: Oleksandr Minakov <email address hidden>
Date: Mon Apr 28 15:54:15 2014 +0300

    Add tempest test for put item

    Update test for coverage TableNotExistsException.

    Change-Id: I4e2d8fa92e417faa60abb110e8e3f63bb3c8c6da
    Closes-Bug: #1297247

Changed in magnetodb:
status: In Progress → Fix Committed
Changed in magnetodb:
importance: Undecided → Medium
Changed in magnetodb:
status: Fix Committed → Fix Released
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.