glance/glance/tests/unit/v2
Dinesh Bhor 2562da28c6 Fix 500 if user passes name with more than 80 characters
Following apis are returning 500 error if user passes name with more
than 80 characters:
* md-tag-create
* md-tag-update
* md-object-create
* md-object-update
* md-property-create
* md-property-update

This happens because there is a discrepancy in db column length and
glance-api length check in schema validation. In database the 'name'
field for these API's is defined as of maximum 80 characters and in
schema it is defined as of maximum 255 characters. So if user passes
name with more than 80 characters and less than 255 characters
database fails to store that value and shouts with following error
which leads to 500 error to API user:

(pymysql.err.DataError) (1406, u"Data too long for column 'name' at
row 1")

Fixed this issue by changing the maximum allowed length for 'name'
from 255 to 80 in schema validation.

APIImpact
DocImpact
Closes-Bug: #1719252
Change-Id: I4ae67457c3e4f5a6bfc3c1db2d305a9b7587395f
2017-10-05 10:24:22 +05:30
..
__init__.py Adding versioned namespaces in test dir 2012-03-25 13:28:45 -07:00
test_discovery_image_import.py Return 404 for import-info call 2017-08-18 01:17:32 -04:00
test_image_actions_resource.py Implement and Enable Community Images 2017-01-18 17:56:12 +00:00
test_image_data_resource.py Accept Range requests and set appropriate response 2017-04-05 20:40:02 +00:00
test_image_members_resource.py Implement and Enable Community Images 2017-01-18 17:56:12 +00:00
test_image_tags_resource.py Extracted HTTP response codes to constants in tests 2016-10-06 15:17:06 +00:00
test_images_resource.py Merge "Implement and Enable Community Images" 2017-01-19 18:24:08 +00:00
test_metadef_resources.py Fix 500 if user passes name with more than 80 characters 2017-10-05 10:24:22 +05:30
test_registry_api.py Implement and Enable Community Images 2017-01-18 17:56:12 +00:00
test_registry_client.py Tests: Remove the redundant methods 2017-06-20 15:55:01 +08:00
test_schemas_resource.py Fix order of arguments in assertEqual 2015-09-16 02:55:33 -07:00
test_tasks_resource.py Add 'tasks_api_access' policy 2017-08-18 00:46:34 -04:00