500 error while performing scan with filter with hash key

Bug #1362239 reported by Andrii Ostapenko
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
MagnetoDB
Fix Released
Medium
Andrii Ostapenko

Bug Description

Getting 500 error trying to perform scan with scan filter, that contains hash key of a table.

2014-08-27 11:03:51,257 Request: POST http://192.168.122.100:8480/v1/add1a968c3d54c1d97524332c423d1bd/data/tables/testtempest1009844457/scan
2014-08-27 11:03:51,257 Request Headers: {'Content-Type': 'application/json', 'Accept': 'application/json', 'X-Auth-Token': 'c3f285a87cd8439f9442a35105a2a387'}
2014-08-27 11:03:51,258 Request Body: {"scan_filter": {"inumber": {"attribute_value_list": [{"N": "1"}], "comparison_operator": "EQ"}, "hash_attr": {"attribute_value_list": [{"S": "1"}], "comparison_operator": "EQ"}}}
2014-08-27 11:03:51,320 Response Status: 500
2014-08-27 11:03:51,320 Response Headers: {'date': 'Wed, 27 Aug 2014 15:03:51 GMT', 'content-length': '268', 'content-type': 'application/json', 'connection': 'close, close'}
2014-08-27 11:03:51,321 Response Body: {"explanation": "The server has either erred or is incapable of performing the requested operation.", "code": 500, "error": {"message": "'listiterator' object has no attribute 'has_next'", "traceback": null, "type": "AttributeError"}, "title": "Internal Server Error"}
}}}

For table with description:
{"local_secondary_indexes": [{"key_schema": [{"key_type": "HASH", "attribute_name": "hash_attr"}, {"key_type": "RANGE", "attribute_name": "istr"}], "index_name": "by_str", "projection": {"projection_type": "ALL"}}, {"key_schema": [{"key_type": "HASH", "attribute_name": "hash_attr"}, {"key_type": "RANGE", "attribute_name": "inumber"}], "index_name": "by_number", "projection": {"projection_type": "ALL"}}, {"key_schema": [{"key_type": "HASH", "attribute_name": "hash_attr"}, {"key_type": "RANGE", "attribute_name": "iblob"}], "index_name": "by_blob", "projection": {"projection_type": "ALL"}}], "key_schema": [{"key_type": "HASH", "attribute_name": "hash_attr"}, {"key_type": "RANGE", "attribute_name": "range_attr"}], "table_name": "testtempest1009844457", "attribute_definitions": [{"attribute_type": "S", "attribute_name": "hash_attr"}, {"attribute_type": "S", "attribute_name": "range_attr"}, {"attribute_type": "S", "attribute_name": "istr"}, {"attribute_type": "N", "attribute_name": "inumber"}, {"attribute_type": "B", "attribute_name": "iblob"}]}

Tags: ux
Changed in magnetodb:
milestone: none → juno-3
importance: Undecided → High
tags: added: ux
Changed in magnetodb:
importance: High → Medium
Changed in magnetodb:
milestone: juno-3 → juno-rc1
Changed in magnetodb:
assignee: nobody → Andrei V. Ostapenko (aostapenko)
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to magnetodb (master)

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

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

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

commit aa521b3087f2c6d434be918b72aaaeeb42f738a3
Author: Andrei V. Ostapenko <email address hidden>
Date: Thu Sep 11 03:29:37 2014 +0300

    Fixes bug with scan on hash key attribute

    Closes-bug: #1362239
    Change-Id: I8e071f77743a46b0e62ab4016242415b108acd08

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